In this note we will cover how to install and configure Oracle Goldengate 19c Microservices on an Oracle 19c RAC environment.
We will then configure high availability for GoldenGate Microservices using Grid Infrastructure Agent XAG v10.
Finally we will test the high availability by simulating a RAC node failure and verify that the GoldenGate Microservices Service Manager process has failed over automatically to the surviving node in the RAC cluster.
Create the ACFS file system using the ASM disk group ACFS
Create the directories to install GoldenGate 19c Microservices, Service Manager and the Deployment home
[oracle@rac01 software]$ cd /ogg
[oracle@rac01 ogg]$ mkdir ms
[oracle@rac01 ogg]$ mkdir sm
[oracle@rac01 ogg]$ mkdir deploy
Download Grid Infrastructure Agent XAG v10
https://www.oracle.com/database/technologies/xag-agents-download.html
Install XAG
As grid user
[grid@rac01 ~]$ cd
[grid@rac01 xag]$ cp /media/sf_software/xagpack10_1.zip .
[grid@rac01 xag]$ ls
xagpack10_1.zip
[grid@rac01 xag]$ unzip xagpack10_1.zip
…
…
inflating: xag/bin/oerr.pl
inflating: xag/agsiebel.pm
inflating: xag/aggoldengate.pm
creating: xag/windows/
inflating: xag/windows/s_agutils.pm
inflating: xag/agebs.pm
inflating: xag/agpsoft.pm
[grid@rac01 xag]$ cd xag
[grid@rac01 xag]$ ./xagsetup.sh –install –directory /u01/app/grid/xag –all_nodes
Installing Oracle Grid Infrastructure Agents on: rac01
Installing Oracle Grid Infrastructure Agents on: rac02
Updating XAG resources.
Successfully updated XAG resources.
Create the application VIP
As root
[grid@rac01 xag]$ su –
Password:
Last login: Tue Mar 3 12:57:25 AWST 2020 on pts/1
[root@rac01 ~]# cd /u01/app/19c/grid/bin
[root@rac01 bin]# ./appvipcfg create -network=1 -ip=192.168.56.150 -vipname=ogg_vip -user=root
Using configuration parameter file: /u01/app/19c/grid/crs/install/crsconfig_params
The log of current session can be found at:
/u01/app/grid/crsdata/rac01/scripts/appvipcfg.log
[root@rac01 bin]# tail -10 /u01/app/grid/crsdata/rac01/scripts/appvipcfg.log
> USR_ORA_VIP=192.168.56.104
> GEN_USR_ORA_VIP=
>
>End Command output
2020-03-04 09:10:57: Creating Resource Type
2020-03-04 09:10:57: Executing /u01/app/19c/grid/bin/crsctl add type app.appviptypex2.type -basetype ora.cluster_resource.type -file /u01/app/19c/grid/crs/template/appvipx.type
2020-03-04 09:10:57: Executing cmd: /u01/app/19c/grid/bin/crsctl add type app.appviptypex2.type -basetype ora.cluster_resource.type -file /u01/app/19c/grid/crs/template/appvipx.type
2020-03-04 09:10:58: Create the Resource
2020-03-04 09:10:58: Executing /u01/app/19c/grid/bin/crsctl add resource ogg_vip -type app.appviptypex2.type -attr “USR_ORA_VIP=192.168.56.150,NETWORK_RESOURCE=,START_DEPENDENCIES=hard(ora.net1.network) pullup(ora.net1.network),STOP_DEPENDENCIES=hard(intermediate:ora.net1.network),ACL=’owner:root:rwx,pgrp:root:r-x,other::r–,user:root:r-x’,APPSVIP_FAILBACK=,HOSTING_MEMBERS=”
2020-03-04 09:10:58: Executing cmd: /u01/app/19c/grid/bin/crsctl add resource ogg_vip -type app.appviptypex2.type -attr “USR_ORA_VIP=192.168.56.150,NETWORK_RESOURCE=,START_DEPENDENCIES=hard(ora.net1.network) pullup(ora.net1.network),STOP_DEPENDENCIES=hard(intermediate:ora.net1.network),ACL=’owner:root:rwx,pgrp:root:r-x,other::r–,user:root:r-x’,APPSVIP_FAILBACK=,HOSTING_MEMBERS=”
[root@rac01 bin]# ./crsctl setperm resource ogg_vip -u user:oracle:r-x
[root@rac01 bin]# ./crsctl start resource ogg_vip
CRS-2672: Attempting to start ‘ogg_vip’ on ‘rac01’
CRS-2676: Start of ‘ogg_vip’ on ‘rac01’ succeeded
[root@rac01 bin]# ./crsctl status resource ogg_vip
NAME=ogg_vip
TYPE=app.appviptypex2.type
TARGET=ONLINE
STATE=ONLINE on rac01
Create the service
[oracle@rac01 bin]$ srvctl add service -db cdb -service ogg_cdb -role PRIMARY -preferred cdb1,cdb2
[oracle@rac01 bin]$ srvctl start service -s ogg_cdb -d cdb
[oracle@rac01 bin]$ srvctl status service -s ogg_cdb -d cdb
Service ogg_cdb is running on instance(s) cdb1,cdb2
Install GoldenGate 19c Microservices
[oracle@rac01 ogg]$ cd /home/oracle/software/
[oracle@rac01 software]$ ls
fbo_ggs_Linux_x64_services_shiphome OGG-19.1.0.0-README.txt OGG_WinUnix_Rel_Notes_19.1.0.0.4.pdf
[oracle@rac01 software]$ cd fbo_ggs_Linux_x64_services_shiphome/
[oracle@rac01 fbo_ggs_Linux_x64_services_shiphome]$ cd Disk1/
[oracle@rac01 Disk1]$ ./runInstaller
Configure GoldenGate 19c Microservices
Note: The deployment is created on the shared ACFS file system /ogg
[oracle@rac01 Disk1]$ echo $ORACLE_HOME
/u01/app/oracle/product/19c/dbhome_1
[oracle@rac01 Disk1]$ export TNS_ADMIN=/u01/app/oracle/product/19c/dbhome_1/network/admin
[oracle@rac01 Disk1]$ export OGG_HOME=/u01/app/oracle/goldengate
[oracle@rac01 Disk1]$ cd $OGG_HOME/bin
[oracle@rac01 bin]$ ./oggca.sh
Start Service Manager
[oracle@rac01 conf]$ export OGG_CONF_HOME=/ogg/sm/etc/conf
[oracle@rac01 conf]$ /ogg/ms/bin/ServiceManager –xagEnabled
[oracle@rac01 conf]$ Oracle GoldenGate Service Manager for Oracle
Version 19.1.0.0.4 OGGCORE_19.1.0.0.0_PLATFORMS_191017.1054
Copyright (C) 1995, 2019, Oracle and/or its affiliates. All rights reserved.
Linux, x64, 64bit (optimized) on Oct 17 2019 14:47:09
Operating system character set identified as UTF-8.
[oracle@rac01 conf]$ ps -ef|grep ServiceManager
oracle 23990 1 0 22:47 ? 00:00:00 /ogg/ms/bin/ServiceManager –xagEnabled
oracle 24507 29299 0 22:48 pts/1 00:00:00 grep –color=auto ServiceManager
[root@rac01 rac01]# netstat -nltp|grep 900
tcp 0 0 0.0.0.0:9001 0.0.0.0:* LISTEN 28351/ServiceManage
tcp 0 0 0.0.0.0:9002 0.0.0.0:* LISTEN 28402/adminsrvr
tcp 0 0 0.0.0.0:9003 0.0.0.0:* LISTEN 28400/distsrvr
tcp 0 0 0.0.0.0:9004 0.0.0.0:* LISTEN 28398/recvsrvr
tcp 0 0 0.0.0.0:9005 0.0.0.0:* LISTEN 28396/pmsrvr
tcp6 0 0 :::9001 :::* LISTEN 28351/ServiceManage
tcp6 0 0 :::9002 :::* LISTEN 28402/adminsrvr
tcp6 0 0 :::9003 :::* LISTEN 28400/distsrvr
tcp6 0 0 :::9004 :::* LISTEN 28398/recvsrvr
tcp6 0 0 :::9005 :::* LISTEN 28396/pmsrvr
Connect to Service Manager
Create and start the XAG GoldenGate Resource
[root@rac01 rac01]# /u01/app/grid/xag/bin/agctl add goldengate ogg_ms_ha –gg_home /u01/app/oracle/goldengate –service_manager –config_home /ogg/sm/etc/conf –var_home /ogg/sm/var –vip_name ogg_vip –port 9100 –adminuser oggadmin –user oracle –group oinstall –filesystems ora.acfs.oggvol.acfs –db_services ora.cdb.ogg_cdb.svc –use_local_services
Enter password for ‘oggadmin’ :
[root@rac01 rac01]# /u01/app/grid/xag/bin/agctl start goldengate ogg_ms_ha
[root@rac01 rac01]# /u01/app/grid/xag/bin/agctl status goldengate ogg_ms_ha
Goldengate instance ‘ogg_ms_ha’ is running on rac01
[root@rac01 rac01]# /u01/app/grid/xag/bin/agctl config goldengate ogg_ms_ha
Instance name: ogg_ms_ha
Application GoldenGate location is: /u01/app/oracle/goldengate
Goldengate MicroServices Architecture environment: yes
Goldengate Service Manager configuration directory: /ogg/sm/etc/conf
Goldengate Service Manager var directory: /ogg/sm/var
Service Manager Port: 9100
Goldengate Administration User: oggadmin
Database Services needed: ora.cdb.ogg_cdb.svc
File System resources needed: ora.acfs.oggvol.acfs
VIP name: ogg_vip
Simulate a failure by shutting down rac01
Verify failover to rac02 has occurred
Check the status of the XAG GoldenGate Resource
[root@rac02 ~]# /u01/app/grid/xag/bin/agctl status goldengate ogg_ms_ha
Goldengate instance ‘ogg_ms_ha’ is running on rac02
Review the log files :
/u01/app/grid/xag/log/rac02/ogg_ms_ha_agent_goldengate.trc
/u01/app/grid/diag/crs/rac02/crs/trace/crsd_scriptagent_oracle.trc