With traditional data backup strategies, IT admins safeguard users’ data, verify the integrity of the backed-up data and, after a failure, pray for a successful restore. But virtualization has introduced a flurry of new data backup strategies for the entire virtual machine (VM). Let’s take a look at some practical -- and free -- approaches to virtual server backup.
From traditional backup to VM backup
In a conventional, full OS backup, data residing within the logical confines of its medium (on disk, for instance) streams to a certain type of media (either physical or virtual), where it’s then verified, indexed and archived. With virtual server backup, we can take traditional data backup strategies a step further and move outside the confines of the logical disk to the physical disk files themselves.
By backing up and recovering a complete set of disk files (and depending on your hypervisor, their associated configuration files), you can recover an exact copy of the VM. With this virtual server backup method, the disks re-associate to the guest, and in no time you’re back in business.
You can combine several virtual server backup techniques into a complete strategy and take advantage of most through the free tools in your hypervisor:
VM snapshots. In development environments, snapshots are useful for virtual server backup, but they should be used with caution in production. Common problems with snapshots include their constant growth with deltas and the possibility of corruption. Vendors will be the first to tell you that snapshots are not meant to be a complete virtual server backup strategy. VMware and Microsoft, for example, have steered admins away from using only snapshots for virtual server backup.
Scripting. By scripting and scheduling your VM disk backups, you can circumvent the cost of a commercial backup application and incorporate other scripted tasks into your routine. Scripting can cause downtime, but admins have gotten around this limitation by combining snapshots with scripting.
If you take a hot snapshot of a VM and script the backup of the snapshot disk files, you won’t experience downtime. A great VM backup tool using this combo method is the ghettoVCB project for VMware, which is free and actively developed. There are also PowerShell scripts that work similarly with Microsoft Hyper-V.
Integrated or modular backup tools. The backup utility integrated with Windows Server 2008 R2, called Windows Server Backup, is now considered “virtual friendly” and works with the Windows VSS writer component. This modular tool facilitates Hyper-V virtual server backup, but I’ve heard varying success stories about it so far.
The VMware Data Recovery virtual appliance has limitations as well. This VM backup tool is good for small environments, but it isn’t yet ready for large enterprises. Citrix Systems XenS erver has integrated command-line tools for data backup, but it relies heavily on third-party products for a complete virtual server backup strategy.
Flat-file copy. Yes, I really do think flat-file copying is a viable option for virtual server backup. Many shops use this VM backup method religiously, some very successfully. It’s a scripting strategy, but it’s flexible because it doesn’t have to be scripted with PowerCLI, PowerShell, Bash or VBScript.
Using the internal scheduled task function of the OS, hypervisor or file-copy tool, you can power off a VM and run a command-line utility to copy the files to another medium. Depending on your hypervisor, you can use Robocopy, FastSCP, rsync, SyncToy or even a Linux dd or tar command. VMware and Microsoft Hyper-V have built-in scheduled tasks, but timing is everything, so admins should carefully investigate this VM backup strategy if they want to control file copying.
You may notice that I did not mention storage-based snapshots as an option for virtual server backup. That’s because this technology comes with a price tag. Most mass storage vendors offer integrated tools or add-on products that supply backup at the shared-storage level rather than at the hypervisor or OS level. For a complete virtual server backup strategy, you can use deduplication and replication along with storage-based snapshots. But, again, it’s not free, and it may not even be practical in your infrastructure.
Some admins continue to use physical-world data backup strategies for virtual backup. Others want new ways to back up not only the OS but also the entire VM. A virtual server backup strategy is heavily dependent on your infrastructure, so some or none of these VM backup methods may be useful to you. Still, having an understanding of different options is always another notch in the career belt that can take you places.