Windows IT Pro is the leading independent community for IT professionals deploying Microsoft Windows server and client applications and technologies.
  
  
  Advanced Search 


September 30, 2008

Q. What happens when I take a Hyper-V virtual machine (VM) snapshot?

RSS
Subscribe to Windows IT Pro | See More Backup and Recovery Articles Here | Reprints | Or get the Monthly Online Pass—only $5.95 a month!

A. Before we talk about snapshots, you need to understand a type of virtual hard disk (VHD) called a differencing disk. A differencing disk is an additional VHD file that effectively sits on top of another VHD file and works with the existing VHD. Any write operations are written to the differencing disk, so that no changes are made to the existing VHD. Read operations are first checked against the differencing disk to see whether updated content was written to the differencing disk; if the content isn’t in the differencing disk, then the content is read from the additional VHD. This setup effectively freezes any changes to existing content by storing changes separately on the differencing disk.

Let’s start with a snapshot of an offline virtual machine (VM)—that is, a VM that’s turned off. When you take a snapshot of an offline VM, to avoid any changes to the existing VHD file, the snapshot process creates a differencing disk in a new subfolder of the VM’s Snapshots folder; the subfolder’s name includes the VM’s globally unique identifier (GUID). The name of the differencing disk includes the snapshot’s GUID and the extension .avhd. In addition, a copy of the current configuration is stored in the VM’s Snapshots folder; the configuration filename contains the snapshot’s GUID.

If the VM is running (i.e., online) when the snapshot is taken, two additional files are created in a Snapshots subfolder (named with the snapshot’s GUID) containing two files: a .bin file that contains the contents of the VM’s memory and a .vsv file that contains supporting process information, as the following screenshot shows.

This means that when you restore back to a snapshot’s state, not only the disk is restored to the previous point in time but also the VM’s memory and any processes that were supporting its operation. The next screenshot shows the memory and process content and the .avhd files used by the snapshots.

If you create additional snapshots, the process is exactly the same: A new .avhd file is created, which is a differencing file over the differencing file currently being used since the last snapshot. (A bit confusing, I know!) The following screenshot shows the new snapshot.

If you delete a snapshot, then Windows deletes memory and process files and rolls the content of any differencing disks into the preceding VHD the next time the VM is shut down.

End of Article



Reader Comments

You must be a registered user or online subscriber to comment on this article. Please log on before posting a comment. Are you a new visitor? Register now




Top Viewed ArticlesView all articles
Command Prompt Tricks

One reader shares his tip for setting up the command prompt to reflect a remote path. ...

2009 Windows IT Pro Editors' Best and Community Choice Awards

Picking a favorite product from an impressive crowd of competitive offerings is never an easy task, and such was the case with our Editors' Best and Community Choice awards this year. ...

WinInfo Short Takes: Week of November 23, 2009

An often irreverent look at some of the week's other news, including some post-PDC some soul searching, a Google Chrome OS announcement and a Microsoft response, Windows 7 off to a supposedly strong start, the Jonas Brothers and Xbox 360, and so much more ...


Virtualization Whitepapers A Business Case for Backup & Recovery for The Virtualized Environment

Related Events VirtualizationPro 2010 Summit & Expo

Deep Dive into VMware vSphere

Backup – The Backbone of Your Business

Check out our list of Free Email Newsletters!

Windows OSs eBooks Understanding and Leveraging Code Signing Technologies

A Guide to Windows Certification and Public Keys

SQL Server Administration for Oracle DBAs

Related Windows OSs Resources Introducing Left-Brain.com, the online IT bookstore
Looking for books, CDs, toolkits, eBooks? Prime your mind at Left-Brain.com

Discover Windows IT Pro eLearning Series!
Clear & detailed technical information and helpful how-to's, all in our trademark no-nonsense format


Windows IT Pro Home Register FAQ for Windows WinInfo News
Europe Edition About Us Contact Us/Customer Service Media Kit Affiliates / Licensing  
SQL Server Magazine Office & SharePoint Pro DevProConnections IT Job Hound
Left-Brain.com Technology Resource Directory asp.netPRO ITTV Windows SuperSite 
 
 Windows IT Pro is a Division of Penton Media Inc.
 © 2009 Penton Media, Inc. Terms of Use | Privacy Statement