Hi,
I am getting the below error while trying to update External commands like "Send Custom Service Notification" from Nagios Web Interface. Can Someone please help me to resolve this issue..? Thanks in advance.
----------------------------------------------------------------------------------------------------------------------------------------------------------------
Error: Could not open command file '/apps/tools/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
-----------------------------------------------------------------------------------------------------------------------------------------------------------------
I have given the drwxrwsrwx permission for 'rw' directory. refer the below details for rw directory permission.
drwxrwsrwx 2 nagios nagcmd 4096 May 25 10:16 rw
Regards,
Sachikanta
Getting error when using external command [Solved]
-
msachikanta
- Posts: 58
- Joined: Tue Jan 03, 2012 2:35 am
Getting error when using external command [Solved]
Last edited by msachikanta on Wed Jun 20, 2012 7:45 am, edited 1 time in total.
Re: Getting error while trying to update external command
Do all the directories leading up to 'rw' also have good permissions for nagios?
-
msachikanta
- Posts: 58
- Joined: Tue Jan 03, 2012 2:35 am
Re: Getting error while trying to update external command
yes.. infact Nagios is the owner and having 775 permission to all the leading directories to 'rw'. here is the details for your reference.
drwxrwxr-x 11 nagios nagios 4096 Mar 20 15:32 nagios
drwxrwxr-x 5 nagios nagios 4096 May 28 11:28 var
drwxrwsrwx 2 nagios nagcmd 4096 May 25 10:16 rw
Regards,
Sachikanta
drwxrwxr-x 11 nagios nagios 4096 Mar 20 15:32 nagios
drwxrwxr-x 5 nagios nagios 4096 May 28 11:28 var
drwxrwsrwx 2 nagios nagcmd 4096 May 25 10:16 rw
Regards,
Sachikanta
Re: Getting error while trying to update external command
Open "/etc/group" in a text editor:
and make sure you have "apache" (if you are using apache) added to the "nagcmd":
Hope this helps.
Code: Select all
vi /etc/groupCode: Select all
nagcmd:x:501:nagios,apacheBe sure to check out our Knowledgebase for helpful articles and solutions!
-
msachikanta
- Posts: 58
- Joined: Tue Jan 03, 2012 2:35 am
Re: Error while trying to update external command [solved]
Thanks... it works... 
additionally i changed the permission for rw directory as below.
chmod -R u=rwx,g=rwxs,o=rwx rw/
then it started working fine.
Regards,
Sachikanta
additionally i changed the permission for rw directory as below.
chmod -R u=rwx,g=rwxs,o=rwx rw/
then it started working fine.
Regards,
Sachikanta
Re: Getting error while trying to update external command
Glad your issue was resolved.