Unix/Linux OS/Nagios

Advertisement


Question
I am getting the following error,

"Forbidden

You don't have permission to access /nagios/ on this server.
Apache/2.2.15 (Red Hat) Server at localhost Port 80"

after completing Nagios installation and visiting "http://localhost/nagios" on firefox web browser. How can I solve this.

Answer
Hi Gerald.

Obviously, Nagios has Web interface and access to it must be enabled, which is a normal and secure way of installing things.

Depending on your setup, you may have a GUI for configuring Nagios (Gnome, KDE,...) or you may have to enable it manually.

If manually, locate your Apache configuration, see if there is a config fragment for Nagios. Something like:

/etc/httpd/conf/extra/nagios-*.conf

The path may vary, depending on the distribution. Or it may be missing, completely, in which case you may want to create it and include it in your master config file (httpd.conf).

In that fragment you should enable access to Nagios from the hosts you want to access it from. In your case it would be only "localhost". So, something of this sort would do:

<Location "/nagios">
   Order deny,allow
   Deny from all
   Allow from localhost

   ...The Nagios access goes here, CGI, whatever...
</Location>

I do not know how Nagios actually serves its web interface, so the part with "..." is for you to find or figure out. I would expect Nagios to place the fragment in your Apache config, so you would need only to uncomment some parts.

Nix.

Unix/Linux OS

All Answers


Answers by Expert:


Ask Experts

Volunteer


nix

Expertise

UNIX, programing, C, C++, awk, shell scripts, Web, HTTP, Apache, firewall, AltaVista firewall, E-Mail, sendmail, IMAP4 POP3, DNS, NTP, system administration, TCP/IP, security

Experience

UNIX
Digital UNIX
AltaVista Firewall
TCP/IP

Education/Credentials
BSCS

©2016 About.com. All rights reserved.