distributed monitoring and passive host checks?

Fischer, Thomas thomas.fischer at quadriga.com
Thu Oct 16 14:12:20 CEST 2003


Wolfgang,

yes there is a solution. However i can't send you any code for it since we developed it inhouse and blah legal issues blah.

However i can describe how it was solved :o).

For every device you monitor you also do a check for PING as a service. This service check will forward all results to the central server. On the central server you use any method to monitor /var/log/messages. Nagios is configured to log all external commands via syslog. You could use for example swatch to monitor your /var/log/messages for the external PING commands. These results you pipe through a little script that parses the complete syslog message for the hostname and the status. You write a little function that writes the result into a very simple DB table (just hostname and status needed). Now you replace the host check command on the central server with a script or application that queries the DB and returns the result back to Nagios. Simple and it works. Host checks are nothing else than check_pings and if you catch the results via a PING service you will be fine for host checks as well. This method does not require that the remote host is reachable. However also consider to use service freshness checks. One pitfall exists however. If you don't get service results transmitted nagios will only see the check results from the last time it received a status. This might mean that the host is still marked as up. If you use service freshness checks you can put a general check command in for this service that gets executed whenever the freshness threshhold is reached. This command could also update the DB and set the host status to Critical. But even then there is the chance of a false positive. But better a false positive from time to time than false positives all the time. 

You can also extend this method to deal with all service check results so that the central Nagios server will only query the DB for all results. This should make things a bit faster and more performant.

If you want you can also modify NSCA to write as a general rule all stati into the DB for every host and service. You could use this data to write your own reports on the current status or do whatever you want with it. I will use this method to create a very fast overview page so people don't have to log on to Nagios and still be able to see the system status. The NSCA daemon changes i will post to the community as soon as they are finished. 

Or you make it yourself easier and wait that Nagios 2.0 is released where passive host checks are natively supported. Ethan reckons that Nagios 2.0 is going end of October into Beta.

Tom



-----Original Message-----
From: Wolfgang Fellner [mailto:wmf at noris.de]
Sent: 16 October 2003 11:45
To: nagios-users at lists.sourceforge.net
Subject: [Nagios-users] distributed monitoring and passive host checks?


hi list,

i have running distributed monitoring setup since some weeks. all works
good. the only problem i have is the host-state:
because of security-reasons i have no way to connect to the hosts from
the central server. trought this the central server doesn't recognize if
a host is down. and so the nagios-instance on the central-server sends
critical-notifications for all services of the down host.
does anybody know a solution for this problem?

kind regards,
    wmf






-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null 
This e-mail is the property of Quadriga Worldwide Ltd 
The message (and any associated files) is intended only for the use of  
the individual or entity to which it is addressed and may contain information  
that is confidential, subject to copyright or constitutes a trade secret. If  
you are not the intended recipient you are hereby notified that any  
dissemination, copying or distribution of this message, or files associated  
with this message, is strictly prohibited. If you have received this  
message in error, please notify us immediately by replying to the message  
and deleting it from your computer. Messages sent to and from us may be  
monitored.  Internet communications cannot be guaranteed to be secure or  
error-free as information could be intercepted, corrupted, lost, destroyed,  
arrive late or incomplete, or contain viruses. Therefore, we do not accept  
responsibility for any errors or omissions that are present in this  
message, or any attachment, that have arisen as a result of e-mail  
transmission. If verification is required, please request a hard-copy  
version. Any views or opinions presented are solely those of the author and  
do not necessarily represent those of the company. 
  


More information about the Users mailing list