How to reinstate the old Primary as a Standby after Failover

Cause:

Primary database crash and failed over to standby.

Solution:

We can reinstate old primary as standby by performing flashback on the old primary database.

Step 1:

Please execute the below in new primary

SELECT TO_CHAR(STANDBY_BECAME_PRIMARY_SCN) FROM V$DATABASE;

Step 2:

Flashback the old primary to the above scn(taken from step 1).

SQL> SHUTDOWN IMMEDIATE;
SQL> STARTUP MOUNT;
SQL> FLASHBACK DATABASE TO SCN standby_became_primary_scn;

Step 3:

Convert to physical standby.

ALTER DATABASE CONVERT TO PHYSICAL STANDBY;

Step 4:

Set up DG and verify log sync.
Start managed recovery.

  • June 28, 2018 | 16 views
  • Comments