Backup-Based Disaster
Recovery Switchover and Failover
Operations
Describes
switchover and failover operations with an Backup-Based Disaster
Recovery peer database.
About Switchover to a Backup Copy Peer When you perform a switchover, the primary database becomes the backup copy and the backup copy becomes the primary database, with no data loss.
Perform a Failover When the primary database goes down, with Backup-Based Disaster Recovery you can perform a manual failover to make the local peer the primary database.
When you perform a switchover, the primary database becomes the
backup copy and the backup copy becomes the primary database, with no data
loss.
A switchover is typically done to test failover to the backup copy
for audit or certification reasons, or to test your application's failover
procedures when you have added a backup copy peer.
For switchover to a backup copy peer, the Autonomous
Database Details page, shows the
Switchover link under Disaster
recovery and the Oracle Cloud
Infrastructure Console on the primary database also shows a
Switchover link in the
Role field when both the primary database and
a backup copy peer are available. You can perform a switchover when the
primary database Lifecycle state shows
Available or Stopped
and a backup copy is available (the State field shows
Standby).
To see the peer state, on the Autonomous Database details page, select the
Disaster recovery tab and for the peer 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.
Perform a Switchover to a Local Backup Copy
Peer 🔗
When you
perform a switchover the primary database becomes the peer, and the peer becomes the primary
database, with no data loss.
A switchover is typically done to test failover to the peer for audit or certification reasons or to test your application's failover procedures with Backup-Based Disaster
Recovery.
For a switchover to a backup copy, the Autonomous Database
Details page, the Oracle Cloud
Infrastructure Console on the database with the Primary role shows a
Switchover link in the Role field
when both the primary database and a peer are available. You can perform a
switchover when the primary database Lifecycle state shows
Available or Stopped and a peer is
available (the State field shows
Standby).
To see the peer status, select the Disaster recovery tab and
for the peer listed in the Peer Autonomous Database column,
check that the State field shows
Standby.
Using the Autonomous Database API, you can initiate the switchover operation at any time. See Use the API for more information.
Perform the following prerequisite steps as necessary:
Open the Oracle Cloud
Infrastructure Console by clicking the next to Cloud.
From the Oracle
Cloud Infrastructure left navigation menu click
Oracle Database and then
click Autonomous Database.
On the Autonomous
Databases page select your Autonomous Database from the links under the
Display name
column.
To perform a switchover, do the following:
On the Autonomous Database Details page, under Disaster recovery, in the Role field, click Switchover.
As an alternative, to initiate a switchover you can select More actions and
Switchover or select the Disaster recovery tab
anc click Switchover.
In the Confirm switchover to peer dialog, in the Select peer list, choose the peer to switchover.
Enter the database name to confirm that you want to switch over.
Click Confirm switchover to peer.
When concurrent operations
such as scaling are active, the confirmation also confirms either
pausing or canceling the concurrent operation. See Concurrent
Operations on Autonomous Database for more
information.
The database lifecycle state badge shows
Updating. To see the state of the peer select the
Disaster recovery tab. On the Disaster
recovery tab the State column shows
Role Change in Progress.
When the switchover completes, Backup-Based Disaster
Recovery does the following:
The Backup-Based Disaster
Recovery
resource information is updated to reflect the switchover. On the Autonomous Database details page
select the Disaster recovery tab to see the updated information.
Autonomous Database reports the time in the Role Changed On the field.
Perform a Switchover to a
Cross-Region Backup Copy Peer 🔗
When you perform a switchover, the primary database becomes the peer
database and the peer database becomes the primary database, with no data
loss.
Note
For a cross-region switchover you
must initiate the switchover from the cross-region peer.
You have several options to access the cross-region peer:
Select the remote region in Oracle Cloud
Infrastructure Console and then access the peer directly.
Access the primary, and from the primary database you can access
the peer from the Autonomous Database Details page by selecting the Disaster
recovery tab and clicking the link for the backup copy peer
in the Peer Autonomous Database column.
To perform a switchover:
On the cross-region peer, on the Autonomous Database Details page, under Disaster
recovery, in the Role field, click
Switchover.
As an alternative, in the row showing the database's disaster recovery
details, click at the end of the row and select
Switchover.
In the Confirm switchover to peer dialog, enter the peer
database name to confirm that you want to switch over.
In the Confirm switchover to peer dialog, click
Confirm switchover to peer.
When concurrent operations
such as scaling are active, the confirmation also confirms either
pausing or canceling the concurrent operation. See Concurrent
Operations on Autonomous Database for more
information.
The database Lifecycle state changes to
Role change in progress. To see the state of the
peer database, select the Disaster recovery tab. The
state State shows
Updating.
When the switchover completes, Autonomous Database does the following:
The display name shows the Primary indicator.
The Disaster recovery resource information
is updated to reflect the switchover. Select the Disaster
recovery tab to see the updated information.
Autonomous Database
reports the time of the last switchover when you hover over the in the Role field.
When the
primary database goes down, with Backup-Based Disaster
Recovery you can perform a manual failover to make the
local peer the primary database.
Backup-Based Disaster
Recovery does
not provide an automatic failover option. If you want to provide automatic failover,
where the system monitors the primary instance and automatically fails over to a local
standby database in certain scenarios, you need to change the disaster recovery type for
the local instance to use Autonomous Data
Guard.
With both a local Backup-Based Disaster
Recovery peer and a cross-region Backup-Based Disaster
Recovery peer, Oracle recommends that you attempt a manual failover to the local peer first (not to the cross-region peer).
Depending on how you enable Backup-Based Disaster
Recovery, there are different steps to perform a manual failover to a peer:
When you configure Backup-Based Disaster
Recovery with only a local
peer:
When you have a local peer and the switchover
is not successful, the Oracle Cloud
Infrastructure console shows a banner with information about why the switchover was not
successful and the Oracle Cloud
Infrastructure console shows a failover link in the
Role field that you can click to initiate a
failover to the local peer. The failover link only shows when the Primary
database is unavailable and a peer is available. That is, the Primary
database Lifecycle state field shows
Unavailable and the local peer is available.
Using the API, you can initiate manual failover at any time. See Use the API for information on using the API.
To see the peer
status, on the details page select the Disaster recovery
and for the peer listed in the Peer Autonomous Database column check that the
State field shows Available or
Stopped.
When you use Backup-Based Disaster
Recovery with both a local peer and a cross-region (remote) peer:
With Backup-Based Disaster
Recovery enabled with both a local peer and a cross-region peer, and the local peer is available, Oracle recommends that you attempt a manual failover to the local peer first (not to the cross-region peer).
If a local peer is unavailable or a manual failover to the local peer fails, you can perform a manual switchover to the cross-region peer. If the switchover to the cross-region peer fails, on the peer the Oracle Cloud
Infrastructure console shows a failover link in the Role field that you can click to initiate a manual failover to the peer.
If the switchover attempt in Step 1 fails, on the peer the Role field shows a Failover link. On the peer, click the Failover link.
This shows the Confirm manual failover to peer dialog, along with information on possible data loss that may result if you perform the manual failover to the peer.
In the Confirm manual failover to peer dialog, enter the Autonomous Database name to confirm that you want to failover.
In the Confirm manual failover to peer dialog, click Confirm manual failover to peer.
When concurrent operations
such as scaling are active, the confirmation also confirms either
pausing or canceling the concurrent operation. See Concurrent
Operations on Autonomous Database for more
information.
To initiate a manual failover when the Primary database is unavailable and the local Peer is available, do the following:
On the Details page, under Disaster recovery, in the Role field, click Failover.
This shows the Confirm manual failover to
peer dialog, along with information on possible data loss
that may result if you perform the manual failover to peer.
In the Confirm manual failover to peer dialog, enter the
Autonomous Database name to
confirm that you want to failover.
In the Confirm manual failover to peer dialog, click
Confirm manual failover to peer.
When the failover completes, Backup-Based Disaster
Recovery does the following:
After a manual failover operation completes you can see any data loss associated
with the manual failover in the message on the Oracle Cloud
Infrastructure console banner and if you hover over the in the Role field. The manual failover data
loss is specified in minutes.
After a manual failover with Backup-Based Disaster
Recovery, if there was a regional failure, when the region
comes back online the peer is automatically reconnected or if required
reprovisioned.
After you perform a manual failover to the cross-region peer,
the cross-region peer becomes the primary database. In this case, if a local
Autonomous Data
Guard
standby was enabled, a local Standby will be created and attached. If a
local Autonomous Data
Guard
was not enabled before the failover in the primary database, as is the
default, you have a local backup copy.
Notes for Performing a Switchover to a Backup
Copy Peer 🔗
Provides
notes for Backup-Based Disaster
Recovery
switchover:
For a cross-region switchover, you must initiate the switchover from the
cross-region peer.
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, on the Autonomous Database details page select the Work
requests tab.
After a switchover or failover to the peer, the peer becomes the Primary and the graphs on the Database Dashboard card in Database Actions and the Oracle Cloud
Infrastructure Metrics display information about the Primary database. The graphs and metrics do not contain information about the database that was the Primary 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 to cancel the switchover 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.