Sunday, January 29, 2023

Oracle GoldenGate 21c MA -- Configure Integrated Extract with Downstream Real-Time Capture


You need to configure schema replication from an Oracle Database 11g to Oracle Database 19c using Oracle GoldenGate 21c Microservices Architecture using the integrated extract with real-time capture from a downstream mining database


1) Configure an Oracle Database 11.2 for Data Capture:

2) Enable supplemental logging for the schema tables:

Check what replication modes are supported for the target tables:

SQL> select * from dba_goldengate_support_mode;

Connect to the deployment as a privileged user:

GG (not connected) 1> connect https://localhost:34030 as sys !
Password for 'sys' at 'https://localhost:34030/gg_inst1': <enter password>

Log into the source database:

OGG (https://localhost:34030 gg_inst1) 2> DBLOGIN USERIDALIAS <alias>
Successfully logged into database.

Add supplemental log data for the schema:

GG (https://localhost:34030 gg_inst1 as <alias>@<db>) 3> ADD SCHEMATRANDATA <schema>
2023-01-27T19:08:32Z  INFO    OGG-01788  SCHEMATRANDATA has been added on schema "<schema>".
2023-01-27T19:08:32Z  INFO    OGG-01976  SCHEMATRANDATA for scheduling columns has been added on schema "
2023-01-27T19:08:32Z  INFO    OGG-10154  Schema level PREPARECSN set to mode NOWAIT on schema "

Verify with:

SQL> select * from dba_capture_prepared_tables;
SQL> select * from dba_capture_prepared_schemas;

3) Create parameter files for Extract, file name should match the Extract name:

OGG (https://localhost:34030 gg_inst1 as <alias>@<db>) 11> edit params <extract_name>

EXTRACT <extract_name>
USERIDALIAS <source_alias> DOMAIN OracleGoldenGate
EXTTRAIL <trail_file>
TABLE <schema>.*;
SEQUENCE <schema>.*;

2023-01-28T16:24:04Z  INFO    OGG-10183  Parameter file <extract_name>.prm passed validity check.
2023-01-28T16:24:04Z  INFO    OGG-06153  FIPS 140 support has been enabled. Process 171 is using compliant shared libraries to perform encryption for the rest of its execution.

4) Register Extract with the source and mining databases:

OGG (https://localhost:34030 gg_inst1) 13> DBLOGIN USERIDALIAS <source_alias>
Successfully logged into database.

OGG (https://localhost:34030 gg_inst1 as <alias>@<db>) 14> MININGDBLOGIN USERIDALIAS <mining_alias>
Successfully logged into database.

OGG (https://localhost:34030 gg_inst1 as <alias>@<db>) 17> ADD EXTRACT <extract_name>, INTEGRATED TRANLOG, BEGIN NOW
2023-01-28T17:04:46Z  INFO    OGG-08100  Integrated Extract added.

OGG (https://localhost:34030 gg_inst1 as <alias>@<db>) 18> REGISTER EXTRACT <extract_name> DATABASE
2023-01-28T17:09:09Z  INFO    OGG-02003  Extract group
<extract_name> successfully registered with database at SCN 357808321.

5) Add local trail file for the Extract:

OGG (https://localhost:34030 gg_inst1 as <alias>@<db>) 19> ADD EXTTRAIL <xx>, EXTRACT <extract_name>, MEGABYTES <N>

6) Start Extract:

OGG (https://localhost:34030 gg_inst1 as <alias>@<db>) 20> START EXTRACT <extract_name>
2023-01-28T17:19:28Z  INFO    OGG-00975  Extract group
<extract_name> starting.
2023-01-28T17:19:28Z  INFO    OGG-15426  Extract group
<extract_name> started.

7) Check status of Extract:

OGG (https://localhost:34030 gg_inst1 as ECOM@ECOM) 26> info extract <extract_name>

Extract    <extract_name>      Last Started 2023-01-28 17:22   Status RUNNING
Checkpoint Lag       00:00:03 (updated 00:00:09 ago)
Process ID           8111
Log Read Checkpoint  Oracle Integrated Redo Logs
                     2023-01-28 17:24:50
                     SCN 0.357826304 (357826304)
Encryption Profile   LocalWallet


No comments: