I'm getting "Whoops!" msg

Hello,

I installed Nagios today but for some reason it doesn’t wanna work… I installed on RedHat 9.0, the service start just fine:

nagios 2642 0.0 0.1 10300 1012 pts/1 S 22:32 0:00 /usr/local/nagios/bin/nagios nagios.cfg
nagios 2767 0.0 0.1 3568 624 pts/0 S 22:46 0:00 grep nagios

I verfied the Log and this is what I have in my log:

[1139956361] Nagios 2.0 starting… (PID=2642)
[1139956361] LOG VERSION: 2.0

I’m not using mySQL, everything is text file… we I login to Nagios page, I’m getting the following error:

Whoops!
Error: Could not read host and service status information!

The most common cause of this error message (especially for new users), is the fact that Nagios is not actually running. If Nagios is indeed not running, this is a normal error message. It simply indicates that the CGIs could not obtain the current status of hosts and services that are being monitored. If you’ve just installed things, make sure you read the documentation on starting Nagios.

Some other things you should check in order to resolve this error include: …

run
ps -ef | grep nagios
and check the output
is nagios running?

run the confgiuration check (-v option) and see what the output is.

If you still have no clue as to what is going wrong check the logs

Luca

Luca,

this is the result of ps -ef | grep nagios:

nagios 1844 1 0 Feb14 ? 00:00:02 /usr/local/nagios/bin/nagios nagios.cfg

which means the nagios is running just fine … when you say check the log, you mean the nagios.log in /usr/local/nagios/var…right? if yes, here is my log:

[1139961600] LOG ROTATION: DAILY
[1139961600] LOG VERSION: 2.0
[1139961600] CURRENT HOST STATE: localhost;UP;HARD;1;PING OK - Packet loss = 0%, RTA = 0.03 ms
[1139961600] CURRENT SERVICE STATE: localhost;PING;OK;HARD;1;PING OK - Packet loss = 0%, RTA = 0.01 ms
[1139963628] Auto-save of retention data completed successfully.
[1139965199] Warning: A system time change of 1 seconds (backwards in time) has been detected. Compensating…
[1139966208] Caught SIGHUP, restarting…
[1139966208] Caught SIGHUP, restarting…
[1139966208] Nagios 2.0 starting… (PID=1844)
[1139966208] LOG VERSION: 2.0
[1139969808] Auto-save of retention data completed successfully.
[1139973408] Auto-save of retention data completed successfully.
[1139977008] Auto-save of retention data completed successfully.

as you can see, it seems to be running ok but I’m still getting the same error msg. I also used -v and I’m getting 0 error amd 0 warnning…

Please help

This is probably a really long shot (since I don’t know how Nagios would error without any configuration files), but check your /usr/local/nagios/etc directory and verify that there are indeed .cfg files in there, and check nagios.cfg to make sure that it’s configured to use those .cfg files (you’ll also need to make sure that those lines aren’t commented out).

Perhaps you should read through the docs again. It appears you haven’t setup apache correctly to access the cgi’s. That is, if the cgi’s even exist, which they might not.