Hi all,
New to the forum, a complete virgin with Linux and taking baby steps with nagios! Yes im a complete beginner!
Anyhow to the matter on hand.
Latest nagios running on Ubuntu Desktop 11.04 32-bit.
I followed this guide to install
ubuntugeek.com/nagios-networ … 1#comments
If i try to change any settings in the web interface for hosts (such as enable notifications) i get the following error
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 occured while attempting to commit your command for processing
But…
If i run: chmod 777 /usr/local/nagios/var/rw/nagios.cmd
I am able to commit changes using the we interface
That is until the machine is rebooted and then it goes back to Permission denied.
I login to the ubuntu machine as FTLADMIN and there is also a user called NAGIOS created.
I log into the web interface as NAGIOSADMIN
Here is an output from command: ls -al /usr/local/nagios/var
**ftladmin@FTLUBUNTU:~$ ls -al /usr/local/nagios/var
total 84
drwxrwxrwx 4 nagios root 4096 2011-10-21 16:22 .
drwxr-xr-x 9 nagios root 4096 2011-10-20 16:33 …
-rw-r–r-- 1 nagios nagios 4 2011-10-21 16:12 nagios.lock
-rw-r–r-- 1 nagios nagios 5674 2011-10-21 16:12 nagios.log
-rw-r–r-- 1 nagios nagios 14655 2011-10-21 16:12 objects.cache
-rw------- 1 nagios nagios 16530 2011-10-21 16:12 retention.dat
drwxrwsr-x 2 nagios nagios 4096 2011-10-21 16:12 rw
drwxr-xr-x 3 nagios root 4096 2011-10-20 16:41 spool
-rw-rw-r-- 1 nagios nagios 16667 2011-10-21 16:22 status.dat
ftladmin@FTLUBUNTU:~$ **
Here is an output from ls -al /usr/local/nagios/var/rw
**ftladmin@FTLUBUNTU:~$ ls -al /usr/local/nagios/var/rw
total 8
drwxrwsr-x 2 nagios nagios 4096 2011-10-21 16:12 .
drwxrwxrwx 4 nagios root 4096 2011-10-21 16:26 . .
prw-rw---- 1 nagios nagios 0 2011-10-21 16:12 nagios.cmd
ftladmin@FTLUBUNTU:~$ **
After i have run chmod 777 /usr/local/nagios/var/rw/nagios.cmd this is the output of ls -al /usr/local/nagios/var/rw
**ftladmin@FTLUBUNTU:~$ ls -al /usr/local/nagios/var/rw
total 8
drwxrwsr-x 2 nagios nagios 4096 2011-10-21 16:12 .
drwxrwxrwx 4 nagios rott 4096 2011-10-21 16:26 . .
prwxrwxrwx 1 nagios nagios 0 2011-10-21 16:12 nagios.cmd
ftladmin@FTLUBUNTU:~$ **
So how to i permanently have access to this file to make changes with the web interface?
I have read loads of docs that suggest adding the apache user to the nagios group but i dont have an apache user!?
Any help is appreciated.
If you need any more info then please ask - but bear in mind i can write my linux/nagios knowledge on the back of a fag packet!
Cheers guys