Feb 28, 2010

VMWare...

Recently I went from using stand alone machines to VMWare ESXi server. It gives me much more flexibility. We purchased HP ML350 with 16GB Ram and one processor so far. Will try to upgrade it soon.

Anyway, the first major thing was, I didn't want to install new machine from the scratch over and over. We have several Ubuntu servers and I just needed one install which I would reuse as a base for different servers.

The way to do it in ESXi is:
  1. Prepare one virtual machine for cloning. In my case it was to make a basic installation of Ubuntu server. Don't forget to install VMWare Tools, so you don't have to do it for each of your clones later.
  2. Then go to your datastare and make a directory for a new virtual machine. Go back to the directory of your Ubutu server installation from previous step. Copy all *.wmx and *.wmdk files over to your new directory.
  3. When done go to the new directory, right click on *.wmx file and choose "Add to Inventory". Finish the wizard.
  4. Start your new virtual machine.
  5. Go to console and edit /etc/hostname file to have the name you want your virtual machine to have.
  6. Go to console and edit /etc/hosts. Change hostname from the name of your cloned machine to the one form previous step.
  7. Go to console and edit /etc/udev/rules.d/70-persistent-net.rules You just need to comment first line and change eth1 to eth0 in the second line.
  8. In console edit /etc/network/interfaces and change IP of your machine.
After those steps your "cloned" virtual machine is ready. Now you can install whatever software you need for the particular case.