Hosts jumping in/out from CGI overview


#1

Hello all. I’ve installed Nagios 2.0b3 on a FreeBSD 5.4 machine.

This is my first time trying out Nagios, but I’m fairly confident I set stuff up right, and exhausted my options before coming here asking.

My problem is that my local router (192.168.0.1) dissapears and reapperas on the CGI overview (Host Detail and Hostgroup *)

The entry in hosts.cfg is like this:

define host{ name generic-host notifications_enabled 1 event_handler_enabled 1 process_perf_data 1 retain_status_information 1 retain_nonstatus_information 1 register 0 }

define host{
use generic-host
host_name localrouter
alias Local Router
address 192.168.0.1
check_command check-host-alive
max_check_attempts 10
notification_interval 120
notification_period 24x7
notification_options d,r
contact_groups admins
}

the services for this host is:

define service{ name generic-service active_checks_enabled 1 passive_checks_enabled 1 parallelize_check 1 check_freshness 0 notifications_enabled 1 event_handler_enabled 1 process_perf_data 1 retain_status_information 1 retain_nonstatus_information 1 register 0 }

define service{
use generic-service
host_name localrouter
service_description PING
is_volatile 0
check_period 24x7
max_check_attempts 4
normal_check_interval 5
retry_check_interval 1
contact_groups admins
notification_interval 960
notification_period 24x7
check_command check_ping!100.0,20%!500.0,60%
}

I’ve tried toying around with different options in all of the above, aswell as in the nagios.cfg, pretty much everything I can think of could have any relevanse at all.

So, whats happening is that I can see the router through the web interface for a few seconds, then it’s gone for a few seconds.

I’ve tried issuing the commands manually (sudo -u nagios /usr/local/libexec/nagios/chech_ping -H 192.168.0.1 -w ), and it all works just fine.

Why does it completely dissapear from the interface? If somethings wrong I’d rather see a big fat warning… But hosts NOT showing up just isnt right in a monitoring application.

Any help appreciated.


#2

A little update.
The router is always visible in the Status Map, but when it dissapears from all other places it has the mouseover popup of “Host status information not found” in the map.

Gonna look deeper into this based on that.


#3

I found the problem.
There was a stray nagios process with an old configuration overwriting status.dat

Somehow ‘/usr/local/etc/rc.d/nagios.sh restart’ didnt get that process.