How to change HOSTNAME when host acting as a collector
Posted: Mon Jun 29, 2015 1:01 pm
We have an HP OpenView server on which we have logs that are read via an active check. These logs contain the name of hosts which are also configured on the Nagios XI server. The active check on the HP OpenView server "alarms" as the HOSTNAME of the HP OpenView server, so it looks like the "alarm" was on the HP OpenView server.
I want to report the alarm as the host that was found in the log file without using a passive check. In effect, I want to alter the HOSTNAME value of an event based upon a value found in the log entry that triggered it. It would be possible within the service check to parse that log entry and extract the desired hostname, but I don't know how to then tell the Nagios XI server that the event is actually for a server other than the one that sent the alarm.
I checked for "proxy" (which is the what this is), but there are hundreds of entries mostly relating to web proxies. I'm hoping there's a more formal way to do achieve this.
Thank you.
I want to report the alarm as the host that was found in the log file without using a passive check. In effect, I want to alter the HOSTNAME value of an event based upon a value found in the log entry that triggered it. It would be possible within the service check to parse that log entry and extract the desired hostname, but I don't know how to then tell the Nagios XI server that the event is actually for a server other than the one that sent the alarm.
I checked for "proxy" (which is the what this is), but there are hundreds of entries mostly relating to web proxies. I'm hoping there's a more formal way to do achieve this.
Thank you.