Freigeben über


What is a Virtual Machine?

Virtualization 101 (Red)

Hyper-V is a platform that is used for running virtual machines.  Maybe it’s the term virtual which in the western culture has come to mean “not physical” or “Ethereal” or “not real” and I think the reason for this definition is because of the term “virtual reality.”  When it comes to virtual machines that definition  just does not hold up.  The operating systems that run as virtual machines are as real as any other operating system that you have ever installed.  They will still take up Gigabytes of real disk space, the will consume Gigahertz of real processor power, they will consume Gigabytes of real RAM.  They are real operating systems!  The thing about Hyper-V is that we have eliminated the necessity of a one to one relationship between hardware platform and the operating system.  With Hyper-V the relationship is now one to many.  On the Hyper-V platform the way in which we structure the virtual machine is important and we certainly should understand it clearly.

VMM

The prerequisite to understanding virtual machine construction is a brief understanding of the management environment in which the virtual machines will be built, operated, and managed.  When you install the Hyper-V role on your hardware you also install a management tool called Hyper-V manager.  Hyper-V manager is a free tool that comes with Hyper-V.  Hyper-V manager is the tool that we use as the management foundation for all of the virtual machines that will be operating on a Hyper-V server.  Hyper-V manager is classified among a set of tools used to manage virtual machines and so we often call it simply a Virtual Machine Manager (VMM.)  Each type 1 hypervisor platform will use some form of VMM to manage their virtual machines regardless of operating systems virtualized, or manufacturer of the hypervisor.  We find VMM’s in Hyper-V, VMware, and Xen.  Microsoft has an additional VMM that you might choose to use in managing you virtual machines called System Center Virtual Machine Manager.  This is a for purchase product that can be added to your virtualization environment.  Regardless of the VMM that you use to build and maintain your Hyper-V based virtual machines the component pieces of the virtual machine are the same.  

.VHD

The first key principal of virtual machine construction is the Virtual Hard Disk.  The virtual hard disk is a single file that is used as a container for all of the operating system files, any applications that are installed on that operating system, and any associated files and settings saved to that system.  The virtual hard disk file has a unique file extension that helps us to easily identify it.  The extension is simply .vhd.  Many of you are familiar with the term .vhd file because it has been used by Microsoft in each of our type 2 hypervisor products (Windows Virtual PC, and Windows Virtual Server.)  Microsoft has kept the .vhd file type on purpose as they have moved from type 2 hypervisors to the type 1 hypervisor Hyper-V.  Many of you are wondering if the .vhd file is portable from Windows Virtual PC to Hyper-V.  The answer is yes, with some caveats! The biggest caveat comes form the fact that the configuration files in Hyper-V are different than the configuration file in Windows Virtual PC. 

Snapshot Files

When you are using Hyper-V one of the really options is to use something called snapshots, which lets you make a point in time image of a running virtual machine.  We will talk in detail about snapshots at a later time.  For now a snapshot is nothing more than a differencing file with references to the original .vhd.  The snapshots are saved as part of the virtual machine in a format called an .avhd file. 

Configuration files

Virtual machines in Hyper-V do have configuration files, although, as we mentioned earlier, those files are not in the .vmc format that you would find in say Virtual PC or Virtual Server.  The configuration files for Hyper-V virtual machines come in XML format.  This configuration file is used by the VMM to control resource allocation, startup, state, and operation of the virtual machine.

Taken together these files comprise the makings of a virtual machine in Hyper-V.  It is important to note here that the files associated with virtual machines in Hyper-V are tied to the server on which they are created, or imported.  You cannot simply cut copy and paste files from one server to another and expect them to work.  In other words virtual machines in Hyper-V are not natively portable.  If you want to move them you have to go through a process of Export and Import.  We will talk about that next time. 

Homework

 

  Homework:  No homework for this module.  Enjoy your Weekend!