Using VNX Snapshots on Windows

In Block OE version 32 EMC introduced new snapshot functionality VNX Snapshots, very slick technology that simplifies the process of creating snapshots for block storage. There are lot of benefits in using VNX Snapshots versus legacy Snapview Snapshots (no need for RLP, no COFW ..etc). You can read about it in the following two documents:

http://www.emc.com/collateral/software/white-papers/h10858-vnx-snapshots-wp.pdf

https://support.emc.com/docu45754_SnapCLI_for_VNX_Release_Notes_Version_3.32.0.0.5.pdf?language=en_US

https://support.emc.com/docu41553_VNX-Command-Line-Interface-Reference-for-Block.pdf?language=en_US

These papers provide a lot of good information about the technology and some examples. I found some example kind of confusing so i wanted to provide my own examples. Overall goal was to allow my customer to create/delete/mount snapshots without needing to issue naviseccli commands.

Configuration:

VNX 5700 – Block OE 05.32.000.5.206

2 Windows 2008 R2 servers

SnapCLI – V3.32.0.0.5 – 1 (32 bits)

Naviseccli – 7.32.25.1.63

2 storage groups

stg-group1

stg-group2

1) First step we need to install snapcli on both Windows servers, nothing special there, next next Done
2) Next we need to create SMP (Snapshot Mount Point) and present it to stg-group2. Think of SMP as a placeholder device that will be used to attach snapshot to. On a management host where i have naviseccli installed i run the following command. You want to specify “allowInbandSnapAttach” option as that will allow you to attach snapshot on target host using snapcli, otherwise you would have to use naviseccli to attach it. Since our goal is to have customer only use snapcli that’s exactly what we need. LUN 353 is owned by SPA hence -spa A.

C:\>naviseccli -address 10.210.6.19 lun -create -type Snap -primaryLunName "LUN 353" -name SMP_LUN_353 -allowInbandSnapAttach yes -sp A

Now let’s see what SMP looks like and note snapshot mount point number

C:\>naviseccli -address 10.210.6.19 lun -list -l 353 -snapMountPoints
LOGICAL UNIT NUMBER 353
Name: LUN 353
Snapshot Mount Points: 7533

3) Now we need to add SMP to storage stg-group2, note alu is the snapshot mount point point number and since there are no LUNs in the storage group we are using hlu 0

C:\>naviseccli -address 10.210.6.19 storagegroup -addhlu -gname stg-group2 -alu 7533 -hlu 0

If we were to look in Disk Management and rescan, we would see “Unknown” disk in offline state.

smpview

4) At this point we are ready to create snapshot, on source system we flush any data in memory to disk and then create snapshot

C:\>snapcli flush -o F:

C:\>snapcli create -s "Snapshot_LUN_353" -o F:
Attempting to create snapshot Snapshot_LUN_353 on device \\.\PhysicalDrive1.
Attempting to create the snapshot on the entire LUN.
Created snapshot Snapshot_LUN_353.

5) Now on target system we are going to attach snapshot

C:\>snapcli attach -s "Snapshot_LUN_353" -f -d F:
Scanning for new devices.
User specified drive letter F:
Attached snapshot Snapshot_LUN_353 on device F:.

At this point if we look in Disk Management again the drive should be online and available

snapmounted
6) When you are done with snapshot we need to flush it and detach it, on target server we run these commands

C:\>snapcli flush -o F:
Flushed F:.

C:\>snapcli detach -s "Snapshot_LUN_353"
Detaching snapshot Snapshot_LUN_353 on device F:.

7) And finally delete the snapshot, on source server run

C:\>snapcli destroy -s "Snapshot_LUN_353" -o F:
Destroyed snapshot Snapshot_LUN_353 on object F:.