Oracle Enterprise Manager 12c is quickly becoming the central monitoring tool for all of Oracle’s products (if not now, will be soon). One product that Oracle Enterprise Manager 12c can monitor is Oracle Golden Gate. For many shops, Oracle Golden Gate is monitored from the command line with scripts or manual processes. Oracle Enterprise Manager provides a graphical representation of what Golden Gate is doing wither or not the Golden Gate processes are up and running.
With the releases of Oracle Golden Gate (11.2.1 and up), when Golden Gate is installed the DIRPRM directory is already created for you (DIRPRM is suppose to be created with the CREATE SUBDIR command, right?). The DIRPRM directory is created ahead of the CREATE SUBDIR command because the parameter file for the JAGENT is installed with the initial install. The JAGENT is the component that is needed to interact with the EM Agent in order to talk with OEM.
As with any thing that has to be configured in Oracle, there are a few prerequisites you need to take care of first. From here, we will look at the prerequisites and how they need to be configured. At the end of this posting, you will see a simple way to very that monitoring is working from within OEM.
Before we can use Oracle Enterprise Manager 12c with Oracle Golden Gate, there are prerequisites that must be met prior to deploying the OEM plugin.
These software requirements ensure that OEM works with the Golden Gate. They are as follows:
- Oracle Enterprise Manager 12c (220.127.116.11 or later)
- Oracle Golden Gate (18.104.22.168.1 or later)
- Java Development Kit (JDK 1.6) on each system to be monitored
Note: The location of the JDK needs to be in the LD_LIBRARY_PATH . For Linux it should point to the location where the libjvm.so file is located.
Note: There is a known bug with JAGENT and berkley database with OEM. Move to version of Golden Gate (22.214.171.124.10 or later) to void.
Configure Each Golden Gate Instance
There are three primary steps to configuring Golden Gate to be monitored with OEM. These steps consist of:
- Enable monitoring in the GLOBALS files (ENABLEMONITORING)
- Create an Oracle Wallet to store the password for the JAGENT
- Configure Golden Gate instances to be monitored for OEM.
Each one of these steps are quite simple; however, when you first perform these steps it can become quite confusing. Slowing down and taking time to make sure everything is correct will greatly help in the configuration process.
The first thing you want to do on all Golden Gate instances that will be monitored is enable monitoring. Enable monitoring is actually quite simple. This involves opening the GLOBALS files and adding the parameter for monitoring. Once you have added the ENABLEMONITORING parameter to the GLOBALS file, you will be able to monitor Golden Gate from OEM.
Before monitoring can be turned seen, you will need to configure the JAGENT and OEM.
Create Oracle Wallet
Now that we have monitoring enabled in the Golden Gate GLOBALS file, why do you need an Oracle Wallet? The Oracle Wallet allows the EM Agent to connect and talk with the JAGENT. In order to setup the wallet, you will need to be in the Golden Gate installation directory. Once in the installation directory, you will need to run the password agent utility.
$ ./pw_agent_util.sh –jagentonly
This will create the wallet. After creating the wallet, you will be prompted to enter the Oracle Enterprise Manager agent password.
Please create a password for Java Agent: <password>
Please confirm password for Java Agent: <password>
Once you have run the pw_agent_util.sh and provided the password, you will notice a new directory in the Golden Gate installation directory. The directory name will be DIRWLT. If this directory is already there, the password agent utility will return a message and exit.
If the DIRWLT directory already exists, you will want to update the wallet using the following:
$ ./pw_agent_util.sh –updateAgentJMX
Get Golden Gate to run with OEM
Now that you have enabled monitoring and created the wallet for the agent to talk to OEM, lets get Golden Gate to work with OEM. In order to get Golden Gate to work with OEM, we need to change a few parameters in the Config.properties file. This properties file can be found under the Golden Gate installation directory under /cfg.
$ cd $GG_HOME
$ cd ./cfg
$ vi ./Config.properties
Once the Config.properties file is open there are a few settings that you must update to enable everything to work together. Find and modify the following to configure Golden Gate with OEM.
jagent.rmi.port=<port_number> => default port is 5559
jagent.host=<host_name> => hostname of the Golden Gate instance/IP is valid as well
jagent.jmx.port=<port_number> => default port is 5555
jagent.username=<user_name> => what user will connect to the jagent
Start Oracle Golden Gate
With monitoring enabled and everything configured, you may be in a hurry to start Golden Gate. At this point, you will need to start Golden Gate in a particular order. This order is needed to make sure that everything comes up as expected.
As with any other time, interacting with Golden Gate is done from the GGSCI. Start a Golden Gate session with GGSCI.
With this being the first time starting Golden Gate since monitoring was enabled in the GLOBALS files, you will need to create a data store. This is done very simply with the CREATE DATASTORE command.
ggsci > CREATE DATASTORE
Once the datastore has been created, the manager process needs to be restarted.
ggsci > STOP MANGER
ggsci > START MANAGER
Lastly, you can start the jagent.
ggsci > START JAGENT
All other Golden Gate process can now be started or restarted.
At this point, there are a few more steps that are specific to Oracle Enterprise Manager 12c. One such step is to configure the management agents by pushing out the Golden Gate Plug-In to the agent on the server where the Golden Gate installation is located. Once the plug-in is pushed out, the Golden Gate instances can be added to OEM via the Auto Discovery Tool.
After the Golden Gate processes have been discovered by OEM, wait a few minutes and then verify that the processes have been discovered.
Verify that Golden Gate in in OEM
In order to verify that Golden Gate is working in OEM, you need to make sure that the Golden Gate Plug-in has been deployed on the Oracle Management Server. This can be done simply by looking under the Targets menu in OEM. If the plug-in is deployed on the OMS, there will be a Golden Gate option.
By selecting the Golden Gate option from the Targets menu, you will be taken to the Oracle Golden Gate Homepage. This page will list the status and relative information for the Golden Gate process you have enabled monitoring for.
Hope this gives everyone a basic understanding of how to configure Oracle Golden Gate with Oracle Enterprise Manager.