Error accessing or executing Nagios binary '/usr/local/www/apache22/data/bin/nagios'.
Cannot run the mandatory syntax check.
How to decide a problem?
Generate Nagios config
Re: Generate Nagios config
Hi!
Check that the nagios Binary is executable (chmod +x nagios) and for the webserver-User (Mostly www-data, chown www-data:www-data nagios) readable.
Also look at http://sourceforge.net/apps/mediawiki/n ... _binary.22
Greetings
Strolz Johann
Check that the nagios Binary is executable (chmod +x nagios) and for the webserver-User (Mostly www-data, chown www-data:www-data nagios) readable.
Also look at http://sourceforge.net/apps/mediawiki/n ... _binary.22
Greetings
Strolz Johann
Re: Generate Nagios config
I vaguely recall something with Apache/PHP when calling commands within included files that the user attempting to run them ends up not being 'apache'. Which requires you to allow any user execute permissions (`chmod +x /usr/local/nagios/bin/nagios`).
Is there a way around this? Could nconf's code be changed so that when it makes system calls with PHP's exec() it actually uses the user Apache is running as? Clearly it would be more secure than allowing any user +x on the Nagios binary.
Is there a way around this? Could nconf's code be changed so that when it makes system calls with PHP's exec() it actually uses the user Apache is running as? Clearly it would be more secure than allowing any user +x on the Nagios binary.
- agargiulo
- NConf developer
- Posts:725
- Joined:Fri Mar 06, 2009 17:50
- Location:Zurich, Switzerland
- Contact:
Re: Generate Nagios config
As far as I know, any executed commands, whether they are included or not, are always run as the "apache" user. Apache/PHP simply start a child process. Unless maybe you have configured something differently in you PHP conf, or are using special modules like PHPSuexec.
Does changing the nagios binary to rwx-r-x-r-x (755) do the trick for you? Who is the owner of the file?
Does changing the nagios binary to rwx-r-x-r-x (755) do the trick for you? Who is the owner of the file?
A.G. - NConf developer - http://www.nconf.org
If you like NConf,
rate it here: https://sourceforge.net/projects/nconf/reviews/
or here: http://exchange.nagios.org/directory/Ad ... nf/details
If you like NConf,
rate it here: https://sourceforge.net/projects/nconf/reviews/
or here: http://exchange.nagios.org/directory/Ad ... nf/details