Perform a Switchover
When you perform a switchover, the primary database becomes the standby database and the standby database becomes the primary database, with no data loss.
A switchover is typically done to test failover to the standby database for audit or certification reasons, or to test your application's failover procedures when you have added an Autonomous Data Guard standby database.
For switchover to a standby database, the Oracle Cloud Infrastructure Console on the primary database shows a Switchover link under Disaster recovery area when both the primary database and a standby database are available. You can perform a switchover when the primary database Lifecycle State shows Available or Stopped, and a standby database is available (the State field shows Standby).
To see either local or cross-region standby database state, under Resources click Disaster recovery and for the standby database listed in the Peer Autonomous Database column, check that the State shows Standby.
Using the Autonomous Database API, you can initiate the switchover operation at any time. See Use the API for more information.
When Full Stack Disaster Recovery is enabled, the Autonomous Database details page, under Disaster recovery, shows the Full Stack DR field as Enabled. See Use Full Stack Disaster Recovery to Perform Switchover or Failover Operations for details on performing a switchover or a failover when Full Stack Disaster Recovery is enabled.
- Perform a Switchover to a Local Standby
When you perform a switchover, the primary database becomes the standby database and the standby database becomes the primary database, with no data loss. - Perform a Switchover to a Cross-Region Standby
When you perform a switchover, the primary database becomes the standby database and the standby database becomes the primary database, with no data loss. - Notes for Performing a Switchover
Notes for performing a switchover on Autonomous Database.
Perform a Switchover to a Local Standby
To perform switchover to a local standby, you access the primary database from the Oracle Cloud Infrastructure Console.
Perform the following prerequisite steps as necessary:
-
Open the Oracle Cloud Infrastructure Console by clicking the next to Oracle Cloud.
-
From the Oracle Cloud Infrastructure left navigation menu click Oracle Database and then, depending on your workload, click one of: Autonomous Data Warehouse or Autonomous Transaction Processing.
-
On the Autonomous Databases page select your Autonomous Database from the links under the Display name column.
To perform a switchover:
When the switchover completes, Autonomous Database reports the time of the last switchover when you hover over the in the Role field.
See Notes for Performing a Switchover for more information.
Parent topic: Perform a Switchover
Perform a Switchover to a Cross-Region Standby
For a cross-region switchover you must initiate the switchover from the Standby database.
You have several options to access the Standby database:
-
Select the remote region in Oracle Cloud Infrastructure Console and then access the Standby database.
-
Access the primary, and from the primary database you can access the standby from the Autonomous Database Details page by selecting Disaster recovery under Resources and clicking the link for the standby database in the Peer Autonomous Database column.
When Full Stack Disaster Recovery is enabled, the Autonomous Database details page, under Disaster recovery, shows the Full Stack DR field as Enabled. See Use Full Stack Disaster Recovery to Perform Switchover or Failover Operations for details on performing a switchover or a failover when Full Stack Disaster Recovery is enabled.
To perform a switchover:
When the switchover completes, Autonomous Data Guard does the following:
-
The display name shows the standby indicator.
-
The Disaster recovery resource information is updated to reflect the switchover. Under Resources select Disaster recovery to see the updated information.
-
Autonomous Database reports the time of the last switchover when you hover over the in the Role field.
See Notes for Performing a Switchover for more information.
Parent topic: Perform a Switchover
Notes for Performing a Switchover
-
For a cross-region switchover, you must initiate the switchover from the Standby database.
-
During the switchover most of the actions on the Oracle Cloud Infrastructure Console are not available and the Autonomous Database Information page shows the Lifecycle State with the value Updating.
-
The switchover operation keeps the original state of the primary database. If the primary database is stopped when you perform a switchover, the primary database is stopped after the switchover.
-
Autonomous Database generates the Switchover Autonomous Database work request. To view the request, under Resources click Work Requests.
-
After a switchover or failover to the standby, the standby becomes the primary:
-
The Oracle Cloud Infrastructure Metrics display information about the primary database.
-
The graphs on the Database Dashboard card in Database Actions display information about the primary database.
-
The graphs and metrics do not contain information about the database that was the primary database, before the switchover or failover operation.
-
-
You cannot cancel a cross-region switchover operation after the switchover begins and the State shows Role change in progress. Your options are:
-
Try or retry a switchover or a failover until the operation succeeds.
-
File a service request at Oracle Cloud Support or contact your support representative.
-
Parent topic: Perform a Switchover