The free VMWare Player is a very powerful and simple way to run virtual machines on your PC. You install the VMWare Player software, download some pre-configured virtual machines, and can run just about any other operating system from the comfy confines of your favorite operating system (Windows or Linux) without ever having to worry about messing up your favorite operating system. (You can read a more in-depth description of the VMWare Player from one of my previous posts, “VMWare: See How the Other Half Lives“)
VMWare also makes the VMWare Server software, which gives you a lot more control over your virtual machines, including a wizard that you can use to create your own virtual machine. VMWare Server is also free but may be a bit too complex for the user who simply wants to try out a different OS.
That leaves us with the choice between the simple VMWare Player, which you use to run pre-configured virtual machines, and the more complicated VMWare Server, which allows you to create your own virtual machines. But what if a user wants the simplicity of the VMWare Player and the ability create their own virtual machines from scratch? It’s actually quite easy to do.
In simplified terms the VMWare Player is really just the VM runtime component of the VMWare Server, including all of the abstracted hardware components that the virtual machine needs in order to be able to run. That means that the Player uses the same configuration file as the Server, and that means that you can use the VM creation wizard from the Server to create a configuration file that will also work with the Player.
If you don’t have the Server application you can still create the configuration file — you’ll just have to do it manually. The configuration file that VMWare uses for both their Player and Server is just a text file. As long as you know what settings are required to define and run the virtual machine you can use a simple text editor to create a configuration file that will work with the Player. So, in reality you’ve always been able to create your own VM’s to be used with VMWare Player, as long as you understand what to put into that configuration file. Or, you can take the easy way out. In this case that would be the EasyVMX way out.
EasyVMX is a website which provides a simple way to create that configuration file without having to understand everything that it contains. There’s nothing that the EasyVMX website does that you couldn’t accomplish by creating and editing that configuration file with a simple text editor — it just makes it much easier, not to mention reducing the chance of errors in your configuration file.
The site gives you three different ways to create your VM configuration file using three configuration screen targeted to users with different technical needs:
- “Super Simple Edition” – you pick the name of the VM that you’re creating, choose the type of OS, and the amount of memory and drive space you’d like the VM to have. That’s it.
- EasyVMX! (normal) – in addition to the choices provided in the Super Simple Edition you also have an opportunity to modify settings such as network and disk configurations.
- Expert – all options which are available in a VMWare configuration file.
Let’s walk through a practical example. I already have VMWare Player installed on my Windows OS and I’d like to create a virtual machine so that I can try out the latest version of the Ubuntu operating system.
The first thing I have to do is download the Ubuntu installation CD image (.iso) file from here. I’ll store the file right on the root of my “C:\” drive. If I was installing Ubuntu onto a “real” machine I’d have to take the downloaded file and burn it onto a CD or DVD before I could use it but since we’re going to be using a virtual machine we can skip that step. If you’d like to burn it to a CD you can do that, too — just skip the step below which talks about adding the 2nd CD-ROM drive.
The next step is to set up our VMWare Player configuration file. Go the EasyVMX website and choose the “EasyVMX!” link. In the Basic Configuration section we’ll assign a name to this virtual machine container, choose the type of OS, the amount of memory the VM is going to be use, and the number of CPU’s (in the case of VMWare Player you’re limited to 1).
Next we’ll have to decide how we’re going to handle networking. I like to use the “Bridged” setting, which basically means that the virtual machine is to be treated like any other OS you may have running on your network. That way it will have it’s own IP address which it will get either from your DHCP server or by static assignment.
Since we downloaded the .iso image but didn’t burn it to a CD we’ll have to tell the VMWare Player what to do. If you have a physical CD image instead of just an .iso file you can skip this step completely.
By default your PC’s CD-ROM drive gets mapped as the “Master” CD-ROM drive in the virtual machine. We’ll add a 2nd CD-ROM drive to the virtual machine and point it to the Ubuntu .iso file we downloaded earlier. From the virtual machine’s perspective it will look like a 2nd CD-ROM drive with our Ubuntu disc loaded into it. (Please note that the file name shown truncated below is the complete file name to the .iso file: “C:\ubuntu-6.10-desktop-i386.iso”) If you plan to use an actual CD to install your VM’s OS you can skip this step and just use the Master CD-ROM drive.
Next we tell EasyVMX how large we’d like the virtual machine’s hard drive to be. In this example I’m going to use a single 4GB drive. Remember, the virtual machine can’t see your PC’s hard drive at all — all it sees is what you define here.
That’s about all we need to define in our virtual machine to get Ubuntu up and running. Now we just tell EasyVMX that we’re ready to go and it’ll generate a .zip file containing everything we need to create our virtual machine. Open up that .zip file and copy the contents to the directory where the virtual machine is going to live. Remember to make sure that the location you choose for your virtual machine has enough free drive space. In our example above we told EasyVMX that we wanted to set aside 4GB for this virtual machine so we need to make sure that the directory we use as the location of our virtual machine has at least 4GB of free space available.
Here I’ve unzipped the file that EasyVMX created for me and copy the contents into my Eds_Ubuntu_Desktop directory. Although we specified that the virtual machine was going to be 4GB large it isn’t using more than 1MB of drive space yet. The files which are used as the VM’s hard drive will grow as needed up to the 4GB size we specified.
Now we’re ready to fire up our virtual machine. You can either double-click on the .vmx file in the virtual machine directory or you can start up VMWare Player (Start -> VMWare -> VMWare Player) and point it to the .vmx file. You’ll see VMWare start your virtual machine just like it would start a “real” system. The VM’s BIOS will first look to the VM’s hard drive to boot an OS but it won’t find anything there (remember, we haven’t actually installed the OS yet). If you’re using the .iso file you’ll have to disable the Master CD-ROM and enable the Slave “CD-ROM 2″ by clicking on those buttons at the top of the player so the VM will boot from the .iso image and not from the Master CD-ROM drive. And away it goes……
The Ubuntu CD is a “live” CD — it runs itself from memory instead of from your hard drive in order to give you a chance to check it out. If you decide that you like what you see you can double-click on the “Install” icon on the VM’s desktop to launch the Ubuntu installer which will install the OS to your hard drive. The installer will ask you the standard questions (pick your timezone, set up your partitions, etc.) and then will copy its files to your new partition. Remember, it’s not installing Ubuntu onto your PC’s hard drive — it’s installing Ubuntu onto the 4GB virtual hard drive that we’d set up earlier.
Once Ubuntu is installed onto your VM’s hard drive it will ask you to remove the CD-ROM from the drive and to restart your system. If you used an actual CD-ROM drive go ahead and eject it, otherwise we need to re-enable the Master CD-ROM drive by clicking on the CD-ROM button at the top of the player. Once you’re removed the CD-ROM disc or re-attached the Master CD-ROM drive tell Ubuntu to go ahead and restart the system. It thinks it rebooting your PC but what it’s really doing, of course, is restarting your virtual machine.
The virtual machine restarts and you get to the Ubuntu login screen.
That’s it — you have a fully-functional Ubuntu installation running from within your VMWare Player. Sure, you could’ve just downloaded a pre-existing Ubuntu virtual machine from the VMWare website but, by doing it this way, you know exactly what’s in that virtual machine because you’re the one who put it there. Besides, there are times when you’ll need to know how to create your own VM. For example, you won’t find any Microsoft Windows VM’s on VMWare’s website because of licensing issues. Using this technique you can create a Windows virtual machine just like we did for our Ubuntu virtual machine.
One additional bonus from running an OS in a virtual machine is thatyou can just shut down the VM and the contents of its memory will be saved as a file, much like putting your PC in Hibernation dumps the contents of its memory to its hard drive. When you run the VM again the file will be loaded back into the VM’s memory and you’ll pick up right where you left off without having to wait for the OS to complete its normal boot process.
VMWare Player makes it easy to run virtual machines on your PC, and EasyVMX makes it easy to create those virtual machines. Now you, too, can Ubuntu.