Several database servers are being monitored by the Foglight for Oracle cartridge. The database connection is established on a dns entry hostname-vip:1521. The SSH connection to the host cannot be established on this interface due to security and needs to be made on hostname-mgt:22.
Is there a way to modify the os collection settings so that it recognizes the os collected metrics?
Use the following script in the Script Console panel to update the monOSHost property.The Agent ID can be obtained from the Script console area as show in the attached document. The field virtualHostName should include the hostname that the SSH connection will use.
For Oracle RAC agents
namespace = "DB_Oracle";
agentType = "DB_Oracle_RAC_Instance";
agentId = "102" //can be taken from the Agent Blackouts page
virtualHostName = "hostname-mgt";
primaryAsp = server["ConfigService"].getAgentInstancePrimaryAsp(namespace, agentType, agentId);
// Set field value
primaryAsp.setValueByString("monOSHost", virtualHostName);
// Save the changed ASP
server["ConfigService"].saveConfig(primaryAsp);
return "OK";
For Oracle instance agents (non RAC)
namespace = "DB_Oracle";
agentType = "DB_Oracle";
agentId = "102" //can be taken from the Agent Blackouts page
virtualHostName = "HOSTNAME";
primaryAsp = server["ConfigService"].getAgentInstancePrimaryAsp(namespace, agentType, agentId);
// Set field value
primaryAsp.setValueByString("monOSHost", virtualHostName);
// Save the changed ASP
server["ConfigService"].saveConfig(primaryAsp);
return "OK";
© ALL RIGHTS RESERVED. Feedback Terms of Use Privacy Cookie Preference Center