<!-- 
.. title: Change (yes we can)
.. slug: change-yes-we-can
.. date: 2008-11-23 14:48:07 UTC+01:00 
.. tags: virtual-machines, 
.. link: 
.. description: 
.. type: text 
--> 

Virtual machines enable us to have various operating systems in store for testing or support purposes. Rather than installing each of these systems, one can download the respective [virtual appliance](http://www.vmware.com/appliances/) and use it instantaneously with [the free VMware Player.](http://www.vmware.com/products/player) Alternatively, one may download [a virtualbox image](http://virtualbox.wordpress.com/images/) and use it in [VirtualBox.](http://www.virtualbox.org/) Now, these appliances often have rather funny sounding host- and usernames, which at least I really want to change to avoid confusion. Here's how.

The hostname is simple...

	hostname new_name

That's, however, just temporary.;) A permanent change is achieved by editing /etc/hostname for Debian and Ubuntu, /etc/HOSTNAME for Suse and Slackware, and /etc/sysconfig/network on Redhat, Fedora and Mandriva. Don't forget to check /etc/hosts either.

Changing the username from, say, "Jim" to "John" is not difficult either, but can also be done in a few seconds:

	init 3
	killall -u Jim
	usermod -l John Jim
	groupmod -n John Jim //if required...check before with "id Jim"
	usermod -d /home/John -m John
	usermod -c “Johnnie Walker” John
	id John //just for checking
	shutdown -r now

A consistent naming scheme really helps. 😉

