Oracle Failover Options
Oracle Tips by Burleson Consulting
For cost issues see related notes on
Oracle licensing Pricing and
Many cost-conscious Oracle
shops as how they can get Oracle failover as cheaply as
Oracle standby database license requirements.
Oracle has a wealth of failover options, each with its own
costs and benefits:
Manual failover: allows Oracle SE, but has data loss and up to 30 minutes to
Data Guard: Requires Oracle EE, but
automates the failover process to reduce downtime
Replication: Multi-master replication can
allows the standby database to be open and accepting
transactions, with DML cross-feeding each instance. This
requires Oracle EE and is only for databases with low DML
Oracle Streams: High-speed
replication from the Oracle log_buffer allows fast
synchronization between servers. Oracle Streams requires
Oracle10g Enterprise Edition.
Let's take a closer look
at the cheapest solution, Oracle manual standby database.
Manual standby database
If you want to save money
by using Oracle Standard Edition which does not have Oracle
Data Guard, multimaster replication and Oracle Streams, a manual
approach might work for you. In this approach you write a
daemon process on the OS that detects when the Oracle ARCH
process has completed writing an archived redo log.
the daemon uses FTP or rsh to move the archived
redo to the standby database server where it is automatically
accepted into the standby database because it remains in
"recover database" mode.
The trick to this approach
is to set the size of the online redo logs to minimize data
loss. This is done by examining the log switch rate for
the Oracle database at its PEAK DML load. For example, if
you determine a size that has log switching every 5 minutes at
peak load (with an average of, say 15 minutes, the maximum data
loss is 15 minutes.
Many shops improve this
mechanism with solid-state disk for the online redo logs and
archived redo log filesystem, SSD can write up to 100 times
faster, reducing recovery time by two orders of magnitude,
reducing the maximum data loss from 15 minutes to less than one
Oracle Data Guard Failover Options
There are four methods for achieving failover
technology within the Oracle software. Each failover
option has its own costs, advantages and disadvantages.
choosing a failover option, the DBA must consider their
tolerance for unplanned downtime as well as the cost per minute
Each of these options will incur different
downtimes, configuration costs and expenses. Since Oracle
introduced recovery products 12 years ago, their technologies
have evolved significantly:
- Traditional recovery (1990-1995): This recovery method requires restoration of
failed database files and a roll-forward using Oracle?s
Enterprise Backup Utility (EBU) or the Oracle8 Recovery
Manager (RMAN) utility. This type of recovery could take
- Manual Standby databases
(1993-present) - Oracle7 introduced mechanisms that
allow a standby database to be constantly in recovery mode
and to be refreshed from Oracle's archived redo logs. In
case of failure, the last redo log could be added to the
standby database, and the database could be started in just
a few minutes. Standby database is not an Oracle product,
but a procedure that was used prior to Oracle Data Guard to
create a standby database. Oracle7 introduced
mechanisms that allow a standby database to be constantly in
recovery mode and to be refreshed from Oracle's archived
redo logs. In case of failure, the last redo log could be
added to the standby database, and the database could be
started in just a few minutes.
- Replication failover: Multi-master replication can allow the standby database to
be open and accepting transactions, with DML cross-feeding
each instance. This requires Oracle Enterprise Edition
and is only for databases with low DML rates.
- Real Application Clusters
- The RAC architecture allows many instances
to share a single database, but it avoids the overhead of
RAM block pinging. RAC has also been enhanced to work with
Oracle's Transparent Application Failover (TAF) to
automatically restart any connections when an instance
- Oracle Streams - This is
a high-speed replication solution that takes SQL directly
from the log_buffer RAM area and replicates
transactions to a remote database. During a server
crash, transactions can be quickly redirected to the
- Oracle Data Guard - This
is a free option with Oracle Enterprise Edition, and it
provides an automated standby database. Upon server
failure, a series of database procedures synchronizes the
standby database and opens it to accept connections. Oracle
Data Guard is free with Enterprise Edition.
In sum, the standby
database approach has these issues:
a) Allows Oracle Standard Edition
(far cheaper than enterprise edition).
b) Requires a license for the standby database.
c) If standby database is
geographically removed, this also provides disaster recovery.
d) Recovery can take up to 15
e) If the instance fails, the last
redo log remains in the log buffer and online redo log files.
This means that there might be a small data loss.
f) Requires manual intervention to
open the surviving standby database and re-direct incoming
requests (via tnsnames.ora or Apache) ton the new server.
standby database licenses
Oracle license pricing document (as of March 16, 2006), notes
that mall standby and failover database must be fully licensed if
they might be used as production:
"Standby – In this type of
recovery, a copy of the primary database is maintained on a
separate server at all times.
These systems are configured for
disaster recovery purposes. If the primary database fails, the
standby database is activated to act as the new primary
In this environment, both
the primary and the standby databases must be fully licensed."
Oracle Training from Don Burleson
The best on site
training classes" are just a phone call away! You can get personalized Oracle training by Donald Burleson, right at your shop!