Using Windows VSS for virtual machine backup

The goal of virtual machine backup is to create and store an exact copy of a VM. But when changes occur during the backup process, you need Windows VSS to ensure consistency.

When it comes to virtual machine backup, consistency is key. Ideally, a virtual machine (VM) disk file will copy

to its backup service exactly, with identical VM data. But because slight changes can occur during this process, Windows Volume Shadow Copy Service (VSS) helps retain much-needed consistency.

Virtual machine backup methods
To keep virtual machine backup data consistent, you need a mechanism to quiesce the file system and any applications. For Windows computers, the mechanism that enables consistency is the Windows VSS. But before Windows VSS comes into play, you should consider the various virtual machine backup methods.

There are all sorts of locations from which you can source virtual machine backup. You can install an agent directly into a VM’s operating system and gather its individual files and folders one by one. This virtual machine backup method uses the same architecture that you’ve used on physical machines forever.

An alternative method for virtual machine backup is to install an agent not into a VM, but instead to a VM’s host. Locating the virtual machine backup agent on a host means gathering each VM’s Virtual Machine Disk Format (VMDK) or virtual hard disk (VHD) file all at once. Rather than collecting individual files, you’re getting an entire copy of a VM at a specific point in time.

With this VM backup method, it’s especially important that for consistency of VM copies. Backing up a VM from a specific point in time requires the coordination of a range of independent components, both on the host as well as inside the VM. It takes time to copy a VMDK or VHD file from disk to your virtual machine backup service. During this interval, the disk file probably experiences some changes in its data. You want to manage these changes to ensure a consistent view of the server, always sourcing every part of the VM backup from the same moment in time.

The confusing components of Windows VSS
Windows VSS has been around for a long time. It was originally used to restore previous versions of documents users had accidentally deleted or modified. In virtual infrastructures, Windows VSS coordinates the quiescence (or “quieting”) process that keeps host-based virtual machine backup consistent.

Windows VSS has multiple components that must coordinate for the VM backup process to complete successfully. You should be familiar with these components, because each is required for a successful backup, but not all are automatically available depending on the backup technology you choose.
 
There are four major components to Windows VSS. Most of the confusion surrounding these components involves their similar naming; however, each has a specific role to play in virtual machine backup.

First up is the VSS writer. Any Windows computer has one or more VSS writers installed. Each VSS-aware application installs its own VSS writer to a computer during the initial installation. These applications can be Active Directory Domain Services, Microsoft Exchange and SQL Server, or even third-party software from vendors such as Oracle.

Your Windows server must have a VSS writer for each transaction-based application you want to back up. By entering the command vssadmin list writers, you can see which writers have been installed.

The next Windows VSS component is the VSS requestor. A requestor can be, among other things, your backup application. Essentially, any application that needs to quiesce data for capture can play the role of VSS requestor.

The VSS provider is the third component. Its job is to create and manage the shadow copies, sometimes called snapshots, of data on the system. The operating system, combined with its onboard file system, is enabled with a VSS provider. Additional VSS providers can arrive from hardware providers on an external storage array.

Finally, combining the activities of those three components is the Volume Shadow Copy Service itself. The Windows VSS handles the orchestration between components and logically sits in the center of the other pieces.

Using Windows VSS for virtual machine backup
A carefully choreographed series of events occurs when the virtual machine backup process begins. First, the VSS requestor announces that it needs to create a server snapshot. Prior to creating that snapshot, it queries the server to determine which VSS writers have been installed. It needs this list so it can later instruct each writer to quiesce its associated application.

Then, the VSS requestor instructs each VSS writer to accomplish whichever task is needed for data quiescence. This is an important function in the Windows VSS multipart arrangement, because different applications have different means for quiescence.

After each VSS writer reports that it has completed pre-backup tasks, the VSS requestor then instructs the VSS provider to create a snapshot. A provider tells the requestor where to go to locate the VM backup data it needs. Then the virtual machine backup begins.

Once the VM backup is complete, the VSS requestor announces that it has completed its activities. This announcement instructs each VSS writer to accomplish any post-backup tasks necessary to return the server and its applications to regular operation.

This careful orchestration of Windows VSS components is critical for strong virtual machine backup strategies. It’s also important to know that your backup vendor should install the necessary components into each VM. Lacking the proper coordination could mean that VM backup data is inconsistent or corrupted. Pay careful attention to your backup data, and perform test restores to ensure that your virtual machine backup service gathers data that is usable once restored.

This was first published in February 2011

Dig deeper on Virtual server backup and storage

Pro+

Features

Enjoy the benefits of Pro+ membership, learn more and join.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

SearchVMware

SearchWindowsServer

SearchCloudComputing

SearchVirtualDesktop

SearchDataCenter

Close