Virtual Machines: Virtualization vs. Emulation

I just wanted to write down some quick notes about virtual machines. Virtual Machines have always been an effective and efficient way to emulate multiple computers without requiring all of the space and hardware. They create a completely isolated operating system installation within your normal operating system. For this posting, i’ll define two words: host and guest. The host is the native computer that you are running and guest is the virtual machine instance that is running on the host. They are implemented in two ways: emulation and virtualization.

Emulation involves emulating the virtual machines hardware and architecture. Microsoft’s VirtualPC is an example of an emulation based virtual machine. It emulates the x86 architecture, and adds a layer of indirection and translation at the guest level, which means VirtualPC can run on different chipsets, like the PowerPC, in addition to the x86 architecture. However, that layer of indirection slows down the virtual machine significantly.

Virtualization, on the other hand, involves simply isolating the virtual machine within memory. The host instance simply passes the execution of the guest virtual machine directly to the native hardware. Without the translation layer, the performance of a virtualization virtual machine is much faster and approaches native speeds. However, since the native hardware is used, the chipset of the virtual machine must match. Usually, this means the Intel x86 architecture. VMWare is an example of this type of application for Windows.

Regardless of your virtual machine direction, they provide a way to run separate logical instances of an OS on one physical computer. Some uses of this include:

1. Development test bed - Creating separate virtual machines for development environments enables you to customize your laptop for particular environments, without messing with your actual laptop. Good for all those WebSphere or BizTalk installs.

2. Testing Environment – The ability to recreate a customer specific environment, including all relevant hot fixes & service packs, proves to be invaluable when debugging production problems.

3. General Sandbox – Ever want to try a piece of software, but were afraid ruin your computer? Most virtual machines have the ability to rollback in-memory changes to preserve a particular state of the virtual machine. This provides a good safety net.

These are just some of the uses of virtual machines. I am sure people will figure out more.

Technorati Tags: ,