ENABLE_FS_FAILOVER

The ENABLE_FS_FAILOVER function can be used to enable fast-start failover. This enables the broker to fail over to a specifically-chosen standby database in the event of loss of the primary database, without requiring any manual steps..

ENABLE_FS_FAILOVER Function

DBMS_DG.ENABLE_FS_FAILOVER (
     observe_only    IN BOOLEAN DEFAULT FALSE,
     severity        OUT BINARY_INTEGER)
RETURN BINARY_INTEGER;

Parameters

Parameter Description
observe_only A boolean value to indicate whether fast-start failover should be enabled in observer-only mode. A value of TRUE will cause this function to enable fast-start failover in observe-only mode. A value of FALSE will cause this function to enable fast-start failover without observe-only mode. In observe-only mode, the observer will print information about when a fast-failover would have been initiated without actually doing a failover to the target standby database.
severity The severity associated with the status returned by this function. Severity will be one of the following Oracle error numbers:
  • ORA-0: normal, successful completion
  • ORA-16501: The Oracle Data Guard broker operation failed.
  • ORA-16502: The Oracle Data Guard broker operation succeeded with warnings.

Usage Notes

  • This function returns a binary integer.

  • The prerequisites described in Prerequisites for Enabling Fast-Start Failover must be met before you issue this command to enable fast-start failover.
  • Issuing the ENABLE FAST_START FAILOVER command does not trigger a failover, it only allows the observer that is monitoring the configuration to initiate a fast-start failover if conditions warrant a failover.
  • You can enable fast-start failover while connected to any database in the broker configuration.
  • If you do not start the observer after you have enabled fast-start failover, the ORA-16819 warning is displayed for the primary and target standby databases.
  • To enable fast-start failover for a broker configuration with multiple standby databases, the FastStartFailoverTarget configuration property on the primary database must specify one or more viable target standby databases. Both the primary database and the target standby databases must have:
    • Standby redo logs configured
    • Redo transport must be properly configured at both databases for the configured protection mode

      Note:

      Oracle also recommends Flashback Database be enabled on both the primary and standby databases to allow for reinstatement of the old primary database after a failover.
  • Once you have enabled fast-start failover, you must comply with the restrictions described in Restrictions When Fast-Start Failover is Enabled.

Return Values

Error Description
ORA-00000: normal, successful completion

Fast-start failover was disabled according to the value specified by the force parameter.

Other

If the severity returned was ORA-16501, the Data Guard broker was unable to enable fast-start failover and the return value will indicate the reason. If the severity returned was ORA-16501, the Data Guard broker was able to enable fast-start failover and the return value will indicate information about how fast-start failover was enabled.