edit · history · print

How to add new check to the host monitored by Nagios

1. On monitored host create another command in /usr/local/nagios/etc/nrpe.cfg . Look for similiar declarations at the end of the file. Basic form is:

 command[command_name]=linux_executable arg1 arg2 ...

2. On the monitoring host (monitor.hep.kbfi.ee in our case) in /usr/local/nagios/etc/objects you have to find a file describing corresponding host group (wns.cfg, service.cfg, dcache.cfg,...).

3. In that file a new service should be described, i.e. appended to the end of the file. Template is (shown for dcache hostgroup):

 define service{
        use generic-service
        hostgroup_name dcache
        service_description checks for some magical property
        check_command check_nrpe!command_name
 }

PS. Here command_name should match command_name from the 1. step.

NB! You have to restart nagios service on monitoring host (monitor.hep.kbfi.ee in our case).

Adding new host to the Nagios system

1. On the monitoring host (monitor.hep.kbfi.ee in our case) in /usr/local/nagios/etc/objects you have to find a file describing corresponding host group (wns.cfg, service.cfg, dcache.cfg,...).

2. Add the description of a new host to the corresponding host group configuration file (name, hostname, template - linux-box in most cases).

edit · history · print
Page last modified on June 03, 2010, at 11:36 AM