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.
I have this errore in the web interface whene I try to enable notifications for check_http and check_ssh:
Error: Could not open command file '/usr/local/nagios/var/rw/nagios.cmd' for update!
The permissions on the external command file and/or directory may be incorrect. Read the FAQs on how to setup proper permissions.
An error occurred while attempting to commit your command for processing.
Return from whence you came
module NagiosRule 1.0;
require {
type httpd_sys_script_t;
type usr_t;
class fifo_file { write getattr open };
}
#============= httpd_sys_script_t ==============
allow httpd_sys_script_t usr_t:fifo_file open;
#!!!! This avc is allowed in the current policy
allow httpd_sys_script_t usr_t:fifo_file { write getattr };
Also, with SELinux systems, people sometimes forget 'ls -Z' is your friend.
[root@studentstation10 ~]# service nagios status
nagios (pid 2522) is running...
[root@studentstation10 ~]# ls -l /usr/local/nagios/var/rw
total 0
prw-rw----. 1 nagios nagcmd 0 Mar 22 11:40 nagios.cmd
[root@studentstation10 ~]#
tlum wrote:Are you running with SELinux active? If so, this is real common, you'll need to install a custom policy like:
module NagiosRule 1.0;
require {
type httpd_sys_script_t;
type usr_t;
class fifo_file { write getattr open };
}
#============= httpd_sys_script_t ==============
allow httpd_sys_script_t usr_t:fifo_file open;
#!!!! This avc is allowed in the current policy
allow httpd_sys_script_t usr_t:fifo_file { write getattr };
Also, with SELinux systems, people sometimes forget 'ls -Z' is your friend.