Nagios 3.1.2 + RHEL 5.3 You don't have permission to access /nagios/ on this server
Hi i install nagios on server using this manual:
http://nagios.sourceforge.net/docs/3...rt-fedora.html but when i log in to nagios i see error: You don't have permission to access /nagios/ on this server i search internet but nothing find, please help. [nagios]# ll total 24 drwxrwxr-x 2 nagios nagios 4096 Jul 8 11:03 bin drwxrwxr-x 3 nagios nagios 4096 Jul 8 11:03 etc drwxrwxr-x 2 nagios nagios 4096 Jul 8 10:07 libexec drwxrwxr-x 2 nagios nagios 4096 Jul 8 11:03 sbin drwxrwxr-x 10 nagios nagios 4096 Jul 8 11:03 share drwxrwxr-x 5 nagios nagios 4096 Jul 8 11:39 var [nagios]# cat /etc/group | grep apache apache:x:48: nagcmd:x:501:nagios,apache THX! |
Quote:
What do you mean you do not have permission to access nagios? Is it on a web interface? Is it in the logs? Assuming it is on the web interface, you have to allow apache to access /nagios/. Here is the kind of definition you have to put in the Apache definition for nagios. I know that I have defined one in /etc/nagios2 then asked apache to read the file. Code:
# Where the HTML pages live If you have any other question pls let us know! G. |
Hi, i have no access to web interface , when i use iexplore http://server/nagios , and logon, i see :
Forbidden You don't have permission to access /nagios/ on this server. -------------------------------------------------------------------------------- Apache/2.2.3 (Red Hat) Server at sak-monitor02 Port 80 I have file nagios.conf in /etc/httpd/conf.d: ScriptAlias /nagios/cgi-bin "/usr/local/nagios/sbin" <Directory "/usr/local/nagios/sbin"> # SSLRequireSSL Options ExecCGI AllowOverride None Order allow,deny Allow from all # Order deny,allow # Deny from all # Allow from 127.0.0.1 AuthName "Nagios Access" AuthType Basic AuthUserFile /usr/local/nagios/etc/htpasswd.users Require valid-user </Directory> Alias /nagios "/usr/local/nagios/share" <Directory "/usr/local/nagios/share"> # SSLRequireSSL Options None AllowOverride None Order allow,deny Allow from all # Order deny,allow # Deny from all # Allow from 127.0.0.1 AuthName "Nagios Access" AuthType Basic AuthUserFile /usr/local/nagios/etc/htpasswd.users Require valid-user </Directory> |
Did you restart / reload apache?
Did you check the logs for nagios and apache? |
hi, yes i restart reload apache , in apache log i see :
[Wed Jul 08 11:29:15 2009] [error] [client 10.180.65.100] Directory index forbidden by Options directive: /usr/local/nagios/share/ |
Ok try to change the Options value to:
Code:
Options FollowSymLinks Code:
DirectoryIndex index.html |
steel
Forbidden You don't have permission to access /nagios/ on this server. -------------------------------------------------------------------------------- Apache/2.2.3 (Red Hat) Server at sak-monitor02 Port 80 |
Can you paste, using the "["CODE] "["/CODE] your apache configuration for nagios?
Are you sure you have an include from the main apache configuration file to the nagios configuration file? Please let me know Gael |
I post this code:
I have file nagios.conf in /etc/httpd/conf.d: ScriptAlias /nagios/cgi-bin "/usr/local/nagios/sbin" <Directory "/usr/local/nagios/sbin"> # SSLRequireSSL Options ExecCGI AllowOverride None Order allow,deny Allow from all # Order deny,allow # Deny from all # Allow from 127.0.0.1 AuthName "Nagios Access" AuthType Basic AuthUserFile /usr/local/nagios/etc/htpasswd.users Require valid-user </Directory> Alias /nagios "/usr/local/nagios/share" <Directory "/usr/local/nagios/share"> # SSLRequireSSL Options None AllowOverride None Order allow,deny Allow from all # Order deny,allow # Deny from all # Allow from 127.0.0.1 AuthName "Nagios Access" AuthType Basic AuthUserFile /usr/local/nagios/etc/htpasswd.users Require valid-user </Directory> In main /etc/httpd/conf/httpd.conf i have no enteris fo nagios. |
do you know if the nagios file is loaded by apache?
A line which looks like the following: Code:
Include /etc/apache2/sites-enabled/ Code:
cd /etc/httpd/ G. |
I have the same permission problem with nagios 3.1.2.
Here is my output of your advise: Code:
[root@tcentos ~]# cd /etc/httpd/ here is my httpd error log: Quote:
lol. i solved the issue: just installed php and everythink works fine :=) for my centos: Quote:
|
hi guys,
met with the exact same problem. problem was in http.conf. DirectoryIndex was set to index.html. nagios uses an index.php file. so i have change one virtual host to be 'DirectoryIndex index.php index.html'. works perfectly fine, while the other virtual hosts gives me the 'You don't have permission to access /nagios/ on this server.' hope that helps ;) |
Yes it was PHP issue
Installed php
Restarted Apache Restarted nagios Done Excellent Thanks for help |
in my case i am on gentoo, what solved it is adding:
Code:
-D NAGIOS -D PHP5 in /etc/conf.d/apache2 |
All times are GMT -5. The time now is 05:13 PM. |