Nagios, nginx and external commands
Posted: Tue Dec 08, 2015 2:52 am
Hello,
We recently decided to start fresh with our monitoring, going from Nagios 3 to Nagios 4, and using Nginx to serve the site.
Now, everything has been going smooth, except executing external commands. For some reason or another, I'm unable to execute external commands. I can restart / shut down the process, and perform commands relating to the actual Nagios process. However, when I try running e.g a "Reschedule the next check for this host", I get "Sorry, but you are not authorized to commit the specified command.".
I was wondering if anyone is able to point me in the right direction.
My cgi.cfg:
We recently decided to start fresh with our monitoring, going from Nagios 3 to Nagios 4, and using Nginx to serve the site.
Now, everything has been going smooth, except executing external commands. For some reason or another, I'm unable to execute external commands. I can restart / shut down the process, and perform commands relating to the actual Nagios process. However, when I try running e.g a "Reschedule the next check for this host", I get "Sorry, but you are not authorized to commit the specified command.".
I was wondering if anyone is able to point me in the right direction.
My cgi.cfg:
relevant permissions:physical_html_path=/usr/local/nagios/share
url_html_path=/nagios
use_authentication=1
default_user_name=nagiosadmin
authorized_for_system_information=nagiosadmin
authorized_for_system_commands=nagiosadmin
authorized_for_configuration_information=nagiosadmin
authorized_for_all_hosts=nagiosadmin
authorized_for_all_host_commands=nagiosadmin
authorized_for_all_services=nagiosadmin
authorized_for_all_service_commands=nagiosadmin
default_statusmap_layout=5
default_statuswrl_layout=4
refresh_rate=90
ping_syntax=/bin/ping -n -U -c 5 $HOSTADDRESS$
main_config_file=/usr/local/nagios/etc/nagios.cfg
root@newnag:/usr/local/nagios/var/rw# ls -l
total 0
prw-rw---- 1 nagios nagcmd 0 Dec 7 18:41 nagios.cmd
Thanks in advance!root@newnag:/usr/local/nagios/sbin# ls -l
total 5096
-rwxrwxr-x 1 nagios nagcmd 318712 Dec 2 06:51 archivejson.cgi
-rwxrwxr-x 1 nagios nagcmd 302368 Dec 2 06:51 avail.cgi
-rwxrwxr-x 1 nagios nagcmd 295008 Dec 2 06:51 cmd.cgi
-rwxrwxr-x 1 nagios nagcmd 265688 Dec 2 06:51 config.cgi
-rwxrwxr-x 1 nagios nagcmd 310528 Dec 2 06:51 extinfo.cgi