- This feature increases the availability of the database by eliminating the need for DBA involvement as part of the failover process.
- Fast-Start Failover enables the broker to perform these tasks automatically failover to standby database
- The key to this feature is a monitoring process appropriately named the Observer.
- The Observer is a component of the DGMGRL interface that is configured on a system outside the systems actually running the Oracle Data Guard configuration, which monitors the availability of the primary database.
- it will issue a failover after waiting the number of seconds specified by the FastStartFailoverThreshold property
Some of the below circumstance it will start Failover
Datafile Offline Failover is initiated if a datafile on the primary database experiences an I/O error resulting in a datafile being taken offline. This option is enabled by default.
Corrupted Dictionary Failover is initiated if corruption of a critical database object is found. This option is enabled by default.
Corrupted Controlfile Enabled by default, the detection of controlfile corruption will result in immediate failover.
Inaccessible Log File This parameter, disabled by default, allows for failover to be initiated in the event that LGWR is unable to write to a member of a log group.
Stuck Archiver Failover is initiated should the archiver on the primary database become hung. The default setting of this parameter is disabled.
High level steps to configure Data Guard Fast-Start Failover
- Configure Oracle Network
- Prepare the primary database
- Create a physical standby
- Enable Flashback Database
- Create a Broker configuration
- Configure the observer
- Enable and test FSFO
Enable the Fast-Start Failover, Oracle Data Guard configuration must meet the following requirements:
- Flashback Database must be enabled for both the primary and standby database target.
select flashback_on from v$database;
FLASHBACK_ON
——————
YES
2. An observer server (server outside of the Oracle Data Guard configuration) should be established to monitor the environment.
See the below URL’s for Dataguard configuration
Step by Step Configuration Of Data Guard Broker in Oracle 12c Here
Oracle 12c-Performing Dataguard Switchover Using DGMGRL Utility Here
Oracle 12c-Performing Dataguard Failover Using DGMGRL Utility Here
Oracle 12c-Performing Reinstating a Failed Primary Database Using DGMGRL Utility Here
Oracle 12c-Converting a Physical Standby to a Snapshot Standby using DGMGRL Utility Here
Let’s start the Demo:-(Before enable the Fast start Failover we need configure the dataguard broker)
Step by Step Configuration Of Data Guard Broker in Oracle 12c Here
Step1:-Show the Configuration
DGMGRL> SHOW CONFIGURATION;
Configuration – hari
Protection Mode: MaxPerformance
Members:
prime – Primary database
stand – Physical standby database
Fast-Start Failover: DISABLED
Configuration Status:
SUCCESS (status updated 48 seconds ago)
Step2:-Enabling Fast-Start Failover (changing the Maximum Performance mode to Max Availability mode)
Fast-start failover can be enabled for either maximum availability mode or maximum performance mode
DGMGRL> EDIT DATABASE ‘prime’ SET PROPERTY ‘LogXptMode’=’SYNC’;
Property “LogXptMode” updated
DGMGRL> EDIT DATABASE ‘stand’ SET PROPERTY ‘LogXptMode’=’SYNC’;
Property “LogXptMode” updated
DGMGRL> EDIT CONFIGURATION SET PROTECTION MODE AS MAXAVAILABILITY;
Succeeded.
Step3:- Check the Data Guard Protection Modes
DGMGRL> show configuration verbose;
Configuration – hari
Protection Mode: MaxAvailability
Members:
prime – Primary database
stand – Physical standby database
Properties:
FastStartFailoverThreshold = ’30’
OperationTimeout = ’30’
TraceLevel = ‘USER’
FastStartFailoverLagLimit = ’30’
CommunicationTimeout = ‘180’
ObserverReconnect = ‘0’
FastStartFailoverAutoReinstate = ‘TRUE’
FastStartFailoverPmyShutdown = ‘TRUE’
BystandersFollowRoleChange = ‘ALL’
ObserverOverride = ‘FALSE’
ExternalDestination1 = ”
ExternalDestination2 = ”
PrimaryLostWriteAction = ‘CONTINUE’
Fast-Start Failover: DISABLED
Configuration Status:
SUCCESS
Step4:-Enable the observer
- The observer is integrated in the DGMGRL client-side component of the broker and typically runs on a different computer from the primary or standby databases and from the computer where you manage the broker configuration.
- Idealy we need to configure the observer should be started on another host, to observe the primary, as if the host goes down it can monitor the outage and do specify actions.
- Note:-we start the observer in primary node here(192.168.1.24-primary) I am not configure 3 node for the observer)
Open in Another Terminal in primary side
[oracle@primary ~]$ export ORACLE_SID=prime
[oracle@primary ~]$ dgmgrl
DGMGRL for Linux: Version 12.1.0.2.0 – 64bit Production
Copyright (c) 2000, 2013, Oracle. All rights reserved.
Welcome to DGMGRL, type “help” for information.
DGMGRL> connect sys/oracle@prime
Connected as SYSDBA.
DGMGRL> enable fast_start failover;
Enabled.
DGMGRL> start observer;
Observer started
The session will seem to hang. You can do a control C. Or create and run the script as nohup. (other way to start the observer)
nohup dgmgrl sys/oracle@orcl “start observer file=’/home/oracle/fsfo.dat'” -logfile $HOME/observer.log &
Step5:-check the fast start failover status
DGMGRL> show fast_start failover
Fast-Start Failover: ENABLED
Threshold: 30 seconds
Target: stand
Observer: primary
Lag Limit: 30 seconds (not in use)
Shutdown Primary: TRUE
Auto-reinstate: TRUE
Observer Reconnect: (none)
Observer Override: FALSE
Configurable Failover Conditions
Health Conditions:
Corrupted Controlfile YES
Corrupted Dictionary YES
Inaccessible Logfile NO
Stuck Archiver NO
Datafile Offline YES
Oracle Error Conditions:
(none)
DGMGRL> SHOW CONFIGURATION;
Configuration – hari
Protection Mode: MaxAvailability
Members:
prime – Primary database
stand – (*) Physical standby database
Fast-Start Failover: ENABLED
Configuration Status:
SUCCESS (status updated 10 seconds ago)
Successfully configured the Oracle Data Guard Fast-Start Failover
Oracle 12c-Testing the Oracle Data Guard Fast-Start Failover here
Reference:-
https://docs.oracle.com/database/121/DGBKR/sofo.htm#DGBKR392
Catch Me On:- Hariprasath Rajaram
LinkedIn:https://www.linkedin.com/in/hari-prasath-aa65bb19/
Facebook:https://www.facebook.com/HariPrasathdba
FB Group:https://www.facebook.com/groups/894402327369506/
FB Page: https://www.facebook.com/dbahariprasath/?
Twitter: https://twitter.com/hariprasathdba