Physical standby database switchover through DG Broker

Data guard switchover physical standby-

Switchover using DataGaurd Broker- 

Follow given steps to switchover databases through data guard broker dgmgrl.

(1)Login to primary & standby hosts and . oraenv to the SID of the db.
(2)srvctl stop database -d <Dbname>

(3)Primary: sqlplus / as sysdba
startup

(4)Standby: sqlplus / as sysdba
startup mount

(5)Type: dgmgrl

(3) Connect as sys
DGMGRL> CONNECT SYS/password@<primary db
Example:
DGMGRL> CONNECT SYS/***@pdbname
Connected.
DGMGRL>

(4)Issue the SHOW CONFIGURATION command to verify that DG Broker is working ok
DGMGRL> SHOW CONFIGURATION;
(It should return SUCCESS)

(5)Issue switchover:
DGMGRL> SWITCHOVER TO <standby database name>;
Example:
DGMGRL> SWITCHOVER TO pdbname;

(6)Issue the SHOW CONFIGURATION command to verify that the switchover was successful.
DGMGRL> SHOW CONFIGURATION;
(It should return SUCCESS)

(7) Check alert logs on both primary and standby servers and verify that:
New Primary is open read-write mode
Standby is synching
There are no errors

(8) Check the database open mode and role as mentioned in Section 1 (6).

Note-
If Broker times out/does not complete:
srvctl config database -d <dbname>
If database role and start options are not set correctly:follow below seteps to set correctly.

srvctl modify database -d <database_name> -r PHYSICAL_STANDBY ( or PRIMARY whichvever is the case)
srvctl modify database -d <database name> -s ‘READ ONLY’ (or OPEN if PRIMARY db)

Leave a Reply

Your email address will not be published. Required fields are marked *