top of page

Step-by-Step Guide: Configuring Oracle GoldenGate Microservices for High Availability with XAG and RedHat GFS2


Oracle GoldenGate Microservices architecture offers flexibility in configuring high availability (HA). Using the Oracle Grid Infrastructure Agent (XAG) with a shared file system like RedHat GFS2 can provide a robust HA solution for GoldenGate Microservices without relying on ACFS or DBFS. This guide walks you through configuring Oracle GoldenGate Microservices for high availability on RedHat GFS2 with XAG.


Prerequisites


  1. Environment Setup:

    • RedHat Linux with GFS2 configured and mounted on each node.

    • Oracle GoldenGate Microservices installed on each node.

    • Oracle Grid Infrastructure and XAG installed and configured.

  2. User Permissions:

    • Ensure oracle and grid users have the necessary permissions on GFS2.

    • GG_HOME should be configured and accessible on each node with consistent paths.

  3. Networking:

    • Set up a virtual IP (VIP) for GoldenGate, which XAG will manage to ensure continuity on failover.

    • Ensure that the VIP is available on the same subnet as the nodes and can fail over between them.


Step 1: Configure GFS2 for GoldenGate Data Storage

  1. Mount GFS2:

    • Ensure that the GFS2 filesystem is mounted on the same directory across all nodes, for example:

      mount -t gfs2 -o acl /dev/mapper/gfs2_lv /u01/golden_gate

  2. Set Permissions:

    • Grant read, write, and execute permissions on the GFS2 mount point to the oracle and grid users:

      chown -R oracle:grid /u01/golden_gate chmod -R 775 /u01/golden_gate

  3. Test GFS2:

    • Verify GFS2 functionality by creating test files from each node to ensure access and data consistency.


Step 2: Install Oracle GoldenGate Microservices

  1. Install GoldenGate:

    • Install GoldenGate Microservices on each node under the shared GFS2 filesystem.

      cd /u01/golden_gate ./fbo_ggs_Linux_x64_shiphome/Disk1/runInstaller

  2. Configure GoldenGate Service Manager:

    • Set up the Service Manager on each node using the same GFS2 directory.

    • Make sure to use the same deployment home across nodes (e.g., /u01/golden_gate/ogg_deployment).

  3. Start GoldenGate Service Manager:

    • Start GoldenGate Microservices to confirm the configuration is successful.

      /u01/golden_gate/ogg_deployment/bin/oggca.sh


Step 3: Configure XAG for GoldenGate High Availability

  1. Add XAG Resource Configuration Files:

    • Create a GoldenGate XAG resource configuration file on each node, specifying the deployment directory and process names.


      cd /u01/golden_gate/ogg_deployment vi xag_gg_res_config.xml

      Example xag_gg_res_config.xml:

      xml


      <resource> <name>ogg_deployment</name> <application_type>oracle</application_type> <application_home>/u01/golden_gate/ogg_deployment</application_home> <process_names>ServiceManager, Extract, Replicat</process_names> <network>vip_address</network> </resource>

  2. Register GoldenGate with XAG:

    • Register the GoldenGate deployment as an XAG resource:


      sudo -u grid /opt/oracle/xag/bin/xagctl add_resource -r gg_ha_service -c /u01/golden_gate/ogg_deployment/xag_gg_res_config.xml

  3. Configure VIP with XAG:

    • Add the VIP as an XAG resource to manage GoldenGate failover.


      sudo -u grid /opt/oracle/xag/bin/xagctl add_resource -r gg_vip -n vip_address

  4. Validate XAG Resources:

    • Verify the XAG resources are correctly configured and that GoldenGate can fail over properly.


      sudo -u grid /opt/oracle/xag/bin/xagctl status

Step 4: Configure and Test Failover

  1. Start XAG Resources:

    • Start the GoldenGate and VIP resources in XAG:


      sudo -u grid /opt/oracle/xag/bin/xagctl start -r gg_ha_service sudo -u grid /opt/oracle/xag/bin/xagctl start -r gg_vip

  2. Test Failover:

    • Manually stop GoldenGate on the primary node to test failover to the secondary node:


      sudo -u grid /opt/oracle/xag/bin/xagctl stop -r gg_ha_service

    • Check that the VIP and GoldenGate processes fail over to the secondary node and continue running as expected.

  3. Verify GoldenGate Microservices Availability:


Step 5: Monitor and Maintain High Availability

  1. Monitor XAG Status:

    • Regularly monitor XAG and GoldenGate status to ensure all resources are functioning properly:


      sudo -u grid /opt/oracle/xag/bin/xagctl status

  2. Automate Start/Stop Scripts (Optional):

    • Add start and stop scripts for the GoldenGate XAG resources in /etc/rc.local for automated startup on boot if needed.

  3. Regular Checks:

    • Ensure GFS2 is mounted and accessible on all nodes.

    • Periodically test failover to validate HA configuration.


Conclusion

This configuration allows you to achieve high availability for Oracle GoldenGate Microservices using RedHat GFS2 as the shared file system and Oracle XAG for resource management and failover. This setup is particularly useful when you want to avoid using ACFS or DBFS as the shared storage.


Additional Tips

  • Backup Configurations: Keep a backup of XAG configuration files and the GoldenGate deployment.

  • Regular Testing: Conduct regular failover tests to ensure the HA setup remains functional.

This configuration provides resilience and failover capability for Oracle GoldenGate Microservices, ensuring uninterrupted service for critical data replication tasks.

52 views

Recent Posts

See All

Comments


AiTech

©2023 by AiTech

bottom of page