January 7, 2012

Installing Nagios on Ubuntu Server 11.10 then Monitoring Windows and Exchange Servers–Part 1–Configuring Ubuntu for the Installation of Nagios Core…

[ NOTE: ] This part has been updated to reflect some suggestions from readers of the site. Sections that have changed are:
Installing Nagios Core – added the sed commands before the “Make” process, this fixes an issue with the Make file which prevents the Nagios home page from being displayed, as well as some issues with the RSS feed – many thanks to Michael for pointing this out, and Simon Krenger for the actual fix.

I have also changed the Verifying Nagios Permissions section to reflect Michael’s suggestions – this fixes an issue when trying to schedule a service recheck which is related to permissions on the “nagios.cmd” file.

I have also removed the suggestion for an FTP server within the configuration – in essence you should be using SSH transfers via FileZilla.

Every now and then I like to ramble off and do something with a technology that I would not normally blog about, which also I am by no means an expert in – as it is a learning experience and can be fun!.

Recently I have been looking at monitoring solutions mainly in the context of a new role that I have been appointed to, but also because I have not focussed on any real form of monitoring throughout the history of this site and I thought that it would be good to share some of my experiences.

I have been looking at SCOM (and I will get around to posting a little tip that I discovered recently during the installation of Operations Manager) as well as a few other products (some good, some bad). However what I would like to focus my next few posts upon is Nagios Core.

For those whom don’t know; Nagios Core is a popular monitoring system based around Linux and PHP which in its “Core Edition” is available for free. With Nagios you can monitor a large number of facets of your network (including but not limited to Servers, Switches, Routers, Firewalls) and their respective services. You can also do some basic (in the Core release) business intelligence and performance / capacity management functions.

There is a huge community of plug-ins, skins and alternative interfaces for Nagios which allow for some pretty impressive expansion of the product and pretty much has everything for your monitoring needs.

Before I get into the meat of the article I should point out that I am not a Linux or Nagios expert (more a dabbler to be honest) – but over the years I have played with Ubuntu in the context of a reverse proxy for OWA and looked at Nagios as a monitoring tool a few times ~ but never really have used them in anger, therefore with that considered there are probably some processes that I will describe in this series that could be done better or more efficiently.

It is probably also worth pointing out, that there are a number of articles on the Internet which explain how to install Nagios core, but there are not many (or none that I could find) that give you an end-to-end scenario of Server installation to Server client and Exchange monitoring – so I thought that I would put one together.

As mentioned I have decided to use Nagios on Ubuntu (as it is the Linux Distro that I am the most familiar with), but I will not be explaining the actual Ubuntu install. What I will say is that I have installed Ubuntu Server into my VMWare workstation environment using the “Easy Setup” function – which automated the entire process, and all I really needed to do was create a new Virtual Machine and point the Ubuntu ISO at it.

Prerequisite Steps

Updating you Ubuntu Installation to the latest version

NOTE: The following steps all assume that you have a working, vanilla version of Ubuntu Server in your environment, if you would like to know how you can set install Ubuntu 11.10 within VMWare Workstation 8 – please see my video overview located here

From the Ubuntu Console type in the following commands (every command should then be followed by pressing <Enter>):

sudo apt-get update

Which will give you some output similar to the following (only there will be much more of it):

Ign http://security.ubuntu.com oneiric-security InRelease
Ign http://us.archive.ubuntu.com oneiric InRelease
Ign http://us.archive.ubuntu.com oneiric-updates InRelease
Ign http://us.archive.ubuntu.com oneiric-backports InRelease
Hit http://security.ubuntu.com oneiric-security Release.gpg
Hit http://security.ubuntu.com oneiric-security Release

Then type the following command;

sudo apt-get dist-upgrade

This will then begin the process of updating your Ubuntu Server components to the latest versions.

Installing OpenSSH

Whereas you do not need to install OpenSSH on your Ubuntu server, it is a very useful tool to have in place later on when you are administering the system and making modifications to various configuration files.

OpenSSH provides an encrypted remote administration environment for telnet and FTP applications (like PuTTY and Filezilla ~ more on these later).

Whereas you can administer your server from the console (or if like me you are working in a virtual environment the VMWare tools) it is far easier to install OpenSSH so you can perform tasks on your local Windows machine (I can already hear many Linux aficionados scoffing at the prospect Smile).

In order to install OpenSSH onto your Ubuntu box use following command on the console:

sudo apt-get install openssh-server

Configuring your Ubuntu Server with a Static IP address and configuring DNS

Naturally your Nagios monitoring server will need a static IP address, rather than one that is assigned from DHCP – therefore the following steps can be used to assign a static IP.

From the Ubuntu console type in the following command:

sudo nano /etc/network/interfaces

This will open up a console based text editor with the interfaces IP configuration (some people may prefer to use VI – but I have to admit I am a wimp and cannot get on with it!).

You will initially be presented something that looks like the following configuration:

auto eth0
iface eth0 inet dhcp

You will need to change the above to reflect the settings within your environment – for example mine looks like this:

auto eth0
iface eth0 inet static

When you have finished editing the file in Nano press the CTRL-O key and then <Enter> to save the file, and then press CTRL-X to exit and return to the console.

You should then configure the DNS Servers for your environment – from the console type in the following command:

sudo nano /etc/resolv.conf

This command will present you with a file that looks like the following:

domain telnetport25.com
search telnetport25.com

You should change all of the values within the configuration file to reflect those within your own environment, when done you will need to press CTRL-O and then <ENTER> and then CTRL-X to exit.

Now that you have configured both a static IP address and your nameserver configurations you will need to restart the networking Daemons for the settings to take effect. This is done by entering in the following command to the console:

sudo /etc/init.d/networking restart

Setting up PuTTy to administer your server

You are now in a position to administer the Ubuntu server with a remote tool such as PuTTy. I say PuTTy as it is still one of the most versatile Terminal tools on the market that is also free.

You can download PuTTy from the following location: http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html

PuTTY is very easy to use – after you have downloaded it – double click on the executable and from the Session screen provide the IP address of your server and ensure that the SSH radio button is selected – see below:


When you are done click on the “Open” button – you might be presented with a Certificate Error screen. This is generated because the OpenSSH server will have generated a self signed SSL certificate which naturally will not be trusted by the local PuTTY client. You will need to accept and trust the certificate.

When you have done that you will be presented with a Terminal window that looks like the following:


You can now remotely administer your server from PuTTY.

Installing a Compiler on your Server

Nagios and its associated components is supplied in a pre-compiled form which is compressed and tar-balled (tag.gz) therefore before you can install it you will need to compile it using a compiler. Ubuntu server does not come with a built in compiler, but there are a number in the Linux community which are free to download and use.

For the purposes of this article we will be using “Build-Essential” which can be installed onto your server using the following command line from your PuTTY session:

sudo apt-get install build-essential

Upon executing this command you will be asked to confirm the installation – ensure that you select “Y

Installing the GD Libraries

The Ubuntu (or Debian) GD libraries are in essence binaries that allow for applications to dynamically draw images. These are most likely used by Nagios’ reporting tools.

To install the GD libraries type in the following command:

sudo apt-get install libgd2-xpm-dev

Installing Apache and PHP 5

Apache should really need no introduction with it still being one of the most popular web server platforms on the planet. Apache is naturally required to support the web interface of Nagios, and PHP5 is the platform language which does all of the cool stuff in the user front end.

To install Apache enter in the following command into the PuTTY terminal window:

sudo apt-get install apache2

When Apache has installed enter in the following commands to install PHP5:

sudo apt-get install php5-common php5 libapache2-mod-php5

Installing Nagios Core

Creating the Nagios service user and group for commands

Nagios needs a service user and a group which has the relevant permissions to run commands within the monitoring system. The need to be created before you being the fill Nagios install.

In order to create them type in the following commands into your Terminal window:

sudo useradd -m nagios

sudo passwd nagios – you will be prompted for a password for the Nagios Service user here

sudo groupadd nagcmd

sudo usermod -a -G nagcmd nagios

sudo usermod -a -G nagcmd www-data

Download the Nagios Core and Plug in files

We are now at the stage where we can download the Nagios Core and Plugins source to your Server.

Within the Terminal window type in the following commands:

sudo –s

mkdir downloads

cd downloads

wget http://prdownloads.sourceforge.net/sourceforge/nagios/nagios-3.3.1.tar.gz (this is the latest stable release)

wget http://prdownloads.sourceforge.net/sourceforge/nagiosplug/nagios-plugins-1.4.15.tar.gz

tar –zxvf nagios-3.3.1.tar.gz

tar –zxvf nagios-plugins-1.4.15.tar.gz

Installing Nagios Core

Now that you have downloaded the relevant files to your server we can now begin the installation process, from the Terminal Windows type in the following commands (please ensure that you are in the “downloads” folder that you created in the previous step):

cd nagios ./configure --with-command-group=nagcmd

sed -i 's:for file in includes/rss/\*;:for file in includes/rss/\*.\*;:g' ./html/Makefile

sed -i 's:for file in includes/rss/extlib/\*;:for file in includes/rss/extlib/\*.\*;:g' ./html/Makefile make all make install make install-init make install-config make install-commandmode make install-webconf

We will now create the administration user for the Nagios Core System (this is the account that will be used to log into the web interface)

mkdir /usr/local/nagios/etc

htpasswd –c /usr/local/nagios/etc/htpasswd.users nagiosadmin

You will then be prompted for a password for the admin user.

Installing the Nagios plugins

The Nagios plugins provide around 50 pre-configured monitoring functions and services, without them your Nagios installation is not going to do very much so it is important that they are compiled and integrated into the environment.

In order to install them from the terminal window, type in the following commands:

Navigate to the downloads folder (if you have been following the sequence this could be cd .. and then cd nagios-plugins-1.4.15).

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


make all

make install

Creating a Symbolic Link for the Nagios Service

We now have an almost functional Nagios system, however before we can start the system up, we need to create a symbolic link to the Nagios service so that it can be started with the O/S automatically.

In order to do this type the following command into the Terminal window:

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

Verify permissions and file system

During the configuration of the Nagios environments for this article I have encountered some small problems with file system permissions and a folder not being created by the installation process. Therefore I have added in this step which cleans up the permissions on the Nagios folders and ensures the correct directories are in place.

From the terminal window type in the following commands

chown nagios.nagcmd /usr/local/nagios/var/rw


chmod g+rwx /usr/local/nagios/var/rw


chmod g+s /usr/local/nagios/var/rw


/etc/init.d/nagios restart

Verifying the installation

Just before we start the Nagios server up, as a penultimate step we should now verify the configuration – this is done by executing the following command from the Terminal window:

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

Which should result in the following output:

Nagios Core 3.3.1
Copyright (c) 2009-2011 Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 07-25-2011
License: GPL

Website: http://www.nagios.org
Reading configuration data...
   Read main config file okay...
Processing object config file '/usr/local/nagios/etc/objects/commands.cfg'...
Processing object config file '/usr/local/nagios/etc/objects/contacts.cfg'...
Processing object config file '/usr/local/nagios/etc/objects/timeperiods.cfg'...
Processing object config file '/usr/local/nagios/etc/objects/templates.cfg'...
Processing object config file '/usr/local/nagios/etc/objects/localhost.cfg'...
   Read object config files okay...

Running pre-flight check on configuration data...

Checking services...
    Checked 8 services.
Checking hosts...
    Checked 1 hosts.
Checking host groups...
    Checked 1 host groups.
Checking service groups...
    Checked 0 service groups.
Checking contacts...
    Checked 1 contacts.
Checking contact groups...
    Checked 1 contact groups.
Checking service escalations...
    Checked 0 service escalations.
Checking service dependencies...
    Checked 0 service dependencies.
Checking host escalations...
    Checked 0 host escalations.
Checking host dependencies...
    Checked 0 host dependencies.
Checking commands...
    Checked 24 commands.
Checking time periods...
    Checked 5 time periods.
Checking for circular paths between hosts...
Checking for circular host and service dependencies...
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...

Total Warnings: 0
Total Errors:   0

Things look okay - No serious problems were detected during the pre-flight check

Starting up Nagios and Accessing the Management Site

We can now start Nagios Core – therefore from the Terminal Window type in the following command:

/etc/init.d/nagios start

When the service has completed starting up – you can open a Web Browser to you the Nagios Core installation via:



In the next part

In the next part of this series I will go through how you can configure some basic monitoring of some Windows Servers within your infrastructure.

Monitoring 44 Replies to “Installing Nagios on Ubuntu Server 11.10 then Monitoring Windows and Exchange Servers–Part 1–Configuring Ubuntu for the Installation of Nagios Core…”
Andy Grogan
Andy Grogan


44 thoughts on “Installing Nagios on Ubuntu Server 11.10 then Monitoring Windows and Exchange Servers–Part 1–Configuring Ubuntu for the Installation of Nagios Core…

    Author’s gravatar

    Would be looking forward for the upcoming parts…

    I’ve been the knowing(in person & collegues) about this tool for monitoring(especially exchange as am concerned) & also good on other products too…!

    Nicely mentioned the steps to start with 🙂

    Author’s gravatar

    Brilliant How-To!! I am a MS user who also loves playing around with Ubuntu. This is the best How-to i have found on the web, thank you.

    Cant wait for the next part!!

    Author’s gravatar

    Hi Andy

    I have followed your steps to the T, but when I point my browser to the server, it asks for my username and password but then gives me the following error:

    Internal Server Error

    The server encountered an internal error or misconfiguration and was unable to complete your request.

    Please contact the server administrator, [email protected] and inform them of the time the error occurred, and anything you might have done that may have caused the error.

    More information about this error may be available in the server error log.
    Apache/2.2.20 (Ubuntu) Server at Port 80

    Any idea what could be wrong?

    Kind Regards

    Author’s gravatar

    Hi Andy, i found the problem. Above where you set the administration user you have a comma where it should be a fullstop:

    htpasswd –c /usr/local/nagios/etc/htpasswd,users nagiosadmin

      Author’s gravatar

      Nice catch Bradley! – I have corrected the typo.

    Author’s gravatar

    Hi Andy

    After doing this install, i was getting a error under the status information stating – Return code of 127 is out of bounds – plugin may be missing.

    This is because the plugins need to be installed, instead of make all, you need to make install.

    Kind Regards

      Author’s gravatar

      Thanks once again Bradley – I have corrected the missing line (I still think that you need the make all) – I have also given it another proof read against my install notes and I am now pretty sure that nothing it missing. Cheers.

    Author’s gravatar

    I love the post, but I’ve followed the directions and I’ve even done it several times now… I keep getting 500 Internal Server Error. Any thoughts or ideas on where I may have gone wrong? I even read ahead through the comments and made corrections to my own notes based on what others of written here.

    Any help would be greatly appreciated!


        Author’s gravatar

        Yeah I can hit that no problem.

      Author’s gravatar

      Andy helped me out with this. The solution was to run the following again:

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

      /etc/init.d/apache2 restart
      /etc/init.d/nagios restart

      After that I was able to get in and use Nagios. Thanks a bunch Andy!

    Author’s gravatar

    when following this guide I have sucessfully managed to get nagios working but the main.php is blank. I can see the side bar on the left and all the .cgi links on the left work ok. but where you would usually get the nagios core and version etc.. this doesnt work its blank.

    any suggestions?


      Author’s gravatar

      Hiya Michael, from what I understand this is a bug in the current release of Nagios. I have had a look around (as I have the same issue) on the web and none of the solutions have worked – so I have just ignored it for now as it does not effect the functionality of the product.

        Author’s gravatar

        thank you for the prompt reply. glad this is a known bug and wasnt me missing a step or doing something wrong.

    Author’s gravatar


    I have just gone through this steps from a blank install of Ubuntu 11.11.

    When I hit I get the IT WORKS page. But when I go to I get the error.

    Not Found
    The requested URL /nagios was not found on this server.
    Apache/2.2.20 (Ubuntu) Server at Port

    I followed your guide to the letter and I am lost at what has caused it.

    Author’s gravatar

    Doing what Andy said above helped.

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

    /etc/init.d/apache2 restart
    /etc/init.d/nagios restart

    Author’s gravatar

    A couple of fixes that I have come across building nagios 3.3.1 on ubuntu 11.10 that might help users out.

    •Fix rss error in make (this appears to also fix the home page information page that is blank)
    When installing/building nagios after the command “./configure –with-command-group=nagcmd” run these:

    sed -i ‘s:for file in includes/rss/\*;:for file in includes/rss/\*.\*;:g’ ./html/Makefile
    sed -i ‘s:for file in includes/rss/extlib/\*;:for file in includes/rss/extlib/\*.\*;:g’ ./html/Makefile

    then continue with “make all”, “make install”, etc…..

    •Fix nagios.cmd permission error
    chown nagios.nagcmd /usr/local/nagios/var/rw
    chmod g+rwx /usr/local/nagios/var/rw
    chmod g+s /usr/local/nagios/var/rw
    /etc/init.d/nagios restart

    Thanks to Andy for such a detailed work instruction.

      Author’s gravatar

      I just wanted to say thank you to all of you whom have made comment and suggested alterations to the article. I have now updated the article to reflect them.
      I really appreciate the support and time that you have invested to make it a better piece of work.

    Author’s gravatar

    Just wanted to say thanks for the incredibly helpful + rare (in geek worlds anyway) how to article. Following your steps faithfully landed me with a working installation with no arcane error messages/issues.

    Kudos 🙂


      Author’s gravatar

      Chris, you are more than welcome – glad that it has helped! 🙂

    Author’s gravatar

    Guy this guide is awesome! thanks a lot bro!

    Author’s gravatar


    having trouble when trying to complie nagios code
    # make all
    makefile:52: *** missing separator. Stop.

    Your help would be much appreciated.

    Author’s gravatar

    I followed the above instructions to the “T” and even some of the fixes outlined in the comments but I still cannot get the nagios site. I can hit http://localhost default page that shows it works, but when I try to hit the http://localhost/nagios I get the 500 internal Server error. I looked in /var/www and do not see anything relating to nagios.

    I see the /etc/apache2/conf.d/nagios.conf file:
    # Last Modified: 11-26-2005
    # This file contains examples of entries that need
    # to be incorporated into your Apache web server
    # configuration file. Customize the paths, etc. as
    # needed to fit your system.

    ScriptAlias /nagios/cgi-bin “/usr/local/nagios/sbin”

    # SSLRequireSSL
    Options ExecCGI
    AllowOverride None
    Order allow,deny
    Allow from all
    # Order deny,allow
    # Deny from all
    # Allow from
    AuthName “Nagios Access”
    AuthType Basic
    AuthUserFile /usr/local/nagios/etc/htpasswd.users
    Require valid-user

    Alias /nagios “/usr/local/nagios/share”

    # SSLRequireSSL
    Options None
    AllowOverride None
    Order allow,deny
    Allow from all
    # Order deny,allow
    # Deny from all
    # Allow from
    AuthName “Nagios Access”
    AuthType Basic
    AuthUserFile /usr/local/nagios/etc/htpasswd.users
    Require valid-user

    yet when I retstart apache and nagios i still donot get the nagios website.

    What am I missing?


      Author’s gravatar

      I am also getting the same error. Did you able to fix the problem?

    Author’s gravatar

    Great tutorial! I searched a while online to find a recent tutorial and finally found this, I appreciate the details and step by step.

    I have just installed 12.04 in VBox and did this. The only reccomendation (from my slightly Linux-newbie standpoint) would be to log in as root from the beginning (sudo -i) otherwise all your makes and other things will not work, and you will have to sudo each, else logging in at that point will change your directory.

    Also, maybe I’m blind, but I don’t see any obvious links to the other parts anywhere.

    Author’s gravatar

    To follow up to my previous comment, you actually do log in as root (sudo -s).

    My issue was that I was originally copying and pasting your commands, however the dashes on this website are not recognised by the terminal and that’s where I ran into issues, I never logged into root at that point.

    Author’s gravatar

    Thank you for this! I followed everything except I used Ubuntu 12.04 LTS and Nagios 3.4. Some where I needed to restart apache because nagios wasn’t coming up.

    Author’s gravatar

    Thanks, this is the only manual that is clear. It works very well even on ubuntu 12.04 and nagios 3.4.1!

    Like Kevin, only a apache restart and voila!


    Author’s gravatar

    This guide worked great for me on 12.04 Desktop in VMware with Nagios 3.4.1. I’m trying to get the latest plugins going now but am getting the following error when running make:

    make[2]: *** [check_http.o] Error 1
    make[2]: Leaving directory `/downloads/nagios-plugins-1.4.16/plugins’
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/downloads/nagios-plugins-1.4.16′
    make: *** [all] Error 2

    Is it possible that the ./configure command needs to be –with-nagios-group=nagioscmd like in the first install?

    Author’s gravatar

    Excellent guide.

    Really dug me out of a hole this morning. Thank you.

    Author’s gravatar

    This guide is gooood!!I followed it all through and for the first time in two weeks i’m excited about nagios.
    Now i want to download the plugin check_iftraffic.pl and use it on my nagios but I dont seem to get that right.
    Any help?

    Author’s gravatar

    Excellent !!! The only thing I ran into on Ubuntu 12.04 Server was an error about ssl_version undeclared. I installed libssl-dev and reran the configure/make portions. At the very end I also had to restart apache2 before the website was reachable. All minor. The instructions were spot on.

    Author’s gravatar

    To Ryan:

    apt-get install libssl-dev

    Hope this works for you, let me know if not.

      Author’s gravatar

      I had the same issue as Ryan (on Ubuntu 12.04 x64 running in a Xen virtual), and your solution of installing libssl-dev worked!

      Out of all the googling that I did you were the only one that I found that suggested to install libssl-dev. I would not have guessed that as the errors and other support was quite vague…


    Author’s gravatar

    gracias por eseta enorme gran ayudaaaaaaaaaaaaaaaa increible !

    Author’s gravatar

    Hi I want to install nagios in my Organization. Can u please assist me even monitoring tools also in Linux (Ubuntu OS).

    Appreciated for your prompt reply


    Author’s gravatar

    Thanks for this tutorial. I was also getting the ‘Return code of 127 is out of bounds – plugin may be missing’ error using the 1.4.16 plugin package. I downloaded and installed the 1.4.15 package and it fixed the issue. Hopefully this helps if anybody else runs into the same problem.

    Author’s gravatar

    Great post, thank you!
    Two notes —
    1 – as others have noticed, an apache restart is needed after nagios core is installed so that apache will read the newly added nagios.conf file. this will clear up the 404 on first access of /nagios website
    2 – as of this note, the latest version of plugins (1.4.16) fails the make unless ssldev is installed. before running config,
    apt-get install libssl-dev
    will do the trick. i’m sure the nagios plugins team will fix shortly

    Author’s gravatar

    Awesome tutorial for us Linux idiots!

    I just went through step-by-step. Now, when I try to log into the WebGUI, it tells me “This server could not verify that you are authorized to access the document requested. Either you supplied the wrong credentials (e.g., bad password), or your browser doesn’t understand how to supply the credentials required.”

    I know for sure I am using the correct password. Any help is GREATLY appreciated!

    Author’s gravatar


    Nevermind…like I said…i’m an idiot 🙂

    Author’s gravatar

    When through the above step by step, got stuck at sudo apt-get install libgd2-xpm-dev had to revert to libgdchart-gd2-xpm (im guessing at the time of me doing this the package wasn’t available or was changed). and also needed to restart the apache2 service at the end as the browser couldn’t see it. But I’m “up and running” onto step 2 now.


    Author’s gravatar

    Tried this against Ubuntu 13.10 server

    I had to edit the Makefile for nagios in order to get “make install-webconf” to work. Changing




    Also in order to get the CGIs to execute instead of Download (when clicking links on the main nagios landing page), I had to do the following

    sudo -s
    cd /etc/apache2/mods-enabled
    ln -s ../mods-available/cgi.load cgi.load
    service apache2 restart


    Author’s gravatar

    i have a project in nagios i installed nagios-3.5.0 on ubuntu 13.10 but when i tried the commande of make for the nagios-plugins-1.4.16 this probleme appere
    make all-recursive
    make[1]: Entering directory `/home/ubuntu/Downloads/nagios-plugins-1.4.16′
    Making all in gl
    make[2]: Entering directory `/home/ubuntu/Downloads/nagios-plugins-1.4.16/gl’
    rm -f configmake.h-t && \
    echo ‘#define PREFIX “/usr/local/nagios”‘; \
    echo ‘#define EXEC_PREFIX “/usr/local/nagios”‘; \
    echo ‘#define BINDIR “/usr/local/nagios/bin”‘; \
    echo ‘#define SBINDIR “/usr/local/nagios/sbin”‘; \
    echo ‘#define LIBEXECDIR “/usr/local/nagios/libexec”‘; \
    echo ‘#define DATAROOTDIR “/usr/local/nagios/share”‘; \
    echo ‘#define DATADIR “/usr/local/nagios/share”‘; \
    echo ‘#define SYSCONFDIR “/usr/local/nagios/etc”‘; \
    echo ‘#define SHAREDSTATEDIR “/usr/local/nagios/com”‘; \
    echo ‘#define LOCALSTATEDIR “/usr/local/nagios/var”‘; \
    echo ‘#define INCLUDEDIR “/usr/local/nagios/include”‘; \
    echo ‘#define OLDINCLUDEDIR “/usr/include”‘; \
    echo ‘#define DOCDIR “/usr/local/nagios/share/doc/nagios-plugins”‘; \
    echo ‘#define INFODIR “/usr/local/nagios/share/info”‘; \
    echo ‘#define HTMLDIR “/usr/local/nagios/share/doc/nagios-plugins”‘; \
    echo ‘#define DVIDIR “/usr/local/nagios/share/doc/nagios-plugins”‘; \
    echo ‘#define PDFDIR “/usr/local/nagios/share/doc/nagios-plugins”‘; \
    echo ‘#define PSDIR “/usr/local/nagios/share/doc/nagios-plugins”‘; \
    echo ‘#define LIBDIR “/usr/local/nagios/lib”‘; \
    echo ‘#define LISPDIR “”‘; \
    echo ‘#define LOCALEDIR “/usr/local/nagios/share/locale”‘; \
    echo ‘#define MANDIR “/usr/local/nagios/share/man”‘; \
    echo ‘#define MANEXT “”‘; \
    echo ‘#define PKGDATADIR “/usr/local/nagios/share/nagios-plugins”‘; \
    echo ‘#define PKGINCLUDEDIR “/usr/local/nagios/include/nagios-plugins”‘; \
    echo ‘#define PKGLIBDIR “/usr/local/nagios/lib/nagios-plugins”‘; \
    echo ‘#define PKGLIBEXECDIR “/usr/local/nagios/libexec/nagios-plugins”‘; \
    } | sed ‘/””/d’ > configmake.h-t && \
    if test -f configmake.h && cmp configmake.h-t configmake.h > /dev/null; then \
    rm -f configmake.h-t; \
    else \
    rm -f configmake.h; mv configmake.h-t configmake.h; \
    make all-recursive
    make[3]: Entering directory `/home/ubuntu/Downloads/nagios-plugins-1.4.16/gl’
    make[4]: Entering directory `/home/ubuntu/Downloads/nagios-plugins-1.4.16/gl’
    gcc -DHAVE_CONFIG_H -I. -I.. -I../intl -g -O2 -MT localcharset.o -MD -MP -MF .deps/localcharset.Tpo -c -o localcharset.o localcharset.c
    In file included from localcharset.c:26:0:
    ./stdio.h:456:1: error: ‘gets’ undeclared here (not in a function)
    _GL_WARN_ON_USE (gets, “gets is a security hole – use fgets instead”);
    make[4]: *** [localcharset.o] Error 1
    make[4]: Leaving directory `/home/ubuntu/Downloads/nagios-plugins-1.4.16/gl’
    make[3]: *** [all-recursive] Error 1
    make[3]: Leaving directory `/home/ubuntu/Downloads/nagios-plugins-1.4.16/gl’
    make[2]: *** [all] Error 2
    make[2]: Leaving directory `/home/ubuntu/Downloads/nagios-plugins-1.4.16/gl’
    make[1]: *** [all-recursive] Error 1
    make[1]: Leaving directory `/home/ubuntu/Downloads/nagios-plugins-1.4.16′
    make: *** [all] Error 2
    plzzzzzzzzzzz help me i have just 2 days to solve this probleme and if you can reply me in frensh plzzz

Leave a Reply to Bradley Marks Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: