Skip to main content

snapmirror protect

Contributors
Suggest changes

Start protection for Vservers and 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 the specified Vserver or a list of volumes. For each endpoint, the command creates a data protection destination endpoint 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 FlexGroup volume constituents or non ONTAP endpoints. When source volumes are specified they must be read-write (RW) volumes.

Parameters

[-source-cluster <Cluster name>] - Source Cluster

This optional parameter specifies the source cluster name. This parameter is valid only when only a single Vserver is specified in the path-list parameter.

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

This parameter specifies the list of source endpoints to be protected. The list is a comma separated list of paths of the form vserver:volume or vserver: , for example vs1.example.com:dept_eng1, vs1.example.com:dept_eng2 or vs1.example.com: . If the list contains a Vserver endpoint, then the Vserver is the only endpoint that can be specified, and the list cannot contain a mixture of volume and Vserver endpoints.

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

This parameter specifies the Vserver in which to create the destination volumes of the SnapMirror relationships. When protecting a single Vserver, this parameter specifies the destination Vserver endpoint for protection.

[-destination-vserver-ipspace <IPspace>] - Destination Vserver IPSpace Name

This optional parameter specifies the IPspace the Vserver will be assigned to. If left unspecified, the Vserver will be assigned to the default IPspace. This parameter is supported while protecting a Vserver.

[-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. This parameter is not supported for Vserver endpoints.

[-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. This parameter is not supported for Vserver endpoints.

[-support-tiering {true|false}] - Provision Destination Volumes on FabricPools

This optional parameter specifies whether or not FabricPools are selected when provisioning a FlexVol volume or a FlexGroup volume during protection workflows. When this parameter is set to true, only FabricPools are used; when set to false, only non-FabricPools are used. Tiering support for a FlexVol volume can be changed by moving the volume to the required aggregate. Tiering support for a FlexGroup volume can be changed by moving all of the constituents to the required aggregates. The default value is false . This parameter is supported only for FlexVol volumes and FlexGroup volumes.

[-tiering-policy <Tiering Policy>] - Destination Volume Tiering Policy

This optional parameter specifies the tiering policy to apply to the destination FlexVol volume or FlexGroup volume. This policy determines whether the user data blocks of a FlexVol volume or FlexGroup volume in a FabricPool will be tiered to the capacity tier when they become cold. FabricPool combines flash (performance tier) with an object store (external capacity tier) into a single aggregate. The default tiering policy is 'snapshot-only' for a FlexVol volume and 'none' for a FlexGroup volume. The temperature of a FlexVol volume or FlexGroup volume block increases if it is accessed frequently and decreases when it is not.

The available tiering policies are:

  • snapshot-only - This policy allows tiering of only the FlexVol volume or FlexGroup volume Snapshot copies not associated with the active file system. The default minimum cooling period is 2 days. The -tiering-minimum-cooling-days parameter can be used to override the default using the volume modify command after the destination FlexVol volume or FlexGroup volume has been created.

  • auto - This policy allows tiering of both snapshot and active file system user data to the capacity tier. The default cooling period is 31 days. The -tiering-minimum-cooling-days parameter can be used to override the default using the volume modify command after the destination FlexVol volume or FlexGroup volume has been created.

  • none - FlexVol volume or FlexGroup volume blocks will not be tiered to the capacity tier.

  • backup - On a DP FlexVol volume or FlexGroup volume this policy allows all transferred user data blocks to start in the capacity tier.

This parameter is supported only for FlexVol volumes and FlexGroup volumes.

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

To establish SnapMirror protection for the source Vserver vs1.example.com which is on cluster cluster1 creating a destination-vserver named vs1dp.example.com and using policy MirrorAllSnapshots type the following command:

cluster2::> snapmirror protect -source-cluster cluster1 -path-list vs1.example.com: -destination-vserver vs1dp.example.com -policy MirrorAllSnapshots