Symantec logo

Summary of database snapshot steps

You can use Database FlashSnap commands to create a snapshot of your entire database on the same host or on a different one. Three types of snapshots can be created: online, offline, or instant.

If the SNAPSHOT_MODE specified in the snapplan is set to online, dbed_vmsnap first puts the tablespaces to be snapshot into backup mode. After the snapshot is created, the tablespaces are taken out of backup mode, the log files are switched to ensure that the extra redo logs are archived, and a snapshot of the archive logs is created.

If the SNAPSHOT_MODE is set to offline, the database must be shut down before the snapshot is created. Online redo logs and control files are required and will be used to ensure a full database recovery.

If the SNAPSHOT_MODE is set to instant, tablespaces are not put into and out of backup mode. Online redo logs and control files are required and will be used to ensure a full database recovery.

Both online and offline snapshots provide a valid backup copy of the database. You can use the snapshot as a source for backing up the database or creating a clone database for decision-support purposes. Instant snapshots do not represent a valid backup copy for point-in-time recovery.

The sections that follow explain how to create snapshots of all volumes on a database using the snapplan. Optionally, you can use the VxVM command (vxsnap) to create volume snapshots. However, unlike the Database FlashSnap commands, the vxsnap command does not automate disk group content reorganization functions. For more information about the vxsnap command, see VERITAS Volume Manager Administrator's Guide.


  Note   Make sure the volumes used by the database are configured properly before attempting to take a snapshot. This requires superuser (root) privileges.

Database FlashSnap commands must be run by the Oracle database administrator.



  Note   Anytime you change the structure of the database (for example, by adding or deleting datafiles, converting PFILE to SPFILE, or converting SPFILE to PFILE), you must run dbed_update.


 To create a snapshot image of a database

  1. Perform the steps in To create a snapshot mirror of a volume or volume set.
  2. Use the dbed_vmchecksnap command to create a snapplan template and check the volume configuration to ensure that it is valid for creating volume snapshots of the database.

    The snapplan contains detailed database and volume configuration information that is needed for snapshot creation and resynchronization. You can modify the snapplan template with a text editor.

    The dbed_vmchecksnap command can also be used to:

  3. Use the dbed_vmsnap command to create snapshot volumes for the database.

    See Creating a snapplan (dbed_vmchecksnap)

  4. On the secondary host, use the dbed_vmclonedb command to create a clone database using the disk group deported from the primary host.

    See Cloning a database (dbed_vmclonedb) for more information.

    If the primary and secondary hosts specified in the snapplan are different, the dbed_vmclonedb command imports the disk group that was deported from the primary host, recovers the snapshot volumes, mounts the file systems, recovers the database, and brings the database online with a different Oracle SID name than the primary host. If the secondary host is different, the database name can be same. You can use the -o recoverdb option to let dbed_vmclonedb perform an automatic database recovery, or you can use the -o mountdb option to perform your own point-in-time recovery and bring up the database manually. For a point-in-time recovery, the snapshot mode must be online.

    You can also create a clone on the primary host. Your snapplan settings specify whether a clone should be created on the primary or secondary host.

  5. You can now use the clone database to perform database backup and other off-host processing work.
  6. The clone database can be used to reverse resynchronize the original volume from the data in the snapshot, or can be discarded by rejoining the snapshot volumes with the original volumes (that is, by resynchronizing the snapshot volumes) for future use.

Prerequisites for creating a snapshot of your database, depicts the sequence of steps leading up to taking a snapshot using Database FlashSnap.

There are many actions you can take after creating a snapshot of your database using Database FlashSnap. You can create a clone of the database for backup and off-host processing purposes. You can resynchronize the snapshot volumes with the primary database. In the event of primary database failure, you can recover it by reverse resynchronizing the snapshot volumes.

The following flow chart depicts the actions you can perform after creating a snapshot of your database using Database FlashSnap.

Prerequisites for creating a snapshot of your database

Prerequisites for creating a snapshot of your database

Click the thumbnail above to view full-sized image.

Click the thumbnail above to view full-sized image.

Actions you can perform after creating a snapshot of your database