Oracle Data Guard Switch over using “dbaascli”

Introduction:

Oracle DataGuard is a business continuity solution provided by Oracle Databases. In DataGuard configuration one database which is read/write mode (active) will be called as Primary Database and the other database which is not in read-write mode and it will be in continuous synch with primary database will be known as Standby Database.

In Oracle DataGuard we can switch roles of these databases between primary and standby and the switching roles are of two types “SwitchOver” and “Failover”

SwitchOver — This is a planned changing of roles and in this case both of your database will be available and once the switch over is performed then databases will change their roles. The current primary will become standby and Standby will become primary and log shipping starts in reverse manner as the roles has now changed.

This is a breif introduction about the Oracle Data Guard roles, Let see how can switch over between two databases for a Data Guard Configured in Oracle Cloud Environment using the utility “dbaascli”

Step-1 Connect to Database node using ssh

Connecting to the second Node(Standby):

Step-2 : Check the configured roles of the Databases

Step-3: Check the status of the Data Guard Configuration

Step-4: Checking the status on Oracle DBAAS Cloud console

Here we can see primary node is “dg01" and standby node is “dg02”

Step-5: Now perform switchover using dbaascli

Step-6: Check the roles of the database after siwtchover completion

Here we can see our previous primary database has become standby and standby has become primary.

Step-7: Checking the status on Oracle DBAAS Cloud console after switchover

Here we can see now dg01 has become standby and dg02 has become primary.

Conclusion:

The switch over operation in traditional Data guard configuration is also very simple, if data guard broker is configured it can switch over just with one simple command. But In this article we have seen how we can change roles of the databases using dbaascli utility for the data guard setup in Oracle cloud.

About Author:

Syed Zaheer is an Oracle ACE and currently working as a Senior Oracle Application Specialist. He has a decade of experience in the implementation and management of Oracle E-Business suite, Oracle HA Stack, Oracle Fusion Middle-ware & Oracle Databases. He has extensive experience in working with Oracle Enterprise Linux and Oracle Solaris. He is an Apress author of “Practical Oracle E-Business suite — An Implementation & management Guide”.He is an active member of Oracle technology forums and Oracle awarded him the status of “GURU” for his contributions.He is also an active member of the Toad World community. He has published many articles on OTN & Toadworld community network. He is Oracle certified in Operating Systems, Application, Databases, Engineered systems and Middle ware.

Zaheer has been part of 30+ successful E-Business suite Implementations/Upgrades/Migrations from version 11i to version R12.2.x.
He has domain knowledge in diversified business verticals including financials, FMCG,manufacturing, and consulting. He is an active blogger since 2008 and has published 100+ unique articles on his blog (http://appsdbaworkshop.com) He was a speaker multiple international Oracle conferences — MEOUG, OUGF and TROUG.

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade