Previous  |  Next  >  
Product: Oracle Manual Pages for Storage Foundation   
Manual: Maintenance Commands (1m)   

dbed_vmchecksnap

NAME

dbed_vmchecksnap - create and validate the snapplan used to create a clone database. The command can also be used to list, remove, and copy snapplans.

SYNOPSIS


dbed_vmchecksnap -S ORACLE_SID -H ORACLE_HOME -f SNAPPLAN
-o setdefaults[ ,validate ] -t [ -p plex_tag ]

-t SECONDARY_HOST
dbed_vmchecksnap -S ORACLE_SID -H ORACLE_HOME -f SNAPPLAN
-o validate [ -n ]

dbed_vmchecksnap -S ORACLE_SID [ -f SNAPPLAN ] -o list
dbed_vmchecksnap -S ORACLE_SID -f SNAPPLAN -o copy | remove

AVAILABILITY

VERITAS Storage Foundation for Oracle. To determine whether this product is installed on a HP-UX system, enter:

swlist VRTSdbed

DESCRIPTION

The dbed_vmchecksnap command creates a snapplan that dbed_vmsnap uses to create a snapshot of an Oracle database. The snapplan specifies snapshot scenarios (such as online, offline, or instant).

When you first run dbed_vmchecksnap with the -o setdefaults option, the command creates a snapplan template with a number of variables. Some of the variables are assigned default values. You may edit the snapplan file manually to set the variables for different snapshot scenarios.

Use the -o validate option to check that the snapplan is correct and copy it to the repository.

Snapshot plexes and their associated data change object (DCO) logs should be on different disks than the original plexes and must be configured correctly for creating snapshots by the system administrator. To verify that the plexes are configured correctly, run dbed_vmchecksnap with the -o validate option. For more information about snapshots and DCO logs, see the VERITAS Volume Manager Administrator's Guide.

If the Oracle initialization parameter file is not in the default location ($ORACLE_HOME/dbs), ensure that the location is specified in the settings file, which is located in /etc/vx/vxdba/$ORACLE_SID/settings.

Use the -o list option to list all the snapplans associated with a specific ORACLE_SID.

Use the -o list -f SNAPPLAN options to get detailed information about the snapplan.

Use the -o copy | remove option to copy the snapplan from the VERITAS Storage Foundation for Oracle repository to your local directory or remove the snapplan from the repository.

You can use Database FlashSnap commands in a high availability (HA) environment. See the NOTES section below for details.

OPTIONS

The following options are supported:

-S ORACLE_SID

Specifies the name of the Oracle database for which a snapshot image will be created.

-H ORACLE_HOME

Specifies the ORACLE_HOME setting for the ORACLE_SID database.

-f SNAPPLAN

Specifies the local path or the full path of the snapplan for the ORACLE_SID database.

-o setdefaults[ ,validate ]

Creates a default snapplan. The -o setdefaults option can be used with the -o validate option to validate that the configuration is correct.

-o validate

Validates each parameter in the snapplan, checks whether the snapshot volumes have been configured correctly for creating snapshots, and copies the snapplan to the respository. The default behavior is to force validation. Use the -n option if you want to skip validation.

-o list

Lists all the snapplans associated with a specific ORACLE_SID.

-o copy | remove

The -o copy option copies the snapplan from the repository to your local directory. The -o remove option removes the snapplan from the repository and your local directory.

-t SECONDARY_HOST

Specifies the name of the host to which the snapshot image will be deported. If it is the same as the primary server, the snapshot volumes will not be deported.

[ -p plex_tag ]

Specifies the snapshot plex tag. Use this variable to specify a tag for the plexes to be snapshot. The default plex tag is dbed_flashsnap.

-n

The -n option disables the VxDBA repository refresh. By default, dbed_vmchecksnap refreshes the VxDBA repository unless this option is used.

EXAMPLES

In this example, a snapplan, snap2, is created with default values in a two-host configuration. The primary host is host1, the secondary host is host2, and the working directory is /export/snap_dir:


$ /usr/bin/cd /export/snap_dir
$ /opt/VRTS/bin/dbed_vmchecksnap -S PROD \
-H /oracle/product/9i -f snap2 -o setdefaults -t host2
Snapplan snap1 for PROD.
=====================================================
SNAPSHOT_VERSION=4.0
PRIMARY_HOST=host1
SECONDARY_HOST=host2
PRIMARY_DG=PRODdg
SNAPSHOT_DG=SNAP_PRODdg
ORACLE_SID=PROD
ARCHIVELOG_DEST=/mytest/arch
SNAPSHOT_ARCHIVE_LOG=yes
SNAPSHOT_MODE=online
SNAPSHOT_PLAN_FOR=database
SNAPSHOT_PLEX_TAG=dbed_flashsnap
SNAPSHOT_MIRROR=1
SNAPSHOT_VOL_PREFIX=SNAP_
ALLOW_REVERSE_RESYNC=no
    In the following example, the snapplan, snap2, is validated for a snapshot image in a two-host configuration:

$ /usr/bin/cd /export/snap_dir
$ /opt/VRTS/bin/dbed_vmchecksnap -S PROD \
-H /oracle/product/9i -f snap2 -o validate
NOTICE: PRIMARY_HOST is host1
NOTICE: SECONDARY_HOST is host2
NOTICE: The version of PRIMARY_DG-PRODdg is 110.
NOTICE: SNAPSHOT_DB is SNAP_PRODdg
NOTICE: SNAPSHOT_MODE is online
The database is running in archivelog mode.
NOTICE: ARCHIVELOG_DEST is /mytest/arch
NOTICE: SNAPSHOT_PLAN_FOR is database
NOTICE: SNAPSHOT_ARCHIVE_LOG is yes
ARCHIVELOG_DEST=/mytest/arch is mount on /dev/vx/dsk/PRODdg/arch.
Examining Oracle volume and disk layout for snapshot.
NOTICE Volume arch on PRODdg is ready for snapshot.
Original plex and DCO log for arch is on PRODdg01.
Snapshot plex and DCO log for arch is on PRODdg02.
NOTICE: Volume prod_db on PRODdg is ready for snapshot.
Original plex and DCO log for prod_db is on PRODdg01.
Snapshot plex and DCO log for prod_db is on PRODdg04.
NOTICE: SNAP_PRODdg for snapshot will include: PRODdg02 PRODdg04
NOTICE: ALLOW_REVERSE_RESYNC is yes
The snapplan snap2 has been created.
    In this example, all available snapplans are listed for the database PROD:

$ /opt/VRTS/bin/dbed_vmchecksnap -S PROD -o list
The following snapplan(s) are available for PROD:
  SNAP_PLAN      SNAP_STATUS       DB_STATUS    SNAP_READY
      snap1        init_full            init    yes
      snap2        init_full            init    yes
    For descriptions of the statuses that appear for SNAP_STATUS and DB_STATUS, see the VERITAS Storage Foundation for Oracle Database Administrator's Guide.
    In this example, the snapplan, snap1, is displayed:

$ /opt/VRTS/bin/dbed_vmchecksnap -S PROD -f snap1 -o list
SNAPSHOT_VERSION=4.0
PRIMARY_HOST=host1
SECONDARY_HOST=host1
PRIMARY_DG=PRODdg
SNAPSHOT_DG=SNAP_PRODdg
ORACLE_SID=PROD
ARCHIVELOG_DEST=/prod_ar
SNAPSHOT_ARCHIVE_LOG=yes
SNAPSHOT_MODE=online
SNAPSHOT_PLAN_FOR=database
SNAPSHOT_PLEX_TAG=dbed_flashsnap
SNAPSHOT_MIRROR=1
SNAPSHOT_VOL_PREFIX=SNAP_
ALLOW_REVERSE_RESYNC=yes
STORAGE_INFO
PRODdg02
SNAP_PLEX=prod_db-02 prod_ar-02
STATUS_INFO
SNAP_STATUS=init_full
DB_STATUS=init
LOCAL_SNAPPLAN=/export/snap_dir/snap1

NOTES

dbed_vmchecksnap must be run as the Oracle DBA user in order to retrieve information from an Oracle database. Before the Oracle DBA user can use this command, however, the system administrator needs to enable VERITAS Volume Manager persistent FastResync on the existing database volumes and assign disks for the snapshot volumes.

The dbed_vmchecksnap command runs without interaction from the user.

To take an online snapshot of the database, the database needs to be running in archive log mode, which is set in the Oracle initialization parameter file. To take an offline or instant snapshot, the primary and secondary hosts must be different.

It is recommended that you create a local working directory to store your snapplans in. If a snapplan is updated or modified, you must re-validate it.

You can use Database FlashSnap commands in a high availability (HA) environment. The following limitations apply:

      • In an HA environment, you must modify the default snapplan to use the virtual host name defined for the database resource group for the PRIMARY_HOST and/or the SECONDARY_HOST parameters and validate the snapplan before creating the snapshot.
        • The snapshot is created by running:

          dbed_vmchecksnap -S ORACLE_SID -H ORACLE_SID
          -f SNAPPLAN -o reverse_resync_begin
      • In an HA environment, the primary database must be down before you perform reverse resynchronization. When VERITAS Cluster Server (VCS) detects that the primary database is down, however, it starts a failover process and the VxDBA repository is unmounted and the dbed_vmsnap command is aborted. For more information and a workaround, see the dbed_vmsnap(1M) man page.

SEE ALSO

dbed_vmclonedb (1M), dbed_vmsnap (1M), dbed_vmsnapplan (4)
VERITAS Storage Foundation for Oracle Administrator's Guide
VERITAS Volume Manager Administrator's Guide
 ^ Return to Top Previous  |  Next  >  
Product: Oracle Manual Pages for Storage Foundation  
Manual: Maintenance Commands (1m)  
VERITAS Software Corporation
www.veritas.com