Skip to Main Content

Breadcrumb

Question and Answer

Connor McDonald

Thanks for the question, abhishek.

Asked: May 13, 2020 - 12:46 pm UTC

Last updated: May 18, 2020 - 2:43 am UTC

Version: Oracle 12g 12.1.0.1.0

Viewed 1000+ times

You Asked

We use Oracle 12g 12.1.0.1.0, in both primary and physical standby DB. Don't use Data Guard. Every half an hour, the archivelogs are transferred manually from primary to standby but they are applied to the standby DB only twice in 24 hours (by a script).

Now, We would like to perform a switchover to test if our standby is valid.

We check if the primary and standby are in sync, by using the below query in both primary and standby.

SQL>SELECT MAX(RECID) FROM V$LOG_HISTORY;

If the output of this query in primary and standby matches, then we conclude that the primary and standby are in sync. So, is this result good enough for us to start the switchover? If not, what more do I need to check in a NO data guard environment, if the physical and standby are in sync?

At the moment, SWITCHOVER_STATUS of V$DATABASE in both primary and standby is "NOT ALLOWED" (even if physical and standby are in sync). In this scenario, can I go for a successful switchover? If not, how can i change the "SWITCHOVER_STATUS"?

and Connor said...

That should be sufficient, and you can check V$DATABASE for the current SCN in each.

You could also run a

alter database recover managed standby database finish force;

on the standby to make sure is up to date, and that the database "knows" it is up to date.

But seriously - go with DataGuard. Makes things so much easier.

Rating

  (1 rating)

Is this answer out of date? If it is, please let us know via a Comment

Comments

Abhishek Ghosh, May 15, 2020 - 4:37 am UTC

Thanks Connor for the prompt reply. Yes, I have suggested to use Data Guard. Your answer is very helpful. Regards from Kolkata, India.
Connor McDonald
May 18, 2020 - 2:43 am UTC

glad we could help

More to Explore

Administration

Need more information on Administration? Check out the Administrators guide for the Oracle Database