Page 1 of 1
Error: Could not read host and service status information!
Posted: Thu Jul 11, 2024 7:12 am
by Adith
Hi Team,
Our nagios server was on RHEL 7.9 and we have upgraded our server to RHEL 8 and post that we have installed the latest version of nagios core which is 4.4.14 by following this document.
https://support.nagios.com/kb/article/n ... ce-96.html
Nagios and httpd are running but till nagios console says that is not able to read the hosts and services.
Appreciate the response on this as we have been waiting for a week to get this fixed.
Thanks,
Adith
Re: Error: Could not read host and service status information!
Posted: Thu Jul 11, 2024 10:26 am
by bbahn
Hello @Adith,
It seems that others have encountered similar issues before here:
viewtopic.php?t=57164. I suggest trying the things found there and if you get similar results, it would mean that you are encountering a similar issue (an Apache configuration issue).
Re: Error: Could not read host and service status information!
Posted: Mon Jul 15, 2024 3:15 am
by Adith
Hello,
I did follow the case the documentation links but the commands for a2enmod are not for RHEL and its for Ubuntu.
I have followed this documentation to install nagios from the scratch after our server was upgraded to RHEL 8. Based on the some of the documentation seen, looks like cgi.cfg is unable to check for the right nagios.cfg.
How can we set the cgi.cfg through apache variables?
Thanks,
Adith
Re: Error: Could not read host and service status information!
Posted: Tue Jul 16, 2024 9:24 am
by gwesterman
Hi @Adith,
This user encountered this issue because their nagios config file was not in the default location. They resolved it by setting the apache environment variable NAGIOS_CGI_CONFIG to the config file's new location.
Here is some documentation on setting apache environment variables. There is a lot of additional documentation out there if this doesn't work.
If this resolves your issue or if this isn't the cause, please let us know.
Thank you!
Re: Error: Could not read host and service status information!
Posted: Thu Jul 25, 2024 7:03 am
by Adith
Hi Team,
The issue was actually that nagios was looking for a different cgi.cfg location which got installed when nagios was installed.
I renamed that cgi and reloaded nagios and got to know from the console that it was pointing towards wrong cgi.
Then I updated the correct path in cgi.cfg and then started to work.
Thank you for all the help
Re: Error: Could not read host and service status information!
Posted: Thu Jul 25, 2024 9:16 am
by gwesterman
Hi @Adith,
I'm glad you found a solution!
Please reach out if you have any additional questions.
Thank you!