7 Installing Oracle GoldenGate for PostgreSQL Databases

Learn about the requirements and how to install Oracle GoldenGate for PostgreSQL databases.

Topics:

Operating System Privileges

See Operating System Privileges for general information about the operating system requirements.

Other Programs and Settings

PostgreSQL libpq Module

For Oracle GoldenGate installations beginning with release version 19.1.0.0.220419 and after, required PostgreSQL libpq libraries are now packaged with the Oracle GoldenGate installation and do not need to be installed separately.

For Oracle GoldenGate installations prior to release version 19.1.0.0.220419, PostgreSQL libpq libraries need to be manually installed where Oracle GoldenGate is to be installed. Perform the instructions below to install the correct libpq module when running Oracle GoldenGate release versions prior to 19.1.0.0.220419.

The steps to install the PostgreSQL libpq module are:
  1. Follow the steps to install the required PostgreSQL package available at: https://www.postgresql.org/download/.

  2. Select the Linux operating system family and Red Hat/Rocky/CentOS Linux distribution from the Packages and Installers drop-down list.

  3. Select the PostgreSQL version based on the highest version of PostgreSQL that will be used with Oracle GoldenGate.

  4. Select the platform where Oracle GoldenGate will be installed, such as Red Hat Enterprise, CentOS, Scientific, or Oracle version 7.

  5. Select the architecture as x86_64from the Architecture drop-down list.

    This will provide the PostgreSQL setup scripts needed to install the required package(s).

  6. Install the repository RPM and the libs module. For example:

Database Software for Capture Requirements

To capture from a PostgreSQL database, Oracle GoldenGate requires the test_decoding database plug-in be installed for the database. This plug-in might not have been installed by default when the database was installed.

Ensure that the postgresqlversion#-contrib package is installed on the database server. For example:

sudo yum install postgresql12-contrib

Additional Programs and Settings

Configure the LD_LIBARY_PATH and OGG_HOME environment variables prior to installing Oracle GoldenGate.

  • For Oracle GoldenGate installations prior to release version 19.1.0.0.220419, set the following environment variables before installing Oracle GoldenGate:

    1. OGG_HOME – The planned Oracle GoldenGate installation path.

    2. LD_LIBARY_PATH – Includes the $OGG_HOME/lib and PostgreSQL libpq directories.

      Example:

      export OGG_HOME=<path_to_install_GoldenGate>

      export LD_LIBRARY_PATH=$OGG_HOME/lib:/usr/pgsql-12/lib

  • For Oracle GoldenGate installations of release version 19.1.0.0.220419 and after, set the following environment variables before installing Oracle GoldenGate:

    1. OGG_HOME – The planned Oracle GoldenGate installation path.

    2. LD_LIBARY_PATH – Includes the $OGG_HOME/lib directory.

      Example:

      export OGG_HOME=<path_to_install_GoldenGate>

      export LD_LIBRARY_PATH=$OGG_HOME/lib

  • When installing Oracle GoldenGate on a remote server (one different from where the database is running), set the remote server's time and time zone to that of the source database server so that Oracle GoldenGate Extract can correctly position by time when creating the Extract with the BEGIN option, otherwise, position by a valid LSN value.

Where to Install Oracle GoldenGate

Oracle GoldenGate for PostgreSQL must be installed on a supported operating system as per the Certification Matrix, and can be installed on the database server itself or on an application hub server, based on your preference.

Installing for PostgreSQL

To install Oracle GoldenGate for your PostgreSQL system. See Installing for all Platforms.

Installing the DataDirect driver for PostgreSQL

After installing Oracle GoldenGate for PostgreSQL, the Extract and Replicat processes use a DataDirect ODBC driver to connect to a PostgreSQL database. This driver is packaged with Oracle GoldenGate and needs to be installed and configured separately.

Installing for Linux

After installing Oracle GoldenGate for PostgreSQL on Linux, the DataDirect driver is automatically installed, but an ODBCINI variable needs to be set.
  1. For Classic Architecture, create a new session variable called ODBCINI and assign it the path of the odbc.ini file, which defaults to /etc/odbc.ini.
    export ODBCINI=/etc/odbc.ini