Basically after cloning such a template machine (e.g. using CloneZilla), the most important thing after starting the clone is to change the hostname - and here is how to do it:
There are two files to edit - and you should edit them in this order - just changing the hostname (in total should be 3 times occuring):
sudo vim /etc/hosts
127.0.0.1 nowthenewhostname localhost.localdomain localhostsudo vim /etc/hostname
127.0.1.1 nowthenewhostname
nowthenewhostname
For those not familiar with vim - just press "i" to get into edit mode and when finished press "ESC" and enter ":x" followed by pressing "Enter".
And sure, you can use gedit instead of vim also.
See also more information on Cloning Ubuntu to Different Computer Hardware.
Related post: Virus scanning on Ubuntu, Stationary under Ubuntu.
3 comments:
Thanks. I knew about /etc/hostname having just stumbled upon it. I've only been changing that one and it was bugging me that in certain dialogs I was still seeing the old hostname show up. Good thing I'm not running a server or I'm sure I would have had bigger problems from that. This should really be doable in a gui in my opinion.
I don't know since when, but there is a tool for that named "hostname" in the meantime (or already longer without my notice). Type
man hostname
for more information.
As expected - even on more recent versions this is still the way to go - see also: here.
Post a Comment