How to TEST/Drill Disaster Recovery Site?

In this forum Oracle Applications DBA's, System Administrators & Developers can share their knowledge/issues.
Post Reply
admin
Posts: 2062
Joined: Fri Mar 31, 2006 12:59 am
Location: Pakistan
Contact:

How to TEST/Drill Disaster Recovery Site?

Post by admin »

Convert your DR/Standby Database to Snapshot Standby
This is a nice feature for testing and you can perform DR drill/testing without disturbing the primary production site and logs file will still be sent to DR site but will not be applied. Any changes done in the DR database during snapshot will not be transferred to Primary and will be lost once you will convert back to standby. In this way of testing, there is no risk and you can verify your solution.

1. Steps to convert Physical Standby Database to the Snapshot Standby Database

1) Configure the flash recovery area, while you can check if already configured by show parameter db_recovery at SQL prompt,
a) Set the size for recovery area.
SQL> alter system set DB_RECOVERY_FILE_DEST_SIZE=300G scope=both;
b) Set Flash recovery area,
SQL> alter system set db_recovery_file_dest='+ARCH' scope=both;
SQL> show parameter recovery

2) Bring the physical standby database to mount status,
SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE CANCEL;
SQL> Shutdown immediate
SQL> Startup mount

3) Stop managed recovery,
SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE CANCEL;

4) Convert the physical standby database to the snapshot standby database.
ALTER DATABASE CONVERT TO SNAPSHOT STANDBY;

SQL> shutdown immediate;
SQL> Startup;

NOTE: Any changes on DR will be lost once you will switch back to DR and Primary logs waiting to be applied will apply once snapshot is disabled.

SQL> select open_mode,database_role from v$database;
OPEN_MODE DATABASE_ROLE
---------- ----------------
READ WRITE SNAPSHOT STANDBY

NOTE: An implicit guaranteed restore point is created when a physical standby database is converted into a snapshot standby database and this restore point is used to flashback a snapshot standby to its original state when it is converted back into a physical standby database.

2. Steps to convert the Snapshot Standby Database to the Physical Standby Database

1. Shutdown the snapshot standby database.
SQL> Shutdown immediate
2. Bring the database to the mount stage.
SQL> startup mount
3. Issue the command
ALTER DATABASE CONVERT TO PHYSICAL STANDBY;
4. Shutdown the database and mount,
SQL> shutdown immediate
SQL> startup mount
SQL> select open_mode,database_role from v$database;
OPEN_MODE DATABASE_ROLE
---------- ----------------
MOUNTED PHYSICAL STANDBY

5. Start the media recovery process.
SQL> alter database recover managed standby database disconnect from session;

NOTE: Once a snapshot standby database has been converted back into a physical standby database and restarted, Redo Apply can be started and all redo received by the snapshot standby database will be applied to the physical standby database.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest