Creating and managing linked break-off snapshot volumes

Linked break-off snapshots are suitable for write-intensive volumes. Specifically, they are used for off-host processing, because the snapshot could be in a different disk group to start with and could avoid disk group split/join operations

For linked break-off snapshots, you must prepare a volume that is to be used as the snapshot volume. This must be the same size as the volume for which the snapshot is being created, and it must also have the same region size.

The attributes for a snapshot are specified as a tuple to the vxsnap make command. This command accepts multiple tuples. One tuple is required for each snapshot that is being created. Each element of a tuple is separated from the next by a slash character (/). Tuples are separated by white space.

To create and manage a linked break-off snapshot

  1. Use the following command to link the prepared snapshot volume, snapvol, to the data volume:
    # vxsnap [-g diskgroup] [-b] addmir volume mirvol=snapvol \
      [mirdg=snapdg]

    The optional mirdg attribute can be used to specify the snapshot volume's current disk group, snapdg. The -b option can be used to perform the synchronization in the background. If the -b option is not specified, the command does not return until the link becomes ACTIVE.

    For example, the following command links the prepared volume, prepsnap, in the disk group, mysnapdg, to the volume, vol1, in the disk group, mydg:

    # vxsnap -g mydg -b addmir vol1 mirvol=prepsnap mirdg=mysnapdg

    If the -b option is specified, you can use the vxsnap snapwait command to wait for the synchronization of the linked snapshot volume to complete, as shown in this example:

    # vxsnap -g mydg snapwait vol1 mirvol=prepsnap mirdg=mysnapvoldg
  2. To create a linked break-off snapshot, use the following form of the vxsnap make command.
    # vxsnap [-g diskgroup] make   source=volume/snapvol=snapvol\
    [/snapdg=snapdiskgroup]

    The snapdg attribute must be used to specify the snapshot volume's disk group if this is different from that of the data volume.

    For example, to use the prepared volume, prepsnap, as the snapshot for the volume, vol1, in the disk group, mydg, use the following command:

    # vxsnap -g mydg make source=vol1/snapvol=prepsnap/snapdg=mysnapdg
  3. Clean the temporary volume's contents using an appropriate utility such as fsck for non-VxVM file systems and log replay for databases. Because VxVM calls VxFS and places VxFS file systems in a constant state immediately before taking a snapshot, it is not usually necessary to run fsck on a VxFS file system on the temporary volume. If a VxFS file system contains a database, it will still be necessary to perform database log replay.
  4. To backup the data in the snapshot, use an appropriate utility or operating system command to copy the contents of the snapshot to tape, or to some other backup medium.
  5. You now have the following options:

    • Refresh the contents of the snapshot. This creates a new point-in-time image of the original volume ready for another backup. If synchronization was already in progress on the snapshot, this operation may result in large portions of the snapshot having to be resynchronized.

    • Reattach the snapshot volume with the original volume.

    • Dissociate the snapshot volume entirely from the original volume. This may be useful if you want to use the copy for other purposes such as testing or report generation. If desired, you can delete the dissociated volume.

    • If the snapshot is part of a snapshot hierarchy, you can also choose to split this hierarchy from its parent volumes.

More Information

Creating a volume for use as a full-sized instant or linked break-off snapshot

Refreshing an instant space-optimized snapshot

Reattaching a linked break-off snapshot volume

Dissociating an instant snapshot

Splitting an instant snapshot hierarchy