Installing Any OS To A New VMWare Virtual Machine

by Dan Pisarski in General Software Development, Virtualization

· No Comments

I recently built a Kubuntu 7 virtual machine using the freely available VMWare Player. In doing so, I found a few tutorials and guides online to get you started with VMWare Player, but surprisingly few real step-by-step guides to building a new virtual machine.

So I thought I would document the few steps involved here.

  1. Get VMWare Player (actually, you don’t have to do this first necessarily, but you’ll obviously need it eventually)
  2. Download your operating system, for my example I downloaded Kubuntu 7.04, but really you can start with anything – what you need is an ISO disk image that is a bootable CD-ROM disc image (which is exactly what Kubuntu provides, or for example what MSDN would provide if you were downloading Windows XP via your MSDN membership)
  3. Go to EasyVMX.com, which is a tool that helps you write the VMX file, a text file that sets up the parameters of the virtual machine – it’s just a text file and you could also edit it by hand if you wanted
  4. Choose the easyvmx option, which is the simplest of the interfaces that still gives you some control over parameters you may want
    1. The first section, Virtual Hardware, is where you set your machine name (depending on how you set your network settings, this virtual machine will appear on your network just like a real computer, and this is the name it will report)
    2. GuestOS seems to be just metadata for the virtual machine, do not be confused that this is somehow going to include the OS for you, it doesn’t, it just sets a text line in the VMX defining what OS you are going to install
    3. Memory Size is important, this will be the total memory available to your virtual machine
    4. # of CPUs has to be set to 1, since VMWare Player only supports 1 virtual cpu – VMWare Server apparently supports more but I have not worked with Server yet
    5. The whole Description section is just metadata, again
    6. EasyVMX includes pretty clear instructions for the Network Configuration section – you probably want Bridged, which will make this virtual machine appear on your network just like another machine (and let it acquire an IP address via DHCP if you have DHCP running)
    7. Disk Configuration has two key areas, setting up a CD-ROM drive to install your incoming OS from, and setting up your virtual hard drive
    8. For the CD-ROM, the first CD-ROM is set to be your physical CD-ROM drive, and it will auto-detect what drive to use, so the default settings here should be fine for you
    9. For the second CD-ROM drive, you want to map to the *.iso file of the operating system you are installing (see step 2 above). Input the full filename of the ISO image here, and make sure you place the ISO image in the same folder as the VMX file when you get started below – also, of course, check Enabled so this drive will actually be input into the VMX file
    10. EasyVMX already defaults hard drive 1 to enabled and all you really need to pick is the size – note when you first create the virtual machine, it will not create a *.vmdk file of that size, but as you install the OS and programs it will fill up to this maximum size
    11. The last section, Sound and I/O Ports Configuration, is pretty straightforward – one note, don’t feel too threatened to get all these answers right, as it is very easy in VMWare Player to enable and disable specific external devices, like audio or USB devices
    12. Click Create Virtual Machine and you will see a link to download the total bundle of files (as a *.zip file) – this is your ready-to-use VMX file
  5. Put all your files into a single directory on your computer, the ISO image and the files from the zip archive you just downloaded, and double-click the VMX file to start the virtual machine
  6. As the virtual machine starts, along the top of the player you will see buttons that turn on or off devices – in this case, turning on or off meaning exposing that real device to the virtual machine – make sure the CD-ROM 2 device is enabled, as recall this is your map to your ISO image
  7. The virtual machine basically boots like a real computer with a BIOS, it will see the bootable “CD-ROM” and boot from the ISO image, and you can then follow the OS install as if you were installing it to a real computer – including partitioning and formatting the virtual disk
  8. Once you have the OS installed, you no longer need the CD-ROM 2 device or the ISO image, you can turn off the device and delete the ISO if you want

That’s it – you should be up and going. If, like me, you are installing Kubuntu to create a Ruby on Rails development environment, jump over to RussBrooks.com, as he has two posts covering installing a Rails dev environment onto Kubuntu 7.4.

← Previous

Next →

Leave a Comment

You must be logged in to post a comment.