Search Site:

About

Linux

Printers?

Programming

Windows?

Download

Skins

Edit - To Do - AllRecentChanges

Recent Changes Printable View Page History Edit Page

Linux.ServerMonitoring History

Hide minor edits - Show changes to markup

Monday 04 July 2005, at 12:32 GMT+8 by testert -
Changed lines 1-2 from:

TO BE COMPLETED

to:

TO BE COMPLETED

Changed lines 110-112 from:
  • http://www.nagios.com/
to:
  • http://www.nagios.com/

(:comments:)

Sunday 15 May 2005, at 15:35 GMT+8 by Renaud -
Changed lines 17-18 from:

I use the [Linux/PackageManagement Dag apt]] software repository. It contains a lot of extra packages that are not available elsewhere, including all the Nagios goodies.

to:

I use the Dag apt? software repository. It contains a lot of extra packages that are not available elsewhere, including all the Nagios goodies.

Sunday 06 February 2005, at 15:47 GMT+8 by Renaud -
Added lines 1-2:

TO BE COMPLETED

Friday 30 July 2004, at 01:05 GMT+8 by Renaud -
Changed line 20 from:

=dosbatch [=

to:

=bash [=

Changed line 33 from:

=dosbatch [=

to:

=bash [=

Changed line 37 from:

=dosbatch [=

to:

=bash [=

Changed line 45 from:

=dosbatch [=

to:

=xml [=

Changed line 72 from:

=dosbatch [=

to:

=bash [=

Changed line 77 from:

=dosbatch [=

to:

=bash [=

Changed line 88 from:

=dosbatch [=

to:

=bash [=

Friday 30 July 2004, at 00:53 GMT+8 by Renaud -
Changed line 2 from:

Nagios is an Open Source infrastructure allowing a single server to monitor a bunch of servers and computers remotely. For basic monitoring, like checking network connection, server services, etc, there is no need to install any software on the client PCs. If you need more information, there are spacial services that can be installed on each PC to collect information and forward it to the main Nagios Server.

to:

Nagios is an Open Source infrastructure allowing a single server to monitor a bunch of disparate servers and computers remotely. For basic monitoring, like checking network connection, server services, etc, there is no need to install any software on the client PCs. If you need more data, there are special services that can be installed on each PC to collect information and forward it to the main Nagios Server.

Changed line 4 from:

It's a pretty flexible architecture: it is possible to create your own monitoring modules in C or Perl, there is a pretty complete web interface available, and Nagios can also warn you by email, pager or mobile (though third-party services) to let you know of problems. All network configurations are possible to monitor as you can set up intermediary servers to listen and collect data from a local network and forward that information to a main Nagios Server.

to:

It's a pretty flexible architecture: it is possible to create your own monitoring modules in C or Perl, there is a pretty complete web interface available, and Nagios can also warn you by email, pager or mobile (though third-party services) to let you know of problems. All network configurations are possible to monitor as you can set up intermediary servers to listen and collect data from a local network which the main server can collect securely.

Changed lines 12-13 from:

It is true that power and flexibility are often poor friends of ease of installation. Having said that, I did not find Nagios to be more complicated than settings up most other server software under Linux: if you have ever had to configure a web or mail server, then Nagios is not as hard. On RedHat and Fedora, it's even pretty easy to install core functionality when using pre-packaged RPMs.

to:

It is true that power and flexibility are often poor friends of ease of installation. Having said that, installing Nagios is fairly straightforward, especially On RedHat and Fedora where it's even pretty easy to install core functionality using pre-packaged RPMs. Configuration is another matter: Nagios is flexible and can adapt to almost any scenario, that's the only way to ensure you get what you want out of it, rather than being force-fed someone else's view of what you should get.

Changed line 15 from:

I use the {{Linux/PackageManagement Dag apt}} repository. It contains a lot of extra packages that are not available elsewhere, including all the Nagios goodies.

to:

I use the [Linux/PackageManagement Dag apt]] software repository. It contains a lot of extra packages that are not available elsewhere, including all the Nagios goodies.

Changed lines 99-108 from:

=]

to:

=]

References

How to setup Nagios:

  • http://www.onlamp.com/pub/a/onlamp/2002/09/05/nagios.html?page=1 Installing Nagios
  • http://www.onlamp.com/pub/a/onlamp/2002/09/26/nagios.html Configuring Nagios
  • http://www.linuxjournal.com/article.php?sid=6767 Network Management with Nagios
  • http://www.samag.com/documents/sam0310c/ Network Monitoring with Nagios
  • http://www.samag.com/documents/sam0311i/ Advanced Configuration of Nagios

Nagios Site:

  • http://www.nagios.com/
Thursday 29 July 2004, at 19:10 GMT+8 by Renaud -
Changed line 7 from:

Below is what I did to make Nagios work for me. Tehre are more comprehensive notes on the main site. I suggest you follow the following pages in sequence:

to:

Below is what I did to make Nagios work for me. There are more comprehensive notes on the main site. I suggest you follow the following pages in sequence:

Changed line 14 from:

I use the {{Linux/PackageManagement Dabs apt}} repository. It contains a lot of extra packages that are not available elsewhere, including all the Nagios goodies.

to:

I use the {{Linux/PackageManagement Dag apt}} repository. It contains a lot of extra packages that are not available elsewhere, including all the Nagios goodies.

Changed line 16 from:

Make sure that Apache can run on your server. You will need it to access the web interface.

to:

Note: Make sure that Apache can run on your server. You will need it to access the web interface.

Added lines 40-42:

Note: the RPM packages follow a different convention for the location of the Nagios files. Files are not in the same location as mentionned in the Nagios documentation. To find them all on your server, do a find / -iname '*nagios*'.

Added lines 70-78:

Create the special user that will allowed access to the server and make sure that httpd can read it (Apache generally runs under the apache or httpd user):

# htpasswd -c /etc/nagios/htpasswd.users nagiosadmin
# chown apache.apache /etc/nagios/htpasswd.users

You can add more users later (omit the -c switch, otherwise your password file will be overwritten instead of appended):

# htpasswd /etc/nagios/htpasswd.users <username>
Changed line 80 from:

Restart your web server with service httpd restart and connect to your Nagios server (assumed here to be 192.168.0.50) from a web browser on your network: http://192.168.0.50/nagios/. You should be greeted by the following screen if everything was OK:

to:

Restart your web server with service httpd restart and connect to your Nagios server (assumed here to be 192.168.0.50) from a web browser on your network: http://192.168.0.50/nagios/. You should be greeted by the following screen if everything was and you entered your ''nagiosadmin'/<password>' pair correctly:

Added lines 84-98:

If you can't pass the authentication or get a server error, check your error log to find what went wrong: tail /var/log/httpd/error_log.

Configuration

Now, since I want to be in control of everything, modify the /etc/nagios/cgi.cfg as such (uncomment the lines if necessary):

...
use_authentication=1
authorized_for_system_information=nagiosadmin
authorized_for_configuration_information=nagiosadmin
authorized_for_system_commands=nagiosadmin
authorized_for_all_services=nagiosadmin
authorized_for_all_hosts=nagiosadmin
authorized_for_all_service_commands=nagiosadmin
authorized_for_all_host_commands=nagiosadmin
...
Thursday 29 July 2004, at 18:30 GMT+8 by Renaud -
Changed line 40 from:

By default, access to the Nagios web interface is restricted to localhost. You can change that if you need to enable access from your local network: edit the Nagios web configuration file /etc/httpd/conf.d/nagios.conf (change the C class address 192.168.0.0 by whatever is it you use):

to:

By default, access to the Nagios web interface is restricted to localhost and there is no restriction on who can run the -potentially harmfull- CGI scripts. You can change that by editing the Nagios web configuration file /etc/httpd/conf.d/nagios.conf (change the C class address 192.168.0.0 by whatever is it you use for your LAN):

Changed lines 42-44 from:

... allow from 192.168.0.0/255.255.255.0 ...

to:

ScriptAlias /nagios/cgi-bin/ /usr/lib/nagios/cgi/ <Directory /usr/lib/nagios/cgi/>

   Options ExecCGI
   order deny,allow
   deny from all
   allow from 192.168.0.0/255.255.255.0 127.0.0.1
   AuthName "Nagios Access"
   AuthType Basic
   AuthUserFile /etc/nagios/htpasswd.users
   require valid-user

</Directory>

Alias /nagios/ /usr/share/nagios/ <Directory /usr/share/nagios/>

   Options None
   order deny,allow
   deny from all
   allow from 192.168.0.0/255.255.255.0 127.0.0.1
   AuthName "Nagios Access"
   AuthType Basic
   AuthUserFile /etc/nagios/htpasswd.users
   require valid-user

</Directory>

Added lines 67-71:

Restart your web server with service httpd restart and connect to your Nagios server (assumed here to be 192.168.0.50) from a web browser on your network: http://192.168.0.50/nagios/. You should be greeted by the following screen if everything was OK:

http:/pub/images/ServerMonitoring01.png

Thursday 29 July 2004, at 17:43 GMT+8 by Renaud -
Added lines 7-10:

Below is what I did to make Nagios work for me. Tehre are more comprehensive notes on the main site. I suggest you follow the following pages in sequence:

  • http://nagios.sourceforge.net/docs/1_0/installing.html Installing Nagios
  • http://nagios.sourceforge.net/docs/1_0/installweb.html Setting Up The Web Interface
  • http://nagios.sourceforge.net/docs/1_0/cgiauth.html Authentication And Authorization In The CGIs
Changed line 12 from:

It is true that power and flexibility are often poor friends of ease of installation. Having said that, I did not find Nagios to be more complicated than settings up most other server software under Linux: if you have ever had to configure a web or mail server, then NAgios is not as hard. On RedHat and Fedora, it's even pretty easy to install core functionality when using pre-packaged RPMs.

to:

It is true that power and flexibility are often poor friends of ease of installation. Having said that, I did not find Nagios to be more complicated than settings up most other server software under Linux: if you have ever had to configure a web or mail server, then Nagios is not as hard. On RedHat and Fedora, it's even pretty easy to install core functionality when using pre-packaged RPMs.

Thursday 29 July 2004, at 17:37 GMT+8 by Renaud -
Added lines 12-13:

Make sure that Apache can run on your server. You will need it to access the web interface.

Changed line 27 from:

For now, only install the necessary modules:

to:

For now, only install the necessary packages:

Changed lines 31-42 from:
to:

Check that the following line has been inserted and is not commented out at the end of your Apache main configuration file /etc/httpd/conf/httpd.conf:

...
Include /etc/httpd/conf.d/nagios.conf

By default, access to the Nagios web interface is restricted to localhost. You can change that if you need to enable access from your local network: edit the Nagios web configuration file /etc/httpd/conf.d/nagios.conf (change the C class address 192.168.0.0 by whatever is it you use):

...
allow from 192.168.0.0/255.255.255.0
...

Don't open your server to the world (allow from all) just yet as it has not yet been secured!

Thursday 29 July 2004, at 17:27 GMT+8 by Renaud -
Changed lines 1-29 from:

Describe ServerMonitoring here.

to:

I am using http://www.nagios.org/ Nagios to remotely monitor my servers. Nagios is an Open Source infrastructure allowing a single server to monitor a bunch of servers and computers remotely. For basic monitoring, like checking network connection, server services, etc, there is no need to install any software on the client PCs. If you need more information, there are spacial services that can be installed on each PC to collect information and forward it to the main Nagios Server.

It's a pretty flexible architecture: it is possible to create your own monitoring modules in C or Perl, there is a pretty complete web interface available, and Nagios can also warn you by email, pager or mobile (though third-party services) to let you know of problems. All network configurations are possible to monitor as you can set up intermediary servers to listen and collect data from a local network and forward that information to a main Nagios Server.

Installation

Nagios has a reputation of being fairly convoluted to install and configure. It is true that power and flexibility are often poor friends of ease of installation. Having said that, I did not find Nagios to be more complicated than settings up most other server software under Linux: if you have ever had to configure a web or mail server, then NAgios is not as hard. On RedHat and Fedora, it's even pretty easy to install core functionality when using pre-packaged RPMs.

I use the {{Linux/PackageManagement Dabs apt}} repository. It contains a lot of extra packages that are not available elsewhere, including all the Nagios goodies.

To see what packages are available:

# apt-cache search nagios
nagios - Open Source host, service and network monitoring program.
nagios-devel - Header files, libraries and development documentation for nagios.
nagios-nrpe - Nagios Remote Plug-ins Execution daemon
nagios-nsca - Nagios Service Check Acceptor.
nagios-plugins - Host/service/network monitoring program plugins for Nagios
nagios-plugins-nrpe - Nagios plug-in for NRPE
nsc - Console monitor for Nagios

Not all of these packages need to be installed. Remember that some are meant to run on remote clients. We'll deal with those later. For now, only install the necessary modules:

# apt-get install nagios nagios-plugins
Edit Page - Page History - Printable View - Recent Changes - WikiHelp - Search - RSS -
Page last modified on Monday 04 July 2005, at 12:32 GMT+8 - Viewed 7832 times