ONTAP 9.15.1 commands

snapmirror delete

Delete a SnapMirror relationship

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

Description

The snapmirror delete command removes the SnapMirror relationship between a source endpoint and a destination endpoint. The destination endpoint can be a Vserver, a volume, an Application Consistency Group, or a non-Data ONTAP endpoint. The Vservers, volumes, FlexVol volumes of the Consistency Group and non-Data ONTAP destinations are not destroyed and Snapshot copies on the volumes are not removed.

For relationships with SolidFire endpoints, the SnapMirror source commands snapmirror release and snapmirror list-destinations are not supported. Therefore, Snapshot copies that are locked by SnapMirror on the source container cannot be cleaned up using the snapmirror release command. If the source container is a Data ONTAP volume, in order to reclaim space captured in the base Snapshot copy on the volume, issue a snapshot delete command specifying the -ignore-owners parameter in diag privilege level. To reclaim space captured in a Snapshot copy locked by SnapMirror on a SolidFire system, refer to SolidFire documentation.

The snapmirror delete command fails if a SnapMirror transfer for the SnapMirror relationship is in progress for relationships "9.7 and above" capability the delete will succeed even if a transfer is in progress and the transfer will ultimately stop.

A set of load-sharing mirrors can contain multiple destination volumes, each destination volume having a separate SnapMirror relationship with the common source volume. When used on one of the SnapMirror relationships from the set of load-sharing mirrors, the snapmirror delete command deletes the specified SnapMirror relationship from the set of load-sharing mirrors.

The snapmirror delete command preserves the read-write or read-only attributes of the volumes of a SnapMirror relationship after the relationship is deleted. Therefore, a read-write volume that was the source of a SnapMirror relationship retains its read-write attributes, and a data protection volume or a load-sharing volume that was a destination of a SnapMirror relationship retains its read-only attributes. Similarly, the subtype attribute of source and destination Vservers is not modified when a Vserver SnapMirror relationship is deleted.

When a SnapMirror relationship from a set of load-sharing mirrors is deleted, the destination volume becomes a data protection volume and retains the read-only attributes of a data protection volume.

For relationships with a policy of type strict-sync-mirror or sync-mirror , the relationship must be Quiesced before it can be deleted.

This command is supported for SnapMirror relationships with the field "Relationship Capability" showing as either "9.7 and above" in the output of the snapmirror show command.

For relationships with "Relationship Capability" of "9.7 and above" , the snapmirror delete command must be used from the destination Vserver or cluster. The SnapMirror relationship information is deleted from the destination Vserver, but no cleanup or deletion is performed on the source Vserver. The snapmirror release command must be issued on the source Vserver to delete the source relationship information.

Parameters

{ [-S, -source-path {<[vserver:][volume]>|<[[cluster:]//vserver/]volume>|<hostip:/lun/name>|<hostip:/share/share-name>|<[vserver:]/cg/[app-cgname]>}] - Source Path

This parameter specifies the source endpoint of the SnapMirror relationship in one of four path formats. The normal format includes the names of the Vserver (vserver) and/or the volume (volume). For SnapMirror relationships with an AltaVault source, the source endpoint is specified in the form hostip:/share/share-name . For SnapMirror relationships with a SolidFire source, the source endpoint is specified in the form hostip:/lun/name .

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

Specifies the source cluster of the SnapMirror relationship. If this parameter is specified, the -source-vserver and -source-volume parameters must also be specified.

[-source-vserver <vserver name>] - Source Vserver

Specifies the source Vserver of the SnapMirror relationship. For relationships with volumes as endpoints, if this parameter is specified, parameters -source-volume and for relationships with "Relationship Capability" of "Pre 9.7" , -source-cluster must also be specified. This parameter is not supported for relationships with non-Data ONTAP source endpoints.

[-source-volume <volume name>] - Source Volume }

Specifies the source volume of the SnapMirror relationship. This parameter is not supported for relationships with non-Data ONTAP source endpoints.

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

This parameter specifies the destination endpoint of the SnapMirror relationship in one of four path formats. The normal format includes the names of the Vserver (vserver) and/or volume (volume). For SnapMirror relationships with AltaVault destinations, the destination endpoint is specified in the form hostip:/share/share-name . For relationships with SolidFire destinations, the destination endpoint is specified in the form hostip:/lun/name .

| [-destination-cluster <Cluster name>] - Destination Cluster

Specifies the destination cluster of the SnapMirror relationship. If this parameter is specified, parameters -destination-vserver and -destination-volume must also be specified. This parameter cannot be specified when operating in a Vserver context on relationships with "Relationship Capability" of "9.7 and above" .

-destination-vserver <vserver name> - Destination Vserver

This parameter is not supported for relationships with non-Data ONTAP destination endpoints.

-destination-volume <volume name> - Destination Volume }

This parameter is not supported for relationships with non-Data ONTAP destination endpoints.

[-f, -force <true>] - Force

If specified, the delete proceeds even if it cannot clean up all artifacts of the relationship.

Examples

To delete the SnapMirror relationship with the destination endpoint vs2.example.com:dept_eng_dp_mirror4 , type the following command:

vs2.example.com::> snapmirror delete -destination-path
       vs2.example.com:dept_eng_dp_mirror4

To delete the SnapMirror relationship with destination endpoint dvs1.example.com: , type the following command:

cluster2::> snapmirror delete -destination-path
   dvs1.example.com:

To delete the SnapMirror active sync relationship with the destination Consistency Group cg_dst in Vserver vs2.example.com , type the following command from the destination cluster:

destination::> snapmirror delete -destination-path
        vs2.example.com:/cg/cg_dst

To delete the Application Consistency Group SnapMirror relationship with the destination Application Consistency Group app_cg_dst in Vserver vs2.example.com and all item mappings, type the following command:

vs2.example.com::> snapmirror delete -destination-path
            vs2.example.com:/cg/app_cg_dst
Top of Page