+ All Categories
Home > Documents > How to Install Nagios 4.1 in Ubuntu 15

How to Install Nagios 4.1 in Ubuntu 15

Date post: 17-Feb-2018
Category:
Upload: bnlbnl
View: 217 times
Download: 0 times
Share this document with a friend
31
7/23/2019 How to Install Nagios 4.1 in Ubuntu 15 http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 1/31 11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 1/31 100 NEW ARTICLES About Nagios  SK How To Install Nagios 4.1 In Ubuntu 15.04  AUGUST 4, 2015
Transcript
Page 1: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 1/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 1/31

100NEW ARTICLES

About Nagios

SK

How To Install Nagios 4.1 In Ubuntu 15.04

AUGUST 4, 2015

Page 2: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 2/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 2/31

Nagios is an enterprise class, open source software that can be used for

network and infrastructure monitoring. Using Nagios, we can monitor

servers, switches, applications and services etc. It alerts the System

Administrator when something goes wrong and also alerts back when the

issues have been rectified.

Features

Using Nagios, you can:

Monitor your entire IT infrastructure.Identify problems before they occur.Know immediately when problems arise.

Share availability data with stakeholders.Detect security breaches.Plan and budget for IT upgrades.Reduce downtime and business losses.

Scenario

For the purpose of this tutorial, I will be using the following two systems.

Nagios server:

Operating system : Ubuntu 15.04 ServerIP Address : 192.168.1.102/24

Nagios client:

Operating System : Ubuntu 14.04 ServerIP Address : 192.168.1.103/24Hostname : server.unixmen.local

-40% -41%

Page 3: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 3/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 3/31

Prerequisites

Make sure your server have installed with fully working LAMP stack. If not, follow the below link to install LAMP server.

Install LAMP Server On Ubuntu

And, install the following prerequisites too:

sudo apt-get install build-essential libgd2-xpm-dev apache2-utils unzip

Create Nagios User And Group

Create a new nagios user account:

sudo useradd -m nagios

sudo passwd nagios

Create a new nagcmd group for allowing external commands to be submitted through the web interface. Add both the nagios

user and the apache user to the group.

sudo groupadd nagcmd

Page 4: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 4/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 4/31

sudo usermod -a -G nagcmd nagios

sudo usermod -a -G nagcmd www-data

Download Nagios And Plugins

Go to the nagios download page, and get the latest version. As of writing this, the latest version was 4.1.0 releasecandidate 2.

wget https://assets.nagios.com/downloads/nagioscore/releases/nagios-4.1.0rc2.tar.gz

And, download nagios plugins too. Nagios plugins allow you to monitor hosts, devices, services, protocols, andapplications with Nagios

wget http://nagios-plugins.org/download/nagios-plugins-2.0.3.tar.gz

Install Nagios And Plugins

Page 5: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 5/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 5/31

Install nagios:

Go to the folder where you’ve downloaded nagios, and extract it using command:

tar xzf nagios-4.1.0rc2.tar.gz

Change to the nagios directory:

cd nagios-4.1.0rc2/

Run the following commands one by one from the Terminal to compile and install nagios.

sudo ./configure --with-command-group=nagcmd

sudo make all

sudo make install

Page 6: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 6/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 6/31

sudo make install-init

sudo make install-config

sudo make install-commandmode

Install Nagios Web interface:

Enter the following commands to compile and install nagios web interface.

sudo make install-webconf

You may get the following error:

/usr/bin/install -c -m 644 sample-config/httpd.conf /etc/httpd/conf.d/nagios.conf

/usr/bin/install: cannot create regular file ‘/etc/httpd/conf.d/nagios.conf’: No such file or directory

Makefile:296: recipe for target 'install-webconf' failed

make: *** [install-webconf] Error 1

The above error message describes that nagios is trying to create the nagios.conf file inside the /etc/httpd.conf/directory.

Page 7: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 7/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 7/31

But, in Ubuntu systems the nagios.conf file should be placed in /etc/apache2/sites-enabled/directory.

So, run the following command instead of using sudo make install-webconf .

sudo /usr/bin/install -c -m 644 sample-config/httpd.conf /etc/apache2/sites-enabled/nagios.conf

Check if nagios.conf is placed in /etc/apache2/sites-enabled directory.

sudo ls -l /etc/apache2/sites-enabled/

Sample output:

total 4

lrwxrwxrwx 1 root root 35 Aug 4 15:54 000-default.conf -> ../sites-available/000-default.conf

-rw-r--r-- 1 root root 982 Aug 4 16:19 nagios.conf

Create a nagiosadmin account for logging into the Nagios web interface. Remember the password you assign to this

account. You’ll need it while logging in to nagios web interface..

sudo htpasswd -c /usr/local/nagios/etc/htpasswd.users nagiosadmin

Page 8: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 8/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 8/31

Restart Apache to make the new settings take effect.

In Ubuntu 15.04:

sudo systemctl restart apache2

In Ubuntu 14.10 and previous versions:

sudo service apache2 restart

Install Nagios plugins:

Go to the directory where you downloaded the nagios plugins, and extract it.

tar xzf nagios-plugins-2.0.3.tar.gz

Change to the nagios plugins directory:

cd nagios-plugins-2.0.3/

Page 9: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 9/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 9/31

Run the following commands one by one to compile and install it.

sudo ./configure --with-nagios-user=nagios --with-nagios-group=nagios

sudo make

sudo make install

Wait, We are not finished yet.

Configure Nagios

Nagios sample configuration files will be found in the /usr/local/nagios/etc directory. These sample files should work fine

for getting started with Nagios. However, if you want, you’ll need to put your actual email ID to receive alerts.

To do that, Edit the /usr/local/nagios/etc/objects/contacts.cfg config file with your favorite editor and change the

email address associated with the nagiosadmin contact definition to the address you’d like to use for receiving alerts.

sudo nano /usr/local/nagios/etc/objects/contacts.cfg

Page 10: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 10/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 10/31

Find the following line and enter the email id:

[...]

define contact

contact_name nagiosadmin ; Short name of user

use generic-contact ; Inherit default values from generic-

contact template (defined above)

alias Nagios Admin ; Full name of user

email [email protected] ; <<***** CHANGE THIS TO YOUR EMAIL ADDRESS

******

[...]

Save and close the file.

Then, Edit file /etc/apache2/sites-enabled/nagios.conf ,

sudo nano /etc/apache2/sites-enabled/nagios.conf

And edit the following lines if you want to access nagios administrative console from a particular IP series.

Here, I want to allow nagios administrative access from 192.168.1.0/24 series only.

[...]

## Comment the following lines ### Order allow,deny

Page 11: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 11/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 11/31

# Allow from all

## Uncomment and Change lines as shown below ##

Order deny,allow

Deny from all

Allow from 127.0.0.1 192.168.1.0/24

[...]

Enable Apache’s rewrite and cgi modules:

sudo a2enmod rewrite

sudo a2enmod cgi

Restart apache service.

sudo systemctl restart apache2

Or,

sudo service apache2 restart

Page 12: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 12/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 12/31

Check nagios,conf file for any syntax errors:

sudo /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg

If there are no errors, start nagios service and make it to start automatically on every boot.

sudo service nagios start

sudo ln -s /etc/init.d/nagios /etc/rcS.d/S99nagios

Note: In Ubuntu 15.04, you will see the following error message while starting nagios service.

Failed to start nagios.service: Unit nagios.service failed to load: No such file or directory.

Or

[....] Starting nagios (via systemctl): nagios.serviceFailed to start nagios.service: Unit

nagios.service failed to load: No such file or directory.

failed!

Page 13: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 13/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 13/31

To fix this error, copy /etc/init.d/skeleton to /etc/init.d/nagios using the following command:

sudo cp /etc/init.d/skeleton /etc/init.d/nagios

Edit file /etc/init.d/nagios:

sudo nano /etc/init.d/nagios

Add the following lines:

DESC="Nagios"

NAME=nagios

DAEMON=/usr/local/nagios/bin/$NAME

DAEMON_ARGS="-d /usr/local/nagios/etc/nagios.cfg"

PIDFILE=/usr/local/nagios/var/$NAME.lock

Save and close the file.

Finally you need to change the permissions of the file

sudo chmod +x /etc/init.d/nagios

Page 14: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 14/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 14/31

Now, you can start nagios service using command:

sudo /etc/init.d/nagios start

Access Nagios Web Interface

Open up your web browser and navigate to http://nagios-server-ip/nagios and enter the username as nagiosadmin and

its password which we created in the earlier steps.

Page 15: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 15/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 15/31

This is how Nagios administrative console looked:

Page 16: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 16/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 16/31

Click on the “Hosts” section in the left pane of the console. You will see there the no of hosts being monitored by Nagios

server. We haven’t added any hosts yet. So it simply monitors the localhost itself only.

Page 17: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 17/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 17/31

Click on the localhost to display more details:

Page 18: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 18/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 18/31

That’s it. We have successfully installed and configure Nagios core in our Ubuntu 15.04 server.

Add Monitoring targets to Nagios server

Now, let us add some clients to monitor by Nagios server.

To do that we have to install nrpe and nagios-plugins in our monitoring targets.

On CentOS/RHEL/Scientifc Linux clients:

Page 19: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 19/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 19/31

Add EPEL repository in your CentOS/RHEL/Scientific Linux 6.x or 7 clients to install nrpe package.

To install EPEL on CentOS 7, run the following command:

yum install epel-release

On CentOS 6.x systems, refer the following link.

Install EPEL Repository On CentOS 6.x

Install “nrpe” and “nagios-plugins” packages in client systems:

yum install nrpe nagios-plugins-all openssl

On Debian/Ubuntu clients:

sudo apt-get install nagios-nrpe-server nagios-plugins

Configure Monitoring targets

Edit /etc/nagios/nrpe.cfg file,

Page 20: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 20/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 20/31

sudo nano /etc/nagios/nrpe.cfg

Add your Nagios server ip address:

[...]

## Find the following line and add the Nagios server IP ##

allowed_hosts=127.0.0.1 192.168.1.102

[...]

Start nrpe service on CentOS clients:

CentOS 7:

systemctl start nrpe

chkconfig nrpe on

CentOS 6.x:

service nrpe start

Page 21: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 21/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 21/31

chkconfig nrpe on

For Debian/Ubuntu Clients, start nrpe service as shown below:

sudo /etc/init.d/nagios-nrpe-server restart

Now, go back to your Nagios server, and add the clients ( in the configuration file.

To do that, Edit “/usr/local/nagios/etc/nagios.cfg” file,

sudo nano /usr/local/nagios/etc/nagios.cfg

and uncomment the following lines.

## Find and uncomment the following line ##

cfg_dir=/usr/local/nagios/etc/servers

Create a directory called “servers” under “/usr/local/nagios/etc/”.

Page 22: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 22/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 22/31

sudo mkdir /usr/local/nagios/etc/servers

Create config file to the monitoring target (client):

sudo nano /usr/local/nagios/etc/servers/clients.cfg

Add the following lines:

define host

use linux-server

host_name server.unixmen.local

alias server

address 192.168.1.103

max_check_attempts 5

check_period 24x7

notification_interval 30

notification_period 24x7

Here, 192.168.1.103 is my nagios client IP address and server.unixmen.local is the client system’s hostname.

Finally, restart nagios service.

Page 23: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 23/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 23/31

sudo /etc/init.d/nagios restart

Or

sudo service nagios restart

Wait for few seconds, and refresh nagios admin console in the browser and navigate to “Hosts” section in the left pane. Now,

You will see the newly added client will be visible there. Click on the host to see if there is anything wrong or any alerts it has.

11/6/201 H T I ll N i 4 1 I Ub 1 04 | U i

Page 24: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 24/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 24/31

Click on the monitoring target (client system) to view the detailed output:

11/6/2015 H T I t ll N i 4 1 I Ub t 15 04 | U i

Page 25: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 25/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 25/31

Similarly, you can define more clients by creating a separate config files “/usr/local/nagios/etc/servers”directory for each

client.

Define services

We have just defined the monitoring host. Now, let us add some services of the monitoring host. For example, to monitor the

ssh service, add the following lines shown in bold in the“/usr/local/nagios/etc/servers/clients.cfg” file.

11/6/2015 How To Install Nagios 4 1 In Ubuntu 15 04 | Unixmen

Page 26: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 26/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 26/31

sudo nano /usr/local/nagios/etc/servers/clients.cfg

Add the following lines shown in bold:

define host

use linux-server

host_name server.unixmen.local

alias server

address 192.168.1.103

max_check_attempts 5

check_period 24x7

notification_interval 30notification_period 24x7

define service

use generic-service

host_name server.unixmen.local

service_description SSH

check_command check_ssh

notifications_enabled 0

Save and close the file. Restart Nagios.

sudo /etc/init.d/nagios restart

11/6/2015 How To Install Nagios 4 1 In Ubuntu 15 04 | Unixmen

Page 27: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 27/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 27/31

Or,

sudo service nagios restart

Wait for few seconds (90 seconds by default), and check for the added services (i.e ssh) in the nagios web interface. Navigate

to Services section on the left side bar, you’ll see the ssh service there.

11/6/2015 How To Install Nagios 4 1 In Ubuntu 15 04 | Unixmen

Page 28: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 28/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 28/31

To know more about object definitions such as Host definitions, service definitions, contact definitions, please visit here.

This page will explain you the description and format of all object definitions.

Additional Tip:

I would like to thank our Unixmen reader for this useful tip.

If you’re trying to use check_http with the -S flag (for https), this guide misses a big step.

11/6/2015 How To Install Nagios 4 1 In Ubuntu 15 04 | Unixmen

Page 29: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 29/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 29/31

FEATURED FREQUENTLY ASKED QUESTIONS LINUX MINT LINUX TUTORIALS OPENSOURCE SECURITY SOFTWARE

UBUNTU

POSTED IN:

TAGGED: NAGIOS NETWORK MONITORING TOOLS SERVER MONITORING TOOLS

Make sure you install openssl and libssl-dev first. And yes, even if your Nagios server is checking a remote client, you need

openssl and libssl-dev locally.

The when you get to configuring the Nagios plugins, add –with-openssl so you end up with:

./configure --with-nagios-user=nagios --with-nagios-group=nagios --with-openssl

That’s it. Cheers!

Further reading:

Check out the following official documents for how to go about monitoring other things.

Monitoring Windows machinesMonitoring Netware serversMonitoring routers/switchesMonitoring network printersMonitoring publicly available services (HTTP, FTP, SSH, etc.)

Reference links:

Nagios websiteNagios Documentation

11/6/2015 How To Install Nagios 4 1 In Ubuntu 15 04 | Unixmen

Page 30: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 30/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

http://www.unixmen.com/how-to-install-nagios-4-1-in-ubuntu-15-04/ 30/31

http://rautamiekka.org/ Jouni JärvinenHaving to install from source is bullshit.

Pingback: Monitorer sites mutualisés avec Nagios - Hervé Hennes – Blog()

Pingback: Instalacion Nagios CORE | Blog - Sistemas PCE()

Abinayan Emanu

Hello, I have did the same from the beginning and ended up with the following error:

root@ubuntu-64-nagios:~/nagios-4.1.1# ./configure –with-command-group=nagios–with-command-group=nagcmd – with-mail=/usr/bin/sendmail

checking for a BSD-compatible install… /usr/bin/install -c

checking build system type… x86_64-unknown-linux-gnu

checking host system type… x86_64-unknown-linux-gnu

SK

A Linux enthusiast, FOSS Supporter & Linux Consultant from Tamilnadu, India.

ABOUT THE AUTHOR

Previous storyHow To Combine Two Graphs On Cacti

Next storySetup Local Repository In Ubuntu 15.04

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

Page 31: How to Install Nagios 4.1 in Ubuntu 15

7/23/2019 How to Install Nagios 4.1 in Ubuntu 15

http://slidepdf.com/reader/full/how-to-install-nagios-41-in-ubuntu-15 31/31

11/6/2015 How To Install Nagios 4.1 In Ubuntu 15.04 | Unixmen

Linux Howtos And Tutorials By Unixmen.Com Is Licensed Under A Creative Commons Attribution-NonCommercial 4.0 International License.

checking for gcc… gcc

checking for C compiler default output file name…

configure: error: in `/root/nagios-4.1.1′:

configure: error: C compiler cannot create executables

See `config.log’ for more details.

Note: Updated / changed /reinstalled Gcc compiler but nothing works .

Thanks in Advancehttp://etem.github.io Etem BavarianThank you!http://projectrk.com.ph Richard Hanz Monfort Kalaw

Article is confusing, I thought you use 15.05 and 14.04. All I see are 15.05 server installation and CentOS, where is the14.04 side?https://www.youtube.com/watch?v=4OadeZieS4A Folding Chairs Chicago – Wood Collapsible chairs – A Terrific

RemedyIf you want to improve your know-how only keep visiting this web site and be updated with the newest news updateposted here.Thyago Siebratks !!

Andrew KaplanHello — I completed the installation process, and I log into the appropriate URL. However, after entering the usernameand password, a 500 Internal Serve Error message appears on-screen. What file(s) do I need to run in order to determinethe cause of the error? Thanks.


Recommended