Quick installation of CentosNagios monitoring platform

Source: Internet
Author: User
Nagios is an open-source free network monitoring tool that can effectively monitor the status of Windows, Linux and Unix hosts, network settings such as vswitches and routers, and printers. 1. first install apache: install apache in yum mode. the installation command is yuminstall? After installing apache, yhttpd starts the apache command/etc/init. d/htt Nagios is an open-source free network monitoring tool that can effectively monitor the status of Windows, Linux and Unix hosts, network settings such as vswitches and routers, and printers.

1. install apache first:

Install apache using yum. the command is yum install? After installing apache, run the apache command/etc/init. d/httpd restart!

 

II. install php:

Nagios is a php-based speech program. Therefore, you need to install php and install yum install php-devel-y in Yum mode.

3. download nagios:

Now the nagios version and client plug-in addresses are as follows: wget http://sourceforge.net/projects/nagios/files/nagios-3.x/nagios-3.2.1/nagios-3.2.1.tar.gz/download wget http://sourceforge.net/projects/nagiosplug/files/nagiosplug/1.4.15/nagios-plugins-1.4.15.tar.gz/download wget http://jaist.dl.sourceforge.net/project/nagios/nrpe-2.x/nrpe-2.13/nrpe-2.13.tar.gz create users maintain Nagios users and groups useradd nagios passwd nagios

4. install the Nagios, nrpe, and nagios extensions on the server:

Install Nagios tar zxvf nagios-3.2.1.tar.gz cd nagios-3.2.1. /configure -- prefix =/usr/local/nagios -- with-nagios-user = nagios -- with-nagios-group = nagios make all make install // to install the main program, CGI and HTML files make install-init // in/etc/rc. d/init. d. install the startup script make install-config // to install the sample configuration file, the installation path is/usr/local/nagios/etc make install-commandmode // to configure directory permission make install-webconf write configuration file install Nagios-plugins tar zxvf nagios-plugins-1.4.15.tar.gz cd nagios-plugins-1.4.15. /configure -- prefix =/usr/local/nagios -- with-nagios-user = nagios -- with-nagios-group = nagios make & make install nrpe tar-xzf nrpe-2.13.tar.gz && cd nrpe-2.13 &&. /configure -- enable-ssl -- with-ssl-lib & make all & make install-plugin & make install-daemon-config chown-R nagios: nagios/usr/local/nagios // usr/local/nagios/bin/nrpe-c/usr/local/nagios/etc/nrpe. cfg-d start the nrpe service

 

5. create a web access User:

Add a user for access control verification: (the parameter c must be added during the first creation) htpasswd-c/usr/local/nagios/etc/htpasswd. users nagiosadmin nagios installation is complete, then restart apache, restart nagios,/etc/init. d/nagios restart access: http: // localhost/nagios! You can access the initial installation interface of nagios.

 

6. install nrpe and nagios-plugin on the client:

First Download nagios-plugins-1.4.15.tar.gzand nrpe-2.13.tar.gz, and execute the following script :#! /Bin/sh ### auto make install nagios_plugin and nrpe useradd nagios tar-xzf nagios-plugins-1.4.15.tar.gz & cd nagios-plugins-1.4.15 &&. /configure -- prefix =/usr/local/nagios & make install sleep 2 echo "This is make install nrpe, please waiting .................. "cd .. /; tar-xzf nrpe-2.13.tar.gz & cd nrpe-2.13 &&. /configure -- enable-ssl -- with-ssl-lib & make all & make install-plugin && Make install-daemon & make install-daemon-config chown-R nagios: nagios/usr/local/nagios/cd ..; cp nrpe. cfg/usr/local/nagios/etc/nrpe. cfg/usr/local/nagios/bin/nrpe-c/usr/local/nagios/etc/nrpe. cfg-d ### Add auto start grep "nrpe"/etc/rc. local if [$? -Ne 0]; then echo "/usr/local/nagios/bin/nrpe-c/usr/local/nagios/etc/nrpe. cfg-d ">/etc/rc. local else echo "nrpe is exist" fi save it!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.