MirrorNest
← Todas las guías

Nagios Core

Nagios Core is the original open-source host and service monitoring engine, still distributed and officially documented as a source build rather than a packaged binary.

Sistema: Ubuntu / Debian Linux (built from source)MonitoringSitio oficial ↗Documentación oficial ↗
Esta guía se elaboró a partir de la documentación oficial de Nagios Core, enlazada arriba — verifica siempre ahí los nombres exactos de paquetes/versiones antes de ejecutar estos comandos en un servidor de producción, ya que las versiones de la distribución y del proyecto cambian con el tiempo.
  1. 1Install build prerequisites

    sudo apt-get update
    sudo apt-get install -y autoconf gcc libc6 make wget unzip apache2 php libapache2-mod-php libgd-dev ufw
    sudo apt-get install -y openssl libssl-dev
  2. 2Download and extract the latest Nagios Core release

    cd /tmp
    wget -O nagioscore.tar.gz $(wget -q -O - https://api.github.com/repos/NagiosEnterprises/nagioscore/releases/latest | grep '"browser_download_url":' | grep -o 'https://[^"]*')
    tar xzf nagioscore.tar.gz
  3. 3Compile Nagios Core

    sudo ./configure --with-httpd-conf=/etc/apache2/sites-enabled
    sudo make all
  4. 4Create the nagios user/group and install

    sudo make install-groups-users
    sudo usermod -a -G nagios www-data
    sudo make install
    sudo make install-daemoninit
    sudo make install-commandmode
    sudo make install-config
  5. 5Configure Apache and start services

    sudo make install-webconf
    sudo a2enmod rewrite
    sudo a2enmod cgi
    sudo systemctl restart apache2.service
    sudo systemctl start nagios.service

    This installs Nagios Core only — you still need to add the Nagios Plugins separately to get working check commands.