Use OPatch to check Oracle GoldenGate version

Use OPatch to check Oracle GoldenGate version
Recently on I was strolling the OTN message boards and came across a question about identifying the version of Oracle GoldenGate using OPatch. This was the second time I came across this question; with that I decided to take a look and see if Oracle GoldenGate information could be retrieved using opatch.
Initially I thought that identifing the Oracle GoldenGate version could only be done by logging into GGSCI and reviewing the header information. To do this, just setup the Oracle environment using “. oraenv”.
Note: “. oraenv” will use the /etc/oratab file to set the ORACLE_HOME and ORACLE_SID parameters and ensure that Oracle GoldenGate has access to the library files needed.
Once the enviornment is set, the GGSCI can be used to start the interface.
[oracle@oraclevm01 ogg]$ . oraenv
ORACLE_SID = [oragg] ?
The Oracle base has been set to /u01/app/oracle
[oracle@oraclevm01 ogg]$ ./ggsci
Oracle GoldenGate Command Interpreter for Oracle
Version 12.1.2.1.0 OGGCORE_12.1.2.1.0_PLATFORMS_140727.2135.1_FBO
Linux, x64, 64bit (optimized), Oracle 12c on Aug 7 2014 10:21:34
Operating system character set identified as UTF-8.
Copyright (C) 1995, 2014, Oracle and/or its affiliates. All rights reserved.
GGSCI (oraclevm01.acme.com) 1>
Notice in the code above, that the version of Oracle GoldenGate being ran is 12.1.2.1.0 for Linux x64.
How can this be done through OPatch? The same information can be gathered using the opatch utility. Ideally, you will want to use opatch from the $GG_HOME/OPatch directory.
Note: $ORACLE_HOME needs to be set to $OGG_HOME before correct opatch inventory will be listed. If $ORACLE_HOME is set for the database, the opatch will return information the database not Oracle GoldenGate.
After making sure that the $ORACLE_HOME directory is pointed to the correct $GG_HOME, the inventory for Oracle GoldenGate can be retrieved using “./opatch lsinventory”.
[oracle@oraclevm01 ogg]$ export ORACLE_HOME=/u01/app/oracle/product/12.1.2/ogg
[oracle@oraclevm01 ogg]$ pwd
/u01/app/oracle/product/12.1.2/ogg
[oracle@oraclevm01 ogg]$cd OPatch
[oracle@oraclevm01 OPatch]$./opatch lsinventory
Invoking OPatch 11.2.0.1.7
Oracle Interim Patch Installer version 11.2.0.1.7
Copyright (c) 2011, Oracle Corporation. All rights reserved.
Oracle Home : /u01/app/oracle/product/12.1.2/ogg
Central Inventory : /u01/app/oraInventory
from : /etc/oraInst.loc
OPatch version : 11.2.0.1.7
OUI version : 11.2.0.3.0
Log file location : /u01/app/oracle/product/12.1.2/ogg/cfgtoollogs/opatch/opatch2014-10-28_11-18-49AM.log
Lsinventory Output file location : /u01/app/oracle/product/12.1.2/ogg/cfgtoollogs/opatch/lsinv/lsinventory2014-10-28_11-18-49AM.txt
——————————————————————————–
Installed Top-level Products (1):
Oracle GoldenGate Core 12.1.2.1.0
There are 1 products installed in this Oracle Home.
There are no Interim patches installed in this Oracle Home.
——————————————————————————–
OPatch succeeded.

https://www.dbasolved.com/2014/10/use-opatch-to-check-oracle-goldengate-version/ 

Leave a Reply

Your email address will not be published. Required fields are marked *