What is a Virtual Computer?

There's quite a bit of hype in the world these days around the concept of Virtual Computing - but what is it? Here's a simple explanation.

Virtual Computers

Virtual Computers are software programs that you run on your existing physical computer. When you create a new Virtual PC it behaves like a brand new PC except that it shares whatever you already have in your existing PC. A Virtual Computer:

  • draws graphically on a window on your existing screen so that you don't need a new screen,
  • shares your current keyboard and mouse instead of requiring you to connect new ones,
  • shares the file space on your existing hard disk,
  • is able to read the CD's and DVD's that you put into your existing DVD drive,
  • and plays music through your existing sound card and speakers.

Most importantly: a Virtual computer creates an environment that looks, from a software point of view, exactly like a physical computer. You can install an Operating System onto a Virtual computer the same way that you would on any physical computer - but you don't have to go to the store to buy anything.

In fact, Virtual computers can be created with a few clicks. If you want to learn about networking and need three or four computers - just click and create Virtual PC's. Need a Virtual Network so that you can connect all the computers together? Go ahead - create a Virtual Network and connect your Virtual PC's to it. It's fast, it's cheap, it's easy and it's much better than putting a ton of equipment and wires on a large workbench and fiddling with it all day.

What are the Advantages?

When Virtual PC's first came into common use they were too slow for most applications. In those days they were used mostly for testing. The main advantage offered by Virtual PC's in those days was the convenience of being able to create them quickly - then erase them. It was possible to build, for example, a working copy of a physical network of PC's. Complex tests could then be executed and, if necessary, the entire network could be torn down and rebuilt in a matter of minutes.

Eventually both Intel and AMD, the main manufacturers of CPU's, discovered the value of Virtual Computing. They began to add features to their CPU's to make things go faster. These days a Virtual PC runs at over 90% of the speed of a physical PC.

Most importantly: If you currently run a half-dozen servers in your company you are no-doubt aware that they tend not to be very busy. Most physical servers are only called upon to perform at a small fraction of their full potential. So why not move all the software from the various servers into one physical server? Because it creates a system and software management problem. On the other hand, it's easy to put a half-dozen Virtual Servers into a single Physical Server. This reduces the cost of hardware and maintenance - but has surprisingly little impact on overall performance.

Of course the main benefit of Virtual PC's is that you can create and destroy them in much the same way that you create and destroy files on your hard disk - it's that easy. If you want to try out a new operating system or if you need to carefully document the procedure for installing a complex piece of software on a new computer - do it on a Virtual PC in your desktop. It's clearly the best way.

Backups are also easy with Virtual PC's. A Virtual PC resides in your physical computer in the form of a disk file. When you turn it off you can just copy the file - so making a full backup involves only zipping that one file. You can build a test environment consisting of a half-dozen Virtual PC's - then just shut them down and zip them up when you are done. When you need to run more tests all you have to do is unzip the files so that you can restart the Virtual PC's - it really is that easy.

Is there a downside?

Virtual Computers are great - they really do work much like a physical computer and, in many cases, they are just as fast and easy to use. However, they are not perfect replacements for physical computers. In some cases the minor differences between a physical and a virtual computer can become significant.

For example:

  • The graphical window that a Virtual PC uses as a screen is not compatible with a high performance video card. Modern video cards contain 3-D graphics processing units - in effect little computers that handle high-performance graphics tasks. Most current Virtual PC's don't have the ability to emulate this feature. As a result, sophisticated software that relies on such abilities is not going to work very well in a Virtual PC. Many 3-D action games, for example, run very slowly on virtualized hardware.
  • There are other issues related to Virtual screens and shared mouse cursors. In some cases you will find that graphical editing software can be a little more difficult to use as a result.
  • In some cases you might find it difficult to share some hardware with your Virtual PC's. For example: While it's easy to share the speakers on a sound card it takes a little more care to share a microphone. Some USB devices can be difficult to share.

In practice: you may experience some difficulty if you are trying to:

  • use graphical or video editing software (performance may be unacceptably slow and mouse operations might lack precision.)
  • work with external sources of video or audio (it may be difficult to connect external devices to your virtual machine.)

On the other hand: If you are using a PC strictly for office applications (text editing, spreadsheets, accounting,) you won't notice any difference between a physical computer and a virtual computer.

Technical Details

Virtual PC's run under a software program called a Hypervisor - a software program that creates an operating environment that looks and behaves like an empty PC.

  • Every hypervisor allows you to create a new Virtual PC with a few clicks and
  • incorporates a BIOS that allows you to install an Operating System into each new Virtual PC.
  • Each Virtual PC behaves exactly like a Physical PC except that it must share the disk space, mouse, keyboard and other resources.

There are many Hypervisors available on the market these days. These including Open Source products like QEMU, KVM and XEN that you can download and use for free. Some are commercial products that are available for free (including VirtualBox from Sun Microsystems and VirtualPC from Microsoft.) Others are commercial products that are sold at various different price points (Parallels and, the grand-daddy of them all, VMWare.)

The main differences between hypervisors revolve around the way they virtualize hardware. Some hypervisors, for example, fail to handle USB devices while others allow easy connecting and disconnecting of USB devices from a Virtual PC.

Some hypervisors provide sophisticated management feastures. XEN, for example, offers a feature called Live Migration. This feature makes it easy to manage performance issues. It allows you to command a Virtual Server to migrate itself from one Physical Computer to another - even while it is still running.

The end result is reduced management cost, reduced hardware cost and greater flexibility in disaster planning (and disaster recovery.)

Cloud Computing

Cloud computing environments expand on the above. They allow a massive amount of hardware, spread out over a vast geographical area, to be used to provide virtual computing services on an on-demand basis.