nagios core install | nagios core | nagios plugins | nagios ssh
tested on debian12
that libgd-dev package sometimes provoques conflicts so let’s install it first
apt install libgd-dev libjpeg-dev libpng-dev # libpnglite-dev
we are trying NOT to install apache (got NGINX already)
#apt install apache2 php php-gd php-imap php-curl libapache2-mod-php # php-mcrypt apt install libxml-libxml-perl libnet-snmp-perl libperl-dev libnumber-format-perl libconfig-inifiles-perl libdatetime-perl libnet-dns-perl
groupadd -g 517 nagios useradd -u 517 -g nagios --system -s /sbin/nologin -d /var/nagios nagios groupadd -g 518 nagios-cmd useradd -u 518 -g nagios-cmd --system -s /sbin/nologin -d /var/nagios nagios-cmd
there is a setgid in da place, we need either the same group, or enable that
usermod -aG nagios-cmd nagios
no need to change ownerships, let install-config handle it more precisely
mkdir /etc/nagios/ mkdir /var/nagios/
ver=4.4.13 wget https://github.com/NagiosEnterprises/nagioscore/archive/refs/tags/nagios-$ver.tar.gz tar xzf nagios-$ver.tar.gz cd nagioscore-nagios-$ver/ # otherwise goes to /usr/local/nagios/ ./configure --prefix=/usr/local \ --sysconfdir=/etc/nagios --localstatedir=/var/nagios \ --with-gd-lib --with-gd-inc \ --with-nagios-user=nagios --with-nagios-group=nagios \ --with-command-user=nagios-cmd --with-command-group=nagios-cmd \ --without-httpd-conf \ --with-mail=/usr/sbin/sendmail #--with-httpd-conf=/etc/apache2/sites-enabled \ # CHECK THERE WAS NO LARGE WARNING ABOUT GD echo $MAKEFLAGS make all make install make install-init make install-commandmode make install-config
check
/usr/local/nagios/bin/nagios -v
https://assets.nagios.com/downloads/nagioscore/docs/nagioscore/4/en/quickstart.html
https://support.nagios.com/kb/article/nagios-core-installing-nagios-core-from-source-96.html#Debian
https://www.howtoforge.com/tutorial/how-to-install-nagios-on-ubuntu-2004/
https://linuxhint.com/install_nagios_ubuntu/
https://linuxize.com/post/how-to-install-nagios-on-ubuntu-20-04/ ==> htdigest
https://www.centlinux.com/2021/04/install-nagios-core-on-ubuntu-lts.html
https://kifarunix.com/install-and-setup-nagios-core-on-ubuntu-20-04/
https://www.scaleway.com/en/docs/tutorials/configure-nagios-monitoring/
https://computingforgeeks.com/install-php-mcrypt-extension-on-ubuntu/
https://askubuntu.com/questions/1031921/php-mcrypt-package-missing-in-ubuntu-server-18-04-lts