Download Linux Networking Cookbook - lions

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Document related concepts

Lag wikipedia , lookup

Remote Desktop Services wikipedia , lookup

Cracking of wireless networks wikipedia , lookup

Zero-configuration networking wikipedia , lookup

Transcript
See Also
• Nagios.org: http://www.nagios.org/
• Chapter 8, “Managing Users and Groups,” in Linux Cookbook, by Carla Schroder
(O’Reilly)
• Chapter 4, “Installing Programs from Source Code,” in Linux Cookbook
13.2 Configuring Apache for Nagios
Problem
You can read the Nagios HTML docs in a local web browser or HTML-enabled file
browser like Konqueror, but Apache doesn’t seem to know they exist. Nagios needs
Apache support to be fully functional and to display all the status pages and command pages. How do you make it go?
Solution
You need to use Apache’s access controls. First, create an Apache password for the
Nagios user:
# cd /usr/local/nagios/etc/
# htpasswd -c htpasswd.users nagios
New password:
Re-type new password:
Adding password for user nagios
Then, make the password file owned and readable/writable only by the HTTP user:
# chown HTTP user htpasswd.users
# chmod 0600 htpasswd.users
On Fedora, add this directive to your /etc/httpd/conf/httpd.conf file:
Include /etc/httpd/conf.d
Next, create /etc/httpd/conf.d/nagios. On Debian. create /etc/apache2/conf.d/nagios. Add
these directives to the file, using your own subnet on the line Allow from 192.168.1.:
## conf.d/nagios
ScriptAlias /nagios/cgi-bin /usr/local/nagios/sbin
<Directory "/usr/local/nagios/sbin">
Options ExecCGI
AllowOverride None
Order allow,deny
HostnameLookups On
Allow from localhost
Allow from 127.0.0.1
Allow from 192.168.1.
AuthName "Nagios Access"
AuthType Basic
376
|
Chapter 13: Network Monitoring with Nagios