- Introduction:
- Databases should be installed & running in source & target.
- Connectivity between source & target servers.
- Free Disk space (approx. 15GB) for Golden Gate binary on both servers.
- Working TNS entry in tnsnames.ora file for database in both servers.
| Server | Source | Target |
|---|---|---|
| Hostname | delhi.oraeasy.com | noida.oraeasy.com |
| OS | OEL 8.5 | OEL 8.5 |
| Database Version | 19.28 | 19.28 |
| DB/PDB Name | dlcdb/dldb | ndcdb/nddb |
| Golden Gate Version | 19.1.0.0.4 | 19.1.0.0.4 |
| Golden Gate Home | /u01/app/gghome | /u01/app/gghome1 |
Here we are using the database server as source & target for Golden Gate software as well. So the Prerequisites for installing the Golden Gate binary is same as for database. You can also visit below for OS prepation of installing Golden Gate.
Oracle GoldenGate 23ai Installation.
On Source.
[oracle@delhi ~]$ cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.80.70 delhi.oraeasy.com delhi
192.168.80.72 noida.oraeasy.com noida
[oracle@delhi ~]$
[oracle@delhi ~]$ ping noida.oraeasy.com -c 3
PING noida.oraeasy.com (192.168.80.72) 56(84) bytes of data.
64 bytes from noida.oraeasy.com (192.168.80.72): icmp_seq=1 ttl=64 time=1.00 ms
64 bytes from noida.oraeasy.com (192.168.80.72): icmp_seq=2 ttl=64 time=1.12 ms
64 bytes from noida.oraeasy.com (192.168.80.72): icmp_seq=3 ttl=64 time=1.05 ms
--- noida.oraeasy.com ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2010ms
rtt min/avg/max/mdev = 1.003/1.057/1.123/0.062 ms
[oracle@delhi ~]$
[oracle@delhi ~]$ tnsping dlcdb
TNS Ping Utility for Linux: Version 19.0.0.0.0 - Production on 29-NOV-2025 14:10:27
Copyright (c) 1997, 2025, Oracle. All rights reserved.
Used parameter files:
/u01/app/oracle/product/19c/dbhome_1/network/admin/sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = delhi.oraeasy.com)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = dlcdb)))
OK (0 msec)
[oracle@delhi ~]$
[oracle@delhi ~]$ tnsping dldb
TNS Ping Utility for Linux: Version 19.0.0.0.0 - Production on 29-NOV-2025 14:10:32
Copyright (c) 1997, 2025, Oracle. All rights reserved.
Used parameter files:
/u01/app/oracle/product/19c/dbhome_1/network/admin/sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = delhi.oraeasy.com)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = dldb)))
OK (10 msec)
[oracle@delhi ~]$
On Target.
[oracle@noida ~]$ cat /etc/hosts
127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4
::1 localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.80.72 noida.oraeasy.com noida
192.168.80.70 delhi.oraeasy.com delhi
[oracle@noida ~]$
[oracle@noida ~]$ ping delhi.oraeasy.com -c 3
PING delhi.oraeasy.com (192.168.80.70) 56(84) bytes of data.
64 bytes from delhi.oraeasy.com (192.168.80.70): icmp_seq=1 ttl=64 time=1.06 ms
64 bytes from delhi.oraeasy.com (192.168.80.70): icmp_seq=2 ttl=64 time=1.19 ms
64 bytes from delhi.oraeasy.com (192.168.80.70): icmp_seq=3 ttl=64 time=0.889 ms
--- delhi.oraeasy.com ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2064ms
rtt min/avg/max/mdev = 0.889/1.049/1.194/0.124 ms
[oracle@noida ~]$
[oracle@noida ~]$ tnsping ndcdb
TNS Ping Utility for Linux: Version 19.0.0.0.0 - Production on 29-NOV-2025 14:20:32
Copyright (c) 1997, 2025, Oracle. All rights reserved.
Used parameter files:
/u01/app/oracle/product/19c/dbhome_1/network/admin/sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = noida.oraeasy.com)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = ndcdb)))
OK (0 msec)
[oracle@noida ~]$
[oracle@noida ~]$ tnsping nddb
TNS Ping Utility for Linux: Version 19.0.0.0.0 - Production on 29-NOV-2025 14:20:34
Copyright (c) 1997, 2025, Oracle. All rights reserved.
Used parameter files:
/u01/app/oracle/product/19c/dbhome_1/network/admin/sqlnet.ora
Used TNSNAMES adapter to resolve the alias
Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = noida.oraeasy.com)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = nddb)))
OK (10 msec)
[oracle@noida ~]$
On source (Delhi)
2. Create GG Home directory & unzip the software.
[oracle@delhi software]$ mkdir -p /u01/app/gghome
[oracle@delhi software]$ pwd
/u01/software
[oracle@delhi software]$ ls -lrth
total 531M
-rw-r--r--. 1 oracle oinstall 531M Nov 28 13:45 V983658-01.zip
[oracle@delhi software]$
[oracle@delhi software]$ unzip V983658-01.zip
3. Now run ./runInstaller to install GG software.
[oracle@delhi Disk1]$ pwd
/u01/software/fbo_ggs_Linux_x64_shiphome/Disk1
[oracle@delhi Disk1]$ ls
install response runInstaller stage
[oracle@delhi Disk1]$
[oracle@delhi Disk1]$ ./runInstaller
Starting Oracle Universal Installer...
Checking Temp space: must be greater than 120 MB. Actual 2874 MB Passed
Checking swap space: must be greater than 150 MB. Actual 3413 MB Passed
Checking monitor: must be configured to display at least 256 colors. Actual 16777216 Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2025-11-28_06-25-34PM. Please wait ...[oracle@delhi Disk1]$ You can find the log of this install session at:
/u01/app/oraInventory/logs/installActions2025-11-28_06-25-34PM.log
Now a GUI window will appear. Follow the instructions:
Select 19c & Click Next.
Provide GG Home /u01/app/gghome and Manager port. Then click Next.
Click Install.
Monitor the progress.
Click Close.
4. Now verify the GG installation.
[oracle@delhi ~]$ cd /u01/app/gghome
[oracle@delhi gghome]$ ./ggsci -v
Oracle GoldenGate Command Interpreter for Oracle
Version 19.1.0.0.4 OGGCORE_19.1.0.0.0_PLATFORMS_191017.1054_FBO
Linux, x64, 64bit (optimized), Oracle 19c on Oct 17 2019 21:16:29
Copyright (C) 1995, 2019, Oracle and/or its affiliates. All rights reserved.
[oracle@delhi gghome]$ ./ggsci
Oracle GoldenGate Command Interpreter for Oracle
Version 19.1.0.0.4 OGGCORE_19.1.0.0.0_PLATFORMS_191017.1054_FBO
Linux, x64, 64bit (optimized), Oracle 19c on Oct 17 2019 21:16:29
Operating system character set identified as UTF-8.
Copyright (C) 1995, 2019, Oracle and/or its affiliates. All rights reserved.
GGSCI (delhi.oraeasy.com) 1> info all
Program Status Group Lag at Chkpt Time Since Chkpt
MANAGER RUNNING
GGSCI (delhi.oraeasy.com) 2> info mgr
Manager is running (IP port TCP:delhi.oraeasy.com.7809, Process ID 5208).
5. Now we need to execute few command to prepare the database for Golden Gate. So let's proceed for that
Enable Supplement Log Data, Force Logging, streams_pool_size & GOLDENGATE_REPLICATION parameter.
SQL> SELECT supplemental_log_data_min,log_mode,force_logging FROM v$database;
SUPPLEME LOG_MODE FORCE_LOGGING
-------- ------------ ---------------------------------------
NO ARCHIVELOG NO
SQL> ALTER DATABASE FORCE LOGGING;
Database altered.
SQL> ALTER DATABASE ADD SUPPLEMENTAL LOG DATA;
Database altered.
SQL> SELECT supplemental_log_data_min,log_mode,force_logging FROM v$database;
SUPPLEME LOG_MODE FORCE_LOGGING
-------- ------------ ---------------------------------------
YES ARCHIVELOG YES
SQL> alter system switch logfile;
System altered.
SQL> show parameter ENABLE_GOLDENGATE_REPLICATION
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
enable_goldengate_replication boolean FALSE
SQL>
SQL> ALTER SYSTEM SET ENABLE_GOLDENGATE_REPLICATION=TRUE SCOPE=BOTH;
System altered.
SQL> show parameter ENABLE_GOLDENGATE_REPLICATION
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
enable_goldengate_replication boolean TRUE
SQL>
SQL> show parameter streams_pool_size
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
streams_pool_size big integer 0
SQL> alter system set streams_pool_size=100m scope=both;
System altered.
SQL> show parameter streams_pool_size
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
streams_pool_size big integer 112M
SQL>
Create Tablespace in both CDB & PDB.
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
3 DLDB READ WRITE NO
SQL> select name from v$datafile;
NAME
--------------------------------------------------------------------------------
/u01/app/oracle/oradata/DLCDB/system01.dbf
/u01/app/oracle/oradata/DLCDB/sysaux01.dbf
/u01/app/oracle/oradata/DLCDB/undotbs01.dbf
/u01/app/oracle/oradata/DLCDB/pdbseed/system01.dbf
/u01/app/oracle/oradata/DLCDB/pdbseed/sysaux01.dbf
/u01/app/oracle/oradata/DLCDB/users01.dbf
/u01/app/oracle/oradata/DLCDB/pdbseed/undotbs01.dbf
/u01/app/oracle/oradata/DLCDB/dldb/system01.dbf
/u01/app/oracle/oradata/DLCDB/dldb/sysaux01.dbf
/u01/app/oracle/oradata/DLCDB/dldb/undotbs01.dbf
/u01/app/oracle/oradata/DLCDB/dldb/users01.dbf
11 rows selected.
SQL> create tablespace OGG datafile '/u01/app/oracle/oradata/DLCDB/OGGCDB01.dbf' size 1g autoextend on;
Tablespace created.
SQL> alter session set container=DLDB;
Session altered.
SQL> create tablespace OGG datafile '/u01/app/oracle/oradata/DLCDB/dldb/OGGPDB01.dbf' size 1g autoextend on;
Tablespace created.
Create user for Golden Gate.
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
3 DLDB READ WRITE NO
SQL> create user c##ogg identified by C##Ogg$123 container=all default tablespace OGG temporary tablespace TEMP;
User created.
SQL> alter user c##ogg quota unlimited on OGG;
User altered.
SQL> grant set container to c##ogg container=all;
Grant succeeded.
SQL> grant alter system to c##ogg container=all;
Grant succeeded.
SQL> grant create session to c##ogg container=all;
Grant succeeded.
SQL> grant alter any table to c##ogg container=all;
Grant succeeded.
SQL> grant connect,resource to c##ogg container=all;
Grant succeeded.
SQL> GRANT SELECT ANY TABLE TO c##ogg container=all;
Grant succeeded.
SQL> GRANT SELECT_CATALOG_ROLE TO c##ogg container=all;
Grant succeeded.
SQL> GRANT SELECT ANY dictionary TO c##ogg container=all;
Grant succeeded.
SQL> exec dbms_goldengate_auth.grant_admin_privilege('c##ogg',container=>'all');
PL/SQL procedure successfully completed.
SQL>
In PDB.
SQL> alter session set container=DLDB;
Session altered.
SQL> create user ggadmin identified by GGadmin#123 default tablespace OGG temporary tablespace TEMP;
User created.
SQL> alter user ggadmin quota unlimited on OGG;
User altered.
Grant succeeded.
SQL> grant alter system to ggadmin;
Grant succeeded.
SQL> grant create session to ggadmin;
Grant succeeded.
SQL> grant alter any table to ggadmin;
Grant succeeded.
SQL> grant connect,resource,DBA to ggadmin;
Grant succeeded.
SQL> GRANT SELECT ANY TABLE TO ggadmin;
Grant succeeded.
SQL> GRANT SELECT_CATALOG_ROLE TO ggadmin;
Grant succeeded.
SQL> GRANT SELECT ANY dictionary TO ggadmin;
Grant succeeded.
SQL> EXEC DBMS_GOLDENGATE_AUTH.GRANT_ADMIN_PRIVILEGE('GGADMIN', CONTAINER=>'CURRENT');
PL/SQL procedure successfully completed.
Here, for Extract we use the user (c##ogg) which is created at root level container and for Replicat we use the user (ggadmin) created to the specific PDB.6. Now we need to run few scripts given by GG software so that DDL replication will work.
[oracle@delhi gghome]$ ls *.sql
archivelog.sql ddl_ora10.sql ddl_setup.sql demo_more_ora_insert.sql label.sql role_setup.sql
chkpt_ora_create.sql ddl_ora10upCommon.sql ddl_status.sql demo_ora_create.sql marker_remove.sql sequence.sql
ddl_cleartrace.sql ddl_ora11.sql ddl_staymetadata_off.sql demo_ora_insert.sql marker_setup.sql ulg.sql
ddl_create.sql ddl_ora9.sql ddl_staymetadata_on.sql demo_ora_lob_create.sql marker_status.sql
ddl_ddl2file.sql ddl_pin.sql ddl_tracelevel.sql demo_ora_misc.sql noop.sql
ddl_disable.sql ddl_remove.sql ddl_trace_off.sql demo_ora_pk_befores_create.sql params.sql
ddl_enable.sql ddl_session1.sql ddl_trace_on.sql demo_ora_pk_befores_insert.sql prvtlmpg_uninstall.sql
ddl_filter.sql ddl_session.sql demo_more_ora_create.sql demo_ora_pk_befores_updates.sql remove_seq.sql
[oracle@delhi gghome]$sqlplus / as sysdba
SQL> show pdbs
CON_ID CON_NAME OPEN MODE RESTRICTED
---------- ------------------------------ ---------- ----------
2 PDB$SEED READ ONLY NO
3 DLDB READ WRITE NO
SQL> @marker_setup.sql
Marker setup script
You will be prompted for the name of a schema for the Oracle GoldenGate database objects.
NOTE: The schema must be created prior to running this script.
NOTE: Stop all DDL replication before starting this installation.
Enter Oracle GoldenGate schema name:c##ogg
Marker setup table script complete, running verification script...
Please enter the name of a schema for the GoldenGate database objects:
Setting schema name to C##OGG
MARKER TABLE
-------------------------------
OK
MARKER SEQUENCE
-------------------------------
OK
Script complete.
SQL>
In PDB.
SQL> alter session set container=DLDB;
Session altered.
SQL>
SQL> @role_setup.sql
GGS Role setup script
This script will drop and recreate the role GGS_GGSUSER_ROLE
To use a different role name, quit this script and then edit the params.sql script to change the gg_role parameter to the preferred name. (Do not run the script.)
You will be prompted for the name of a schema for the GoldenGate database objects.
NOTE: The schema must be created prior to running this script.
NOTE: Stop all DDL replication before starting this installation.
Enter GoldenGate schema name:c##ogg
Wrote file role_setup_set.txt
PL/SQL procedure successfully completed.
Role setup script complete
Grant this role to each user assigned to the Extract, GGSCI, and Manager processes, by using the following SQL command:
GRANT GGS_GGSUSER_ROLE TO
where is the user assigned to the GoldenGate processes.
SQL> GRANT GGS_GGSUSER_ROLE TO c##ogg;
Grant succeeded.
SQL>
7. Now need to create Credential Store so that Golden Gate can make connection to database.
[oracle@delhi gghome]$ ggsci
Oracle GoldenGate Command Interpreter for Oracle
Version 19.1.0.0.4 OGGCORE_19.1.0.0.0_PLATFORMS_191017.1054_FBO
Linux, x64, 64bit (optimized), Oracle 19c on Oct 17 2019 21:16:29
Operating system character set identified as UTF-8.
Copyright (C) 1995, 2019, Oracle and/or its affiliates. All rights reserved.
GGSCI (delhi.oraeasy.com) 1> info all
Program Status Group Lag at Chkpt Time Since Chkpt
MANAGER RUNNING
GGSCI (delhi.oraeasy.com) 2> info mgr
Manager is running (IP port TCP:delhi.oraeasy.com.7809, Process ID 5208).
GGSCI (delhi.oraeasy.com) 3> ADD CREDENTIALSTORE
Credential store created.
GGSCI (delhi.oraeasy.com) 2> ALTER CREDENTIALSTORE ADD USER c##ogg@DLCDB ALIAS ogg
Password:
Credential store altered.
GGSCI (delhi.oraeasy.com) 2> ALTER CREDENTIALSTORE ADD USER GGADMIN@DLDB alias ggadmin
Password:
Credential store altered.
GGSCI (delhi.oraeasy.com) 3> info CREDENTIALSTORE
Reading from credential store:
Default domain: OracleGoldenGate
Alias: ogg
Userid: c##ogg@DLCDB
Alias: ggadmin
Userid: GGADMIN@DLDB
GGSCI (delhi.oraeasy.com) 9> DBLOGIN USERIDALIAS ogg
Successfully logged into database CDB$ROOT.
GGSCI (delhi.oraeasy.com as c##ogg@dlcdb/CDB$ROOT) 10>
GGSCI (delhi.oraeasy.com as c##ogg@dlcdb/CDB$ROOT) 10> DBLOGIN USERIDALIAS ggadmin
Successfully logged into database DLDB.
GGSCI (delhi.oraeasy.com as GGADMIN@dlcdb/DLDB) 11>
Now do the same steps from 2 to 7 on target (Noida) database server and prepare target server for Golden Gate replication.
So we have completed the Golden Gate installation and database prepartion for replication. In the next article, we will see how to configure Extract & Replicat for Bidirectional Golden Gate setup.
Thank you for reading!
I hope this content has been helpful to you. Your feedback and suggestions are always welcome — feel free to leave a comment or reach out with any queries.
Abhishek Shrivastava








Comments
Post a Comment