cgi-bin directory is not found under nagios.

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
rashmi
Posts: 4
Joined: Thu Jun 26, 2014 8:56 am

cgi-bin directory is not found under nagios.

Post by rashmi »

i cant find cgi-bin directory under nagios and hence accessing the link nagios/cgi-bin/status.cgi?host=all&servicestatustypes=28 from browser gives error message as below :


Whoops!

Error: Could not read object configuration data!

Here are some things you should check in order to resolve this error:

Verify configuration options using the -v command-line option to check for errors.
Check the Nagios log file for messages relating to startup or status data errors.
Make sure you read the documentation on installing, configuring and running Nagios thoroughly before continuing. If all else fails, try sending a message to one of the mailing lists. More information can be found at http://www.nagios.org.


However i have configured the nagio's and it was working all this days now all of sudden i have this error message. when i checked for logs of /var/log/message

i see that nagios has thrown error message as

Jun 26 22:01:45 linux-c4rx nagios: Warning: The check of host '9292_OV_planner' looks like it was orphaned (results never came back). I'm scheduling an immediate check of the host...

hence i tried to below steps:

linux-c4rx:~ # service nagios stop
Stopping nagios: kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec]
done.
linux-c4rx:~ # killall -9 nagios
linux-c4rx:~ # service nagios start
Starting nagios: done.

even then i have same problem. could you please guide me to fix the issue and help me to get nagios working again ?
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: cgi-bin directory is not found under nagios.

Post by slansing »

Setting aside cgi-bin for a moment, have you tried to verify your configs yet? It did not appear as though you did, what is the output of:

Code: Select all

/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Use the above if you installed on RHEL/CENTOS, if not, you will need to change the directories to those of the nagios bin and nagios config file.
rashmi
Posts: 4
Joined: Thu Jun 26, 2014 8:56 am

Re: cgi-bin directory is not found under nagios.

Post by rashmi »

This is the output of i see on executing the config file


linux-c4rx:~ # /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg

Nagios Core 3.2.3
Copyright (c) 2009-2010 Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 10-03-2010
License: GPL

Website: http://www.nagios.org
Reading configuration data...
Read main config file okay...
Processing object config file '/usr/local/nagios/etc/objects/commands.cfg'...
Processing object config file '/usr/local/nagios/etc/objects/contacts.cfg'...
Processing object config file '/usr/local/nagios/etc/objects/timeperiods.cfg'...
Processing object config file '/usr/local/nagios/etc/objects/templates.cfg'...
Processing object config file '/usr/local/nagios/etc/objects/nettv_urls.cfg'...
Read object config files okay...

Running pre-flight check on configuration data...

Checking services...
Checked 541 services.
Checking hosts...
Checked 541 hosts.
Checking host groups...
Checked 41 host groups.
Checking service groups...
Checked 0 service groups.
Checking contacts...
Checked 3 contacts.
Checking contact groups...
Checked 2 contact groups.
Checking service escalations...
Checked 0 service escalations.
Checking service dependencies...
Checked 0 service dependencies.
Checking host escalations...
Checked 0 host escalations.
Checking host dependencies...
Checked 0 host dependencies.
Checking commands...
Checked 20 commands.
Checking time periods...
Checked 5 time periods.
Checking for circular paths between hosts...
Checking for circular host and service dependencies...
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...

Total Warnings: 0
Total Errors: 0

Things look okay - No serious problems were detected during the pre-flight check
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: cgi-bin directory is not found under nagios.

Post by tmcdonald »

What OS and version are you running on?
Is there another website running on the server? Anything else that might mess with the httpd configs?
Former Nagios employee
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: cgi-bin directory is not found under nagios.

Post by lmiltchev »

Is SELinux enabled?

Code: Select all

sestatus
Is apache added to the nagios group?

Code: Select all

grep nag /etc/group
Are the permissions correct?

Code: Select all

ls -lad /usr/local/nagios
ls -lad /usr/local/nagios/etc
ls -la /usr/local/nagios/etc
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked