Before Oracle 11g, the physical Standby database (physical Standby) cannot be opened when applying redo, but can only be mounted. Starting from 11g, when applying redo, the physical standby database can be in read-only mode, which is called Active Data Guard. With Active Data Guard, you can query or export Data in the physical standby database to reduce access to and pressure on the master database.
Active Data Guard is applicable to read-only applications. For example, some applications only query Data and perform some report services without generating redo Data. These applications can be transferred to the slave database, avoid contention for master database resources.
Oracle Active Data Guard is a feature of Oracle Database Enterprise Edition, which requires additional fees.
To enable Active Data Guard, you only need to open the slave DATABASE in read-only mode and execute the alter database recover managed standby database statement. Note that the COMPATIBLE parameter of the master and slave databases must be set to at least 11.0.0.
If Active Data Guard is enabled, the V $ DATABASE of the standby DATABASE is displayed as "read only with apply ':
SQL> SELECT open_mode FROM V $ DATABASE;
OPEN_MODE
--------------------
READ ONLY WITH APPLY
Note: UseActive
Data GuardTheCOMPATIBLESet the parameter to at least11.0.0.
To ensure the real-time data of the standby database, you must start real-time apply in the standby database:
SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE USING CURRENT LOGFILE;
The following functions can be executed on read-only databases:
• Issue SELECT statements, including queries that require multiple sorts that leverage TEMP
Segments
• Use alter session and alter system statements
• Use SET ROLE
• Call stored procedures
• Use database links (dblinks) to write to remote databases
• Use stored procedures to call remote procedures via dblinks
• Use set transaction read only for transaction level read consistency
• Issue complex queries (such as grouping SET queries and with clause queries)
The following functions are as follows:Not AllowedRun the following command on the read-only database:
• Any DMLs (excluding simple SELECT statements) or DDLs
• Query accessing local sequences
• DMLs to local temporary tables
Typical Active Data Guard:
• Single-instance physical master database and single-instance physical slave Database
• The master database is Oracle Real Application Clusters (Oracle RAC), and the slave database is a single instance.
• RAC master database and RAC slave Database
For how to configure Oracle Data Guard, see the following documents:
* Physical master database of a single instance and physical slave database of a single instance:
Http://docs.oracle.com/cd/B28359_01/server.111/b28294/create_ps.htm
* The master database is Oracle Real Application Clusters (Oracle RAC), and the slave database is a single instance:
Http://www.oracle.com/technetwork/database/features/availability/maa-wp-10g-racprimarysingleinstance-131970.pdf
* RAC master database and RAC slave database:
Http://www.oracle.com/technetwork/database/features/availability/maa-wp-10g-racprimaryracphysicalsta-131940.pdf
For more information about best practices of Active Data Guard, see:
Http://www.oracle.com/technetwork/database/features/availability/maa-wp-11gr1-activedataguard-1-128199.pdf
For more information about Oracle Maximum Availability Architecture Best Practices, see:
Http://www.oracle.com/goto/maa