Virtualization

VMware create and restore group snapshots multiple VMs at once

If you have a lab environment or other “application stack” specific multiple VMs, there can arise the need to create and restore snapshots in unison or in a “group” fashion. This is easily accomplished with PowerCLI. Also, in playing around recently with Virtual Volumes or VVOLs and the Dell Equallogic Storage Manager appliance, you can also create “group” virtual machine snapshots using the vCenter web interface and using the Dell VSM vCenter plugin.

Let’s take a look at how we can create a particular named snapshot for multiple VMs using PowerCLI. First things first, we need to logically group the VMs into a folder which allows us to specify a location using PowerCLI as the snapshot creation source.

Creating the Multi VM snapshot

So after creating a folder called testclone and moving my VMs into this particular folder, I can use this as the location to create a multi-vm snapshot:

get-vm -location "testclone" | new-snapshot -Memory -quiesce -name "testmulticlone"

Restoring the Multi VM snapshot

get-vm -location "testclone" | set-vm -snapshot "Testmulticlone" -confirm:$false

Using the Dell Virtual Storage Manager

If you are using the Dell VSM plugin integrated into vCenter, you have the multiVM snapshot available using the builtin functionality of the VSM plugin. Steps to create the multiVM snapshot:

vvol_snap

  1. Select the newly created folder; testclone
  2. Select the Manage tab
  3. Select the Dell VSM button
  4. Select Snapshots
  5. Finally, click on Create Snapshot icon.

From this view there are also options for creating Snapshot Schedules, and any existing snapshot of the selected object whether initiated by VMware or VSM will be listed, and a restore can be initiated.

Alternative path to launching the Create Snapshot wizard:

  1. Select the newly created folder; testclone
  2. Click on the Actions dropdown menu
  3. Click on All Dell VSM Actions
  4. Click on Create Snapshot

Also, the really great thing about the VSM if you are using VVOLs for storage, the snapshot overhead is totally offloaded to the SAN itself. So you no longer have to wait minutes or longer for the snapshot to complete. This process can now take seconds. Also, with VVOLs, there is no longer a performance overhead for having snapshots allocated to a virtual machine.

Final Thoughts

Creating multi VM snapshots can be a very handy tool to use especially in lab environments, where you want to keep rollbacks of multiple machines in sync. It can also be useful in production if a set of VMs are application stack specific and rely on each other. Using PowerCLI this functionality is available to us. Also, keep in mind that with VVOLs and using 3rd party integration such as the Dell Virtual Storage Manager, you also have access to this functionality as well.