PDA

View Full Version : 'Run Nagios Debug' under Nagios>Generate gives no output


p2im0
08-22-2007, 09:58 PM
I've been running Nagios 2.9 and Oreon 1.4 on a Dell 2650 since May flawlessly. Since then I've been prepping the system to replace our current production system running Nagios 1.0.

I habitually used the 'Run Nagios Debug (-v)' option under the Configuration>Nagios>Generate section to test my configs before I exported them and restarted Nagios. I went away for a week on vacation, now since I've come back the debug feature produces NO OUTPUT.

Doing it manually on the box "./nagios -v ../etc/nagios.cfg" works fine and provides the expected debug output. Does anyone know what could cause this to mysteriously stop providing output?

Appreciate the help (btw I leave my internship at the company this Friday Aug 24th, so any immediate input would be great)

Thanks,
P2iM0

DonKiShoot
08-23-2007, 10:39 AM
First check your sudo configuration for Centreon.

p2im0
08-23-2007, 06:16 PM
First check your sudo configuration for Centreon.

Care to elaborate a bit?
Be sure the nagios user has sudo capabilities?

DonKiShoot
08-23-2007, 06:32 PM
Look your message and apache error file and with visudo check that :

#Add by OREON
User_Alias OREON=apache

## Nagios Restart
OREON ALL = NOPASSWD: /etc/init.d/nagios restart
## Nagios reload
OREON ALL = NOPASSWD: /etc/init.d/nagios reload
## Snmptrapd Restart
OREON ALL = NOPASSWD: /etc/init.d/snmptrapd restart

p2im0
08-23-2007, 06:42 PM
Look your message and apache error file and with visudo check that :

#Add by OREON
User_Alias OREON=apache

## Nagios Restart
OREON ALL = NOPASSWD: /etc/init.d/nagios restart
## Nagios reload
OREON ALL = NOPASSWD: /etc/init.d/nagios reload
## Snmptrapd Restart
OREON ALL = NOPASSWD: /etc/init.d/snmptrapd restart

yes all of that is in the sudoers file.
I wasn't sure if that was the default so I tried out adding

OREON ALL = NOPASSWD: /usr/local/nagios/bin/nagios -v

just to see if it "should" have been there. Got nothing.

p2im0
08-24-2007, 04:00 PM
BUMP.
Any other suggestions? Reinstalling isn't an option as the box just went into production. Has anyone else even had this issue?

helia
10-12-2007, 09:09 PM
hello,
My sudoers is correct but nagios dont restart through centreon. if you have a solution, please give me.
do i restart my server after modify sudoers?
thanks

WAtt
10-13-2007, 12:19 AM
Hi,

Check right on nagios binaries.

all exec right for "Other" (chmod o+x /usr/bin/nagios)

If you upgrade Nagios after install oreon/centreon, default right isn't 555.

helia
10-15-2007, 01:24 PM
Hi,
right for binarie nagios is OK :
-rwxrwxr-x 1 nagios nagios 1453408 Oct 10 13:46 nagios
What else please ?

helia
10-16-2007, 08:23 PM
the user nagios dont have password to be execute by the user apache. With solaris, the command is :
passwd -d nagios
It's OK now
good luck

EricKvD
10-17-2007, 09:33 AM
You could also check that the path used by Centreon are the good ones:

Options -> General Options --> Nagios