Index  |  Top  -  Up Data ONTAP 8.3

volume snapshot restore-file

Restore a file from a snapshot

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

Description

The volume snapshot restore-file command enables you to restore a single file to a version saved in the Snapshot copy. You can restore a file over an existing copy of the file in the parent read-write volume or to a different location within the same parent read-write volume. If the destination file for the restore operation does not exist, a new file is created with the same version as the one saved in the Snapshot copy. If the destination file for the restore operation exists, then it is overwritten by the version from the Snapshot copy. This operation is used to restore normal user-level files and LUNs. The command fails if you try to restore directories (and their contents) and files with NT streams. During the restore operation the parent read-write volume should remain online. The command fails if the destination path for the restore operation is in a different volume than the source volume.

This command is not supported on Infinite Volumes.

Parameters

-vserver <vserver name> - Vserver Name

This specifies the Vserver which contains the volume.

[-volume <volume name>] - Volume Name

This specifies the volume which contains the specified Snapshot copy.

-snapshot | -s <snapshot name> - Snapshot Name

This specifies the Snapshot copy from which the file is restored.

-path <text> - Filepath

This specifies the relative path to the file which is restored from the Snapshot copy. You should specify the -volume option so that the file is searched and restored from the Snapshot copy of the specified volume. If you do not specify the -volume then the file is searched and restored from the Snapshot copy of the root volume.

[-restore-path | -r <text>] - Restore Filepath

This option specifies the destination location inside the volume where the file is restored. If you do not specify this option, the file is restored at the same location referred by -path option. If you specify -restore-path option, then it should refer to a relative path location within the same volume which contains the source file. If you do not specify -volume along with the relative path, the file is restored in the root volume.

[-split-disabled [true]] - Disable Space Efficient LUN Splitting

If you use this option and set it to true, space efficient LUN clone split is not allowed during the restore operation. If you use this option and set it to false or do not use this option, then space efficient LUN clone split is allowed during the restore operation.

Examples

The following example restores a file foo.txt from the Snapshot copy vol3_snap inside the volume vol3 contained in a Vserver vs0:
cluster1::> volume snapshot restore-file -vserver vs0 -volume vol3 -snapshot vol3_snap -path /foo.txt

Index  |  Top  -  Up Data ONTAP 8.3

Copyright © 1994-2015 NetApp, Inc. Legal Information