Skip to main content
A newer release of this product is available.

snapmirror protect

Contributors
Suggest changes

Start protection for volumes

Availability: This command is available to cluster and Vserver administrators at the admin privilege level.

Description

The snapmirror protect command establishes SnapMirror protection for a list of volumes. For each volume, the command creates a data protection destination volume in the Vserver specified by the -destination-vserver parameter, creates an extended data protection (XDP) SnapMirror relationship, and starts the initialization of the SnapMirror relationship. This command must be used from the destination Vserver or cluster. This command is not supported for Infinite Volumes or Infinite Volume constituents, FlexGroup volumes or FlexGroup volume constituents, Vserver endpoints or non ONTAP endpoints.

Parameters

-path-list {<[vserver:][volume]>|<[[cluster:]//vserver/]volume>|<hostip:/lun/name>|<hostip:/share/share-name>} - Path List

This parameter specifies the list of volumes to be protected. The list is a comma separated list of paths of the form vserver:volume , for example vs1.example.com:dept_eng1, vs1.example.com:dept_eng2

[-destination-vserver <vserver name>] - Destination Vserver

This parameter specifies the Vserver in which to create the destination volumes of the SnapMirror relationships.

[-schedule <text>] - SnapMirror Schedule

This optional parameter designates the name of the schedule which is used to update the SnapMirror relationships.

-policy <sm_policy> - SnapMirror Policy

This parameter designates the name of the SnapMirror policy which is associated with the SnapMirror relationships.

[-auto-initialize {true|false}] - Auto Initialize

This optional parameter specifies whether or not initializes of the SnapMirror relationships should be started after the relationships are created. The default value for this parameter is true .

[-destination-volume-prefix <text>] - Destination Volume Name Prefix

This optional parameter designates the prefix for the destination volume name. For example if the source path is of the form vserver:volume and the destination-volume-prefix specified is prefix and no destination-volume-suffix is specified, then the destination volume name will be _prefix_volume_dst or possibly prefix_volume_1_dst if a name conflict is encountered. If both prefix and suffix are specified as prefix and __suffix , then the destination volume name will be prefix_volume_suffix or prefix_volume_1_suffix , if a name conflict is encountered.

[-destination-volume-suffix <text>] - Destination Volume Name Suffix

This optional parameter designates the suffix for the destination volume name. If you do not desginate a suffix, a destination volume name with suffix dst_ will be used. For example if the source path is of the form vserver:volume , and the suffix specified is DP_ , the destination volume will be created with the name volume_DP or volume_1_DP if a name conflict is encountered. If both prefix and suffix are specified as prefix and suffix , then the destination volume name will be prefix_volume_suffix or prefix_volume_1_suffix , if a name conflict is encountered.

Examples

To establish SnapMirror protection for the source volumes vs1.example.com:dept_eng1 and vs1.example.com:dept_eng2 using destination-vserver vs2.example.com and policy MirrorAllSnapshots type the following command:

vs2.example.com::> snapmirror protect -path-list
       vs1.example.com:dept_eng1,vs1.example.com:dept_eng2 -destination-vserver
       vs2.example.com -policy MirrorAllSnapshots