Activate Standby Database when the Primary Database is not available
My Primary database is not accessible and server is crashed so we can open the standby database for use.
Steps:
1. Start the standby database in mount stage
shut immediate;
startup mount;
2. Check the standby database protection_mode and database_role
SQL> SELECT OPEN_MODE,PROTECTION_MODE,DATABASE_ROLE FROM V$DATABASE;
OPEN_MODE PROTECTION_MODE DATABASE_ROLE
---------- -------------------- ----------------
MOUNTED MAXIMUM PERFORMANCE PHYSICAL STANDBY
NOTE: If protection_mode is other than maximum performance, then alter it as below.
SQL> ALTER DATABASE SET STANDBY DATABASE TO MAXIMIZE PERFORMANCE;
3. Recover standby database
SQL> RECOVER STANDBY DATABASE;
Make sure all archives has been applied in this process and Put CANCEL
4. Finish the recovery process on standby
SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE FINISH;
Database altered
5. Activate the standby database:
SQL> ALTER DATABASE ACTIVATE PHYSICAL STANDBY DATABASE;
Database altered.
6. Check the status
SQL> SELECT OPEN_MODE,PROTECTION_MODE,DATABASE_ROLE FROM V$DATABASE;
OPEN_MODE PROTECTION_MODE DATABASE_ROLE
---------- -------------------- ----------------
MOUNTED MAXIMUM PERFORMANCE PRIMARY
7. Open the database
SQL> ALTER DATABASE OPEN;
Post a Comment
Post a Comment