Skip to main content

Access a read-only LUN copy from a SnapVault backup

Contributors netapp-aherbin

You can access a read-only copy of a LUN from the latest Snapshot copy in a SnapVault backup. The LUN ID, path, and serial number are different from the source LUN and must first be mapped. Persistent reservations, LUN mappings, and igroups are not replicated to the SnapVault secondary volume.

What you'll need
  • The SnapVault relationship must be initialized and the latest Snapshot copy in the SnapVault secondary volume must contain the desired LUN.

  • The storage virtual machine (SVM) containing the SnapVault backup must have one or more LIFs with the desired SAN protocol accessible from the host used to access the LUN copy.

  • If you plan to access LUN copies directly from the SnapVault secondary volume, you must create your igroups on the SnapVault SVM in advance.

    You can access a LUN directly from the SnapVault secondary volume without having to first restore or clone the volume containing the LUN.

About this task

If a new Snapshot copy is added to the SnapVault secondary volume while you have a LUN mapped from a previous Snapshot copy, the contents of the mapped LUN changes. The LUN is still mapped with the same identifiers, but the data is taken from the new Snapshot copy. If the LUN size changes, some hosts automatically detect the size change; Windows hosts require a disk rescan to pick up any size change.

Steps
  1. Run the lun show command to list the available LUNs in the SnapVault secondary volume.

    In this example, you can see both the original LUNs in the primary volume srcvolA and the copies in the SnapVault secondary volume dstvolB:

    cluster::> lun show
    
    Vserver   Path                State   Mapped   Type          Size
    --------  ------------------  ------  -------  --------      -------
    vserverA  /vol/srcvolA/lun_A  online  mapped   windows  300.0GB
    vserverA  /vol/srcvolA/lun_B  online  mapped   windows  300.0GB
    vserverA  /vol/srcvolA/lun_C  online  mapped   windows  300.0GB
    vserverB  /vol/dstvolB/lun_A  online  unmapped windows  300.0GB
    vserverB  /vol/dstvolB/lun_B  online  unmapped windows  300.0GB
    vserverB  /vol/dstvolB/lun_C  online  unmapped windows  300.0GB
    
    6 entries were displayed.
  2. If the igroup for the desired host does not already exist on the SVM containing the SnapVault secondary volume, run the igroup create command to create an igroup.

    This command creates an igroup for a Windows host that uses the iSCSI protocol:

    cluster::> igroup create -vserver vserverB -igroup temp_igroup
      -protocol iscsi -ostype windows
      -initiator iqn.1991-05.com.microsoft:hostA
  3. Run the lun mapping create command to map the desired LUN copy to the igroup.

    cluster::> lun mapping create -vserver vserverB -path /vol/dstvolB/lun_A
      -igroup temp_igroup
  4. Connect the host to the LUN and access the contents of the LUN as desired.