vxsnap restore

Uses the snapshot volumes in a snapshot set created by the vxsnap create command to restore data, for example, after an original volume has become corrupted.

You can restore the data either to the point in time that the snapshot set was last refreshed or to the point of failure.

Before using this command, make sure that the source volumes and the snapshot volumes are not in use.

Use the [-a] attribute to dismount and mount the database automatically or use exchange to dismount and mount the database before and after the restore operation respectively.

For a VCS cluster setup, specifying the -a option offlines the VCS resource database before a restore operation and onlines the resource after restore operation.

Note:

After completing a point of failure (POF) recovery of a database, Veritas recommends using the vxsnap reattach command to reattach and resynchronizing the log volumes. You can then use the vxsnap create command to create a new snapshot set.

Syntax

The vxsnap restore command has the following syntax:

  vxsnap -x <filename>[-f][-b][-r] [-a] restore
   restoreType=<PIT|POF>writer=<writername>[subComponent=<subCompo
   nentName>][RSG=<Yes|No>]

Note:

The Subcomponent and RSG=Yes|No options for restore are not valid for Exchange 2010.

Attributes

The vxsnap restore command has the following attributes:

-x <Filename>

The file created by the vxsnap create command. Each snapshot set must have a unique name for the metadata file.

-f

Forces the snapback. Make sure the volume is not in use by another application before using this command. Use this option with care.

-b

Resynchronizes the volume in the background. A new snapshot cannot be made until the resynchronization is complete.

-r

Recover one or more of the original volumes that are missing. Example below shows additional required steps.

-a

Use the [-a] attribute to dismount and mount the database automatically.

For a VCS cluster setup, specifying the -a option offlines the VCS resource database before a restore operation and onlines the resource after restore operation.

restoreType=<PIT|POF>

PIT specifies a restore to the point in time that the snapshot set was created or last refreshed.

POF specifies a roll-forward recovery to the point of failure.

writer=<WriterName>

Unique ID of the VSS writer, for example, "Microsoft Exchange Writer" or the GUID for the writer.

If you specify the POF option, you must specify the writer.

subComponent=<subComponentName>

Note:

The subcomponent attribute is not valid for Exchange 2010.

[RSG=<Yes|No>]

Exchange 2007 only.

Yes restores the snapshot set to a recovery storage group (RSG). In order to restore to an RSG, the RSG for that storage group must already exist, and databases created inside the RSG must have the same names as that of the source storage group.

When performing a PIT recovery for an RSG, all subcomponents of the storage group are recovered.

When performing a POF recovery for an RSG, only the subcomponents that you specify in the command are recovered.

Examples

The following are examples of the vxsnap restore command:

Restore to the Point in Time

vxsnap -x snapdata.xml restore restoreType=PIT writer="Microsoft
Exchange Writer"

This command uses the information in the snapdata.xml file to restore all the volumes in the snapshot set identified in that file to the point in time the snapshot set was created or last refreshed.

Roll-Forward Recovery to the Point of Failure

vxsnap -x snapdata.xml restore restoreType=POF writer="Microsoft
Exchange Writer"

This command uses the information about the database specified in the snapdata.xml file to snapback the database volumes and then use current transaction logs to roll forward to the point of failure.