LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Blogs > Kashif Aziz Awan
User Name
Password

Notices


Rate this Entry

Installing Nagios Core 3.5.0 on CentOS 6.4

Posted 03-26-2013 at 07:39 AM by kashifazizawan

Kashif Aziz Awan
March 26, 2013

Nagios Core
Latest Releases
Version Date Notes Type
3.5.0 2013-03-15 Latest stable release

Installing Nagios 3.5.0 On CentOS 6.4

Introduction

Nagios is a monitoring tool under GPL licence. This tool lets you monitor servers, network hardware (switches, routers, ...) and applications. A lot of plugins are available and its big community makes Nagios the biggest open source monitoring tool. This tutorial shows how to install Nagios 3.5.0 on CentOS 6.4.

Prerequisites
After installing your CentOS server, you have to disable selinux & install some packages to make nagios work.
To disable selinux, open the file: /etc/selinux/config
# vi /etc/selinux/config
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
SELINUX=permissive // change this value to disabled
# SELINUXTYPE= can take one of these two values:
# targeted - Targeted processes are protected,
# mls - Multi Level Security protection.
SELINUXTYPE=targeted
Now, download all packages you need:
# yum install gd gd-devel httpd php gcc glibc glibc-common


Nagios Installation
Create a directory:
# mkdir /root/nagios
Navigate to this directory:
# cd /root/nagios
Download nagios-core & plugin:
# wget http://prdownloads.sourceforge.net/s...s-3.5.0.tar.gz
# wget http://prdownloads.sourceforge.net/s...-1.4.16.tar.gz
Untar nagios core:
# tar xvzf nagios-3.5.0.tar.gz
Go to the nagios dir:
# cd nagios
Configure before make:
# ./configure
Make all necessary files for Nagios:
# make all
Installation:
# make install
# make install-init
# make install-commandmode
# make install-config
# make install-webconf
Create a password to log into the web interface:
# htpasswd -c /usr/local/nagios/etc/htpasswd.users nagiosadmin
Start the service and start it on boot:
# chkconfig nagios on
# service nagios start
Now, you have to install the plugins:
# cd ..
# tar xvzf nagios-plugins-1.4.15.tar.gz
# cd nagios-plugins-1.4.15
# ./configure
# make
# make install
Start the apache service and enable it on boot:
# service httpd start
# chkconfig httpd on
Now, connect to your nagios system:
http://Your-Nagios-IP/nagios and enter login : nagiosadmin & password you have chosen above.

And after the installation ?
After the installation you have to configure all your host & services in nagios configuration files.This step is performed in command line and is complicated, so I recommand to install tool like Centreon, that is a beautiful front-end to add you host & services.
Posted in Uncategorized
Views 4917 Comments 0
« Prev     Main     Next »
Total Comments 0

Comments

 

  



All times are GMT -5. The time now is 01:36 AM.

Main Menu
Advertisement
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration