Array Performance and Data Protection
1752286 Members
4451 Online
108786 Solutions
New Discussion юеВ

How to restore/clone a vm from vvol?

 
SOLVED
Go to solution
crobinso129
New Member

How to restore/clone a vm from vvol?

I am playing around with VVols and really like them so far. Too bad the max volume limit on Nimbles is so low since it will only allow me to get about half our VMs on to vvols.

I was looking at snapshots and storage policies and how to recover.

Currently with traditional VMFS data stores to recover a VM I do this:

Use the Nimble vCenter plugin to clone the data store from snapshot.

Shutdown and rename the VM in vcenter

start the VM from the cloned data store

vmotion it out

use the plugin to delete the data store and clone.

Now with VVols there is no options for the vvol data store in the plugin so can't do it that way.

snapshot manager on a vm shows no snaps

clone a vm doesn't have the snaps

I tried to clone the volume collection of the main config vvol of my vm but they then looked like normal volumes - not vvol volumes.

So the question is - how do you use nimble snapshots to restore a VM that is using vvols?

6 REPLIES 6
jcates98
Trusted Contributor
Solution

Re: How to restore/clone a vm from vvol?

Hi Cade,

With VMFS datastores, the workflow you describe above is ideal.  Because the datastore contains multiple VM's, we wouldn't just do a snapshot restore, as that would affect all of the other VMs on the datastore in addition to the one we were interested in. So we clone the datastore, import the VM, and then move it back to the original datastore with svmotion.

With VVols, we don't have this constraint since each VMDK is its own volume on the array.

The way to recover a VM from snapshot is to simply revert the volume(s) to that snapshot.  If you have a managed (taken from vSphere) snapshot, you can do this in the vSphere snapshot manager.  If the snapshots are created from the array side, which it sounds like the case here, you simply do the following:

  1. Power off the VM
  2. Revert volume snapshots on the array for all of the VVols associated with the VM. (Or selectively revert them, it's up to you.)
  3. Power on the VM

If you've deleted a VM, you can recover it within 24 hours by using the vm --restore command on the array.  Also, if you're not sure which volumes make up the VM, you can use the vm --list and vm --info commands to find out.

Cheers,

Julian

crobinso129
New Member

Re: How to restore/clone a vm from vvol?

Thanks for the info.

One issue with that we have run into (not often) is a developer will be working on something that day and screw up the DB or something and we have to revert.

I save the old "bad" vm in case they come back with needing new files on the old machine.  With the procedure of using an array snapshot as a new data store is I can keep the old vm for a couple days if I need to bring it backup to get stuff off it.

What about cloning from an array snapshot?

We will clone a prod datastore and VM to test an upgrade before we try prod.

Normally we just clone the nightly array snapshot, mount it, bring the VM up, test, delete.

I assume now we just clone when needed via vcenter?

Can you even clone the array snapshots as a new machine?

crobinso129
New Member

Re: How to restore/clone a vm from vvol?

Also sounds like a nice enhancement to the plugin.

Right click the VM, go to the nimble plugin, revert VM from array snapshot.

For that matter clone from snapshot too

cnelson45
New Member

Re: How to restore/clone a vm from vvol?

I also spoke to Nimble support, and in addition to Julian's steps they recommended removing the VM from inventory after you power it off. Then add it back to inventory after you finished restoring the snapshot.

  1. Power off the VM
  2. Remove from inventory
  3. Revert volume snapshots on the array for all of the VVols associated with the VM. (Or selectively revert them, it's up to you.)
  4. Add back to inventory
  5. Power on the VM

Regards,

Chad

marktheblue45
Valued Contributor

Re: How to restore/clone a vm from vvol?

The issue I'm having is how to revover individual files. Scenario: You have a VM backed by Vvols and a user has deleted some files. I don't want to completely restore the VM back to its last snap but just mount the snap to revover the files out of place. How is this done?

Regards,

               Mark.

mblumberg16
Respected Contributor

Re: How to restore/clone a vm from vvol?

Hi Mark,

The short answer: create a clone and map it to the VVol VM via RDM, you will need to set a VMFS datastore for the descriptor but that is the quickest way.

Steps:

Create a clone from the snapshot you need.

Apply ACL (select the same as the VVol VM or an initiator group that has the ESX host iqn in it).

Rescan the ESX host.

Edit the VVol VM ( or any other VM you want to add the volume to ).

Add new device: RDM Disk

Select the new device (tip:  eui = volume serial number )

You can't complete at this point as the pointer requires a VMFS datastore:

   Expend the new RDM.

   Location: store with virtual machine >> expend and select browse >> select VMFS datastore.   (this is a VMware limitation)

On the guest OS, open disk mgmt and online the new device, this will mount the volume.

Let me know if it worked for you.

Thanks,

Moshe.