Oracle GoldenGate: Time recorded in the Jagent Log File is Not Correct

Oracle GoldenGate: Time recorded in the Jagent Log File is Not Correct

Installed Oracle GoldenGate Management Pack. When installing the JAgent 12.2.1 on the OGG target instances, came up with a curious behavior. In the ogg_agent.log files, the time is not the local time. The time shown in the log file is 8 hours ahead although System Time is correct. The latest data under “ogg_agent.log” was as below,

[2016-12-06T08:45:29.442+00:00] [JAGENT] [NOTIFICATION] [OGGMON-20051] [com.goldengate.monitor.jagent.mbeans.impl.Agent] [tid: RMI TCP Connection(56)-146.222.96.163] [ecid: 0000LZEiZuLFKAwtOCq2Td1OHHUM00000A,0] DerivedMBean is getting build... 

Later came to know that the cause of the issue was the incorrect setting or Java parameter missed in the Java command.

Please follow the below steps to resolve the issue,

1. edit jagent parameter file

2. add -Duser.timezone=Hongkong in command

For example, you will be having the below parameters in the Jagent parameter file,

COMMAND java -Dconfig.dir=/u05/app/goldengate/ggagent/agent1/cfg -Djava.util.logging.config.class=oracle.core.ojdl.logging.LoggingConfiguration
-Doracle.core.ojdl.logging.config.file=/u05/app/goldengate/ggagent/agent1/cfg/logging-config.xml -Doracle.core.ojdl.logging.componentId=JAGENT -jar
-Xms512m -Xmx1024m /u05/app/goldengate/ogg_agent1/oggmon/ogg_agent/dirjar/jagent.jar
Program is 'java', arguments are '-Dconfig.dir=/u05/app/goldengate/ggagent/agent1/cfg
-Djava.util.logging.config.class=oracle.core.ojdl.logging.LoggingConfiguration -Doracle.core.ojdl.logging.config.file=/u05/app/goldengate/ggagent/agent1
/cfg/logging-config.xml -Doracle.core.ojdl.logging.componentId=JAGENT -jar -Xms512m -Xmx1024m /u05/app/goldengate/ogg_agent1/oggmon/ogg_agent
/dirjar/jagent.jar'


So you need to add this -Duser.timezone=Hongkong in the first line after the COMMAND java

Note: Respective Timezones should be added according to the issue faced.

3. Restart the JAgent process from GGSCI.

GGSCI> stop JAgent

GGSCI> start JAgent

You may also like...

Leave a Reply

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