28 апреля 2008 г.

Problem with Management Agent 10g Upload


I had a problem adding another target to Oracle Grid Control 10g. The Management Agent was installed by agentDownload script, the installation finished successfully, but I the target didn’t show up in the Host list of Grid Control web page.

I checked the status of agent on target host:
gc@agenthost $ emctl status agent
Oracle Enterprise Manager 10g Release 4 Grid Control 10.2.0.4.0.
Copyright (c) 1996, 2007 Oracle Corporation. All rights reserved.
---------------------------------------------------------------
Agent Version : 10.2.0.4.0
OMS Version : 10.2.0.1.0
Protocol Version : 10.2.0.0.0
Agent Home : /u01/app/gc/product/agent10g
Agent binaries : /u01/app/gc/product/agent10g
Agent Process ID : 26774
Parent Process ID : 26765
Agent URL : https://agenthost.domain.com:3872/emd/main/
Repository URL : https://omshost:1159/em/upload
Started at : 2008-04-24 12:20:17
Started by user : gc
Last Reload : 2008-04-24 12:20:17
Last successful upload : (none)
Last attempted upload : (none)

Total Megabytes of XML files uploaded so far : 0.00
Number of XML files pending upload : 6
Size of XML files pending upload(MB) : 5.88
Available disk space on upload filesystem : 18.10%
Last successful heartbeat to OMS : 2008-04-24 12:20:26
---------------------------------------------------------------
Agent is Running and Ready
The status report showed that Agent could NOT upload to OMS, so I tried to manually upload to OMS:
gc@agenthost $ emctl upload
Oracle Enterprise Manager 10g Release 4 Grid Control 10.2.0.4.0.
Copyright (c) 1996, 2007 Oracle Corporation. All rights reserved.
---------------------------------------------------------------
EMD upload error: uploadXMLFiles skipped :: OMS version not checked yet..
I checked the agent logs and came across this message in ORACLE_HOME/sysman/log/emagent.trc:
2008-04-23 19:54:26,063 Thread-20 ERROR http: snmehl_connect: Failed to get address for omshost: Non-Authoritive Host not found (error = 2)
2008-04-23 19:54:26,064 Thread-20 ERROR pingManager: nmepm_pingReposURL: Cannot connect to https://omshost:1159/em/upload: retStatus=-32
2008-04-23 19:54:26,067 Thread-20 ERROR http: snmehl_connect: Failed to get address for omshost: Non-Authoritive Host not found (error = 2)
2008-04-23 19:54:26,067 Thread-20 ERROR pingManager: nmepm_pingReposURL: Cannot connect to https://omshost:1159/em/upload: retStatus=-32
2008-04-23 19:54:26,359 Thread-5 ERROR http: snmehl_connect: Failed to get address for omshost: Non-Authoritive Host not found (error = 2)
2008-04-23 19:54:26,359 Thread-5 ERROR command: nmejcn: failed http connection to https://omshost:1159/em/upload: retStatus=-32
2008-04-23 19:54:28,368 Thread-5 ERROR http: snmehl_connect: Failed to get address for omshost: Non-Authoritive Host not found (error = 2)
The omshost could not be resolved from agenthost:
gc@agenthost $ ping -a omshost
ping: unknown host omshost
After configuring /etc/hosts (adding 555.555.555.555 omshost), and re-trying the upload, upload was successful:
gc@agenthost $ ping -a omshost
omshost (555.555.555.555) is alive

gc@agenthost $ emctl upload
Oracle Enterprise Manager 10g Release 4 Grid Control 10.2.0.4.0.
Copyright (c) 1996, 2007 Oracle Corporation. All rights reserved.
---------------------------------------------------------------
EMD upload error: Upload timed out before completion.
Number of files to upload before the upload: 13, total size (MB): 5.25.
Remaining number of files to upload: 13, total size (MB): 5.25.

gc@agenthost $ emctl upload
Oracle Enterprise Manager 10g Release 4 Grid Control 10.2.0.4.0.
Copyright (c) 1996, 2007 Oracle Corporation. All rights reserved.
---------------------------------------------------------------
EMD upload error: Upload timed out before completion.
Number of files to upload before the upload: 6, total size (MB): 1.38.
Remaining number of files to upload: 6, total size (MB): 1.38.

gc@agenthost $ emctl upload
Oracle Enterprise Manager 10g Release 4 Grid Control 10.2.0.4.0.
Copyright (c) 1996, 2007 Oracle Corporation. All rights reserved.
---------------------------------------------------------------
EMD upload completed successfully
The agent status shows that upload is successful now:
gc@agenthost $ emctl status agent
Oracle Enterprise Manager 10g Release 4 Grid Control 10.2.0.4.0.
Copyright (c) 1996, 2007 Oracle Corporation. All rights reserved.
---------------------------------------------------------------
Agent Version : 10.2.0.4.0
OMS Version : 10.2.0.1.0
Protocol Version : 10.2.0.0.0
Agent Home : /u01/app/gc/product/agent10g
Agent binaries : /u01/app/gc/product/agent10g
Agent Process ID : 26774
Parent Process ID : 26765
Agent URL : https://agenthost.domain.com:3872/emd/main/
Repository URL : https://omshost:1159/em/upload
Started at : 2008-04-24 12:20:17
Started by user : gc
Last Reload : 2008-04-24 12:20:17
Last successful upload : 2008-04-24 12:39:02Total Megabytes of XML files uploaded so far : 7.44
Number of XML files pending upload : 0
Size of XML files pending upload(MB) : 0.00
Available disk space on upload filesystem : 18.13%
Last successful heartbeat to OMS : 2008-04-24 12:39:27
---------------------------------------------------------------
Agent is Running and Ready