Oracle Data Guard Physical Standby Databases as Sources
Oracle Data Guard Physical Standby Databases as Sources
PowerExchange Express CDC for Oracle can capture change data from Oracle Data Guard physical standby databases. PowerExchange monitors the standby and archived redo logs and the database SCN on the standby system. As long as the database SCN is progressing, PowerExchange captures change data from the logs.
A PowerExchange CDC environment with a physical standby database source has the following characteristics:
The primary database and the physical standby databases must use Oracle 11
g
or later.
You must install and run PowerExchange on the machine with the physical standby database. A PowerExchange installation is not required on the primary database machine.
The physical standby database can use real-time apply with standby redo logs or apply data directly from the archived logs only.
The physical standby database can be open with read-only access, or it can be not open, such as when started with the mount option.
PowerExchange Express CDC supports any configuration of primary and standby databases that Oracle Data Guard supports, including databases in RACs that use ASM. The number of nodes on the primary and standby systems do not need to match.
To configure change capture from a physical standby database, you must complete the following configuration tasks:
In the PowerExchange Navigator client, create a registration group and capture registrations for the Oracle source instance and tables on the primary system from which the changes originate.
In the dbmover.cfg configuration file on the standby system, configure the following statements to point to the Oracle instance on the primary system:
The ORACOLL parameter in the ORAD CAPI_CONNECTION statement
The DFLTINST parameter in the CAPX CAPI_CONNECTION statement
The first positional parameter,
collection_id
, in the ORACLEID statement
In the ORACLEID statement, do
not
specify the fourth positional parameter
capture_connect_string
. This information is provided by the DATABASE or STANDBY statement in the pwxorad.cfg file.
In the Express CDC pwxorad.cfg configuration file on the standby system, define the following statements if the standby database is open for read-only access:
Define a DATABASE statement that provides connection information for the standby system.
If the primary database is in a RAC, define a RAC statement. PowerExchange verifies the RAC MEMBERS parameter value against the number of threads on the standby or archived redo logs. The RAC MEMBERS value must be equal to the number of threads.
If the standby database is
not
open for read-only access, define the following parameters:
Define a DATABASE statement that provides connection information for the primary system. PowerExchange requires this connection to access the Oracle data dictionary on the primary system.
Define a STANDBY statement that provides connection information for the standby system. The user that you specify for the STANDBY connection must have SYSDBA authority to access the fixed views and monitor the Data Guard apply progress in a database that is not open.
In the PowerExchange Logger pwxccl.cfg configuration file on the standby system, configure the DBID parameter to specify the Oracle collection ID that is defined in the registration group for the registered source tables on the primary system.
After CDC is running, the following operational considerations might apply:
When the standby database is
not
open for read-only access, Oracle might not progress apply processing beyond the tip of the last archived log, even if more recent changes are available in the standby redo logs. To get near-real-time capture processing, add APPLYACTIVE=Y in the STANDBY statement. PowerExchange will then read change data from the standby redo logs up to the highest of the low SCN values in the standby logs for all threads.
PowerExchange CDC captures data up to the current database SCN, or apply SCN, for a physical standby database. If Oracle stops applying data for some reason, for example, because of a log gap, PowerExchange change capture processing stalls and waits for the apply process to resume with message PWX-36098.
Before you perform a switchover, stop change data capture.
If PowerExchange Express CDC is configured to access a standby instance that is open for read-only access, you might need to add or edit the RAC MEMBERS parameter to properly resume capturing data after a switchover. If the thread count on the original standby database does not match the thread count on the original primary database, set the RAC MEMBERS parameter value in the pwxorad.cfg file to the number of threads on the original standby database. After the switchover, the new primary database (former standby database) will have the specified number of threads. If the original standby database is not in a RAC, you can omit the RAC MEMBERS parameter.
If PowerExchange Express CDC is configured to access a standby instance that is in mount mode (not open), make the following changes in the pwxorad.cfg file:
Remove the STANDBY statement.
Edit the DATABASE statement such that PowerExchange connects directly to the new primary instance.
If the thread count on the original standby database does not match the thread count on the original primary database, set the RAC MEMBERS parameter value to the number of threads on the original standby database. After the switchover, the new primary database (former standby database) will have the specified number of threads. If the original standby database is not in a RAC, you can omit the RAC MEMBERS parameter.
PowerExchange Express CDC for Oracle does not support reading Oracle logs across a reset logs boundary. If a RESETLOGS operation is performed when a failover to an Oracle Data Guard physical standby database occurs after an unplanned outage, you must special start the PowerExchange Logger for Linux, UNIX, and Windows to minimize data loss. Data that was captured prior to the special start is preserved, but any transactions that were in flight when the outage occurred are lost.