V_$GOLDENGATE_CAPABILITIES
|
This lists the enabled capabilities of GoldenGate in the database, such as
DBLOGREADER ,
TRIGGERSUPPRESSION ,
TRANSIENTDUPLICATE , and
DDLTRIGGEROPTIMIZATION .
|
V_$GOLDENGATE_CAPTURE
|
This is similar to V_$STREAMS_CAPTURE that provides the integrated capture process information.
|
V_$GOLDENGATE_TABLE_STATS
|
This lists the collision, detection, and resolution (CRD) statistics for the integrated apply process.
|
V_$GOLDENGATE_TRANSACTION
|
This lists the in-flight transaction statistics.
|
V_$GOLDENGATE_MESSAGE_TRACKING
|
This is available in Oracle database future Release 12.2... |
Investigating network issues
GoldenGate is heavily dependent on a fast and reliable network between a source and the target database; without this, data replication cannot take place. Furthermore, if your network fails, the Extract, data pump, and Replicat processes may not necessarily ABEND, so you could be running blind.
By default, the GoldenGate Manager uses the TCP port 7809
. This starts a server collector process on the port 7819
. As the load increases, the server collector dynamically chooses a port in the default range or from that specified in the range configured by the Manager process' DYNAMICPORTLIST
parameter. The Manager can dynamically spawn up to 256 additional processes running on dedicated ports, which may or may not be open and available to the operating system.
One obvious check to confirm connectivity between hosts is to use the Linux ping
utility. However, ping
uses the Internet Control Message Protocol (ICMP), which can also be blocked by firewalls. So, to confirm...
Investigating Oracle errors
It is impossible to discuss every eventuality. However, should an Oracle error cause the Manager, Extract, or Replicat process to ABEND, their corresponding report files will contain the Oracle error number and message.
The following log message shows an ORA-01466
error and the corresponding error description from a failed Extract process:
This is useful in determining the root cause, but in some cases, it doesn't provide sufficient detail on how to progress the issue. Luckily, help is at hand; every Oracle Home contains an error code lookup utility, which nine times out of ten provides additional information about the error and instruction on how to fix it. The utility is oerr
, which is located...
Oracle GoldenGate 12c now supports Conflict Detection and Resolution (CDR). However, out-of-the-box, GoldenGate takes a catch all approach to exception handling. For example, by default, should any operational failure occur, a Replicat process will ABEND and roll back the transaction to the last known checkpoint. This may not be ideal in a production environment.
The HANDLECOLLISIONS
and NOHANDLECOLLISIONS
parameters can be used to control whether or not a Replicat process tries to resolve the duplicate record error and the missing record error. The way to determine what error occurred and on which Replicat is to create an exceptions handler.
Exception handling differs from CDR by trapping and reporting Oracle errors suffered by the data replication (DML and DDL). On the other hand, CDR detects and resolves inconsistencies in the replicated data, such as mismatches with before and after images.
Exceptions can always be trapped by the Oracle error they produce. GoldenGate...
Handling Oracle Sequences
Although GoldenGate supports the replication of Oracle Sequence values, there are a number of issues we need to be aware of. For example, GoldenGate will support Oracle Sequence replication for CDC if checkpoints are not maintained. This is dependent on the SPECIALRUN
parameter that exists in the Replicat parameter file. However, they are not supported for initial loads in which the source data is derived from the source tables and not the redo logs. So, the sequence values are not extracted.
For bidirectional (active-active) environments, the database sequences must generate values on the target database independent to the source. Note that in a cascade environment, GETAPPLOPS
must be enabled on the Extract to capture sequence values replicated by the Replicat process.
Sequence gaps often occur in an Oracle database, depending on the associated sequence, cache size, and number of instances in the RAC environment. However, unless the NOCHECKSEQUENCEVALUE
parameter...
LOGDUMP
is a great utility and a real bonus to the Oracle GoldenGate software bundle. Without LOGDUMP
, we will not be able to read a trail file, which would make us blind to troubleshooting data-related issues.
LOGDUMP
has a command-line interface that allows you to open files, format the display, and navigate through a file, including filtering data. To invoke the utility, navigate to the GoldenGate Home directory and enter logdump
, as shown in the following command:
Should you be unfortunate enough to hit a bug in your GoldenGate environment, Oracle Support may suggest an upgrade to the latest release. Upgrading the Oracle database can be both complex and risky. It will also require careful planning and testing. GoldenGate upgrades are simple in comparison.
Testing is an essential part of any upgrade. When instructed by Oracle Support to upgrade to a newer version, always ensure that the issue is resolved (with no side effects) in a test environment before upgrading production systems.
To upgrade the GoldenGate Home to a later release, we can follow these simple steps that are the same for a fresh installation, as described in Chapter 2, Installing and Preparing GoldenGate:
Download the required GoldenGate version media pack from the Oracle Software Delivery Cloud by entering the following URL into your web browser: http://edelivery.oracle.com
Note
You will need to register and accept the license agreement before you can download any...
Sometimes, transactions are performed on the source system in error. Ideally, you would not want them replicated to the target database. So, what can be done?
We can't feasibly shut down our production database and perform a point-in-time recovery, nor can we use flashback on a specific set of transactions. We could set up Event Actions to detect and ignore erroneous transactions, such as DELETE
operations without a WHERE
clause, but it is impossible to trap every eventuality. Fortunately, since GoldenGate 11g Release 2, a reverse data processing utility is bundled with the software that can back out transactions (once identified) based on the period of time in which they occurred.
The reverse
utility is typically employed to undo accidental deletes that have occurred on a source table. Let's see how it works.
Creating process groups and trails for reverse processing
Before we can use the reverse
utility, we must create dedicated process groups for input and output trail files...
Whether you are a novice or an experienced DBA, you will be drawn to these pages time and again. Troubleshooting is an everyday task for many IT professionals, but no one can master each and every eventuality. This chapter has captured some of the most common failure scenarios, offering help and guidance to a successful resolution. From using LOGDUMP
to drilling into the GoldenGate trail files to automatic exception handling, you learned the importance of a methodical approach to troubleshooting.
We also discovered how to upgrade our GoldenGate environment with ease using OUI, providing the mechanism to keep us abreast of the constant demand for enhanced performance and new features.
In the next chapter, we will take a look at the technologies that are evolving from the Cloud, including the Oracle Integration Cloud Service and GoldenGate's role in the Big Data space.