Thruk is an open-source multibackend monitoring web interface that allows you to monitor several backends like Nagios, Icinga, Check_MK, and more. In this tutorial, we will guide you through the process of installing Thruk on Debian latest.
Before we proceed with installing Thruk on Debian, you need to have the following prerequisites:
The first step is to install some necessary dependencies required for Thruk to work correctly. To install them, log in to your Debian system, open a terminal, and execute the following command:
$ sudo apt-get update
$ sudo apt-get install apache2 libapache2-mod-php php php-mbstring php-zip \
php-net-socket php-net-smtp php-curl php-xml php-json \
git unzip -y
This command will update your system packages and install all the required dependencies.
Thruk is not running Nagios itself. It's just an interface to it. Therefore, we need to install Nagios first. To install Nagios, follow these steps:
$ sudo apt-get update
$ sudo apt-get install build-essential libgd-dev openssl libssl-dev unzip -y
$ sudo useradd nagios
$ sudo groupadd nagcmd
$ sudo usermod -a -G nagios nagcmd
$ sudo usermod -a -G nagcmd www-data
$ cd /usr/src
$ wget -O nagios.tar.gz https://github.com/NagiosEnterprises/nagioscore/archive/nagios-4.4.6.tar.gz
$ tar xzf nagios.tar.gz
$ cd nagioscore-nagios-4.4.6/
$ sudo ./configure --with-httpd-conf=/etc/apache2/sites-enabled
$ sudo make -j4 all
$ sudo make install
$ sudo make install-init
$ sudo make install-commandmode
$ sudo make install-config
$ sudo make install-webconf
$ sudo htpasswd -c /usr/local/nagios/etc/htpasswd.users nagiosadmin
$ sudo systemctl restart nagios
Finally, check whether the Nagios web interface is running correctly by browsing the URL http://your-server-ip/nagios.
Now that we have installed and configured Nagios, we can proceed with installing Thruk on Debian. To install Thruk, follow these steps:
$ cd /usr/src
$ sudo git clone https://github.com/thruk/thruk.git
$ cd thruk
$ sudo make
$ sudo make install
$ sudo a2enmod perl
$ sudo systemctl restart apache2
$ sudo cp /usr/local/thruk/etc/thruk_local.conf.example /usr/local/thruk/etc/thruk_local.conf
Open the file /usr/local/thruk/etc/thruk_local.conf
with your favorite file editor and customize it to suit your environment.
Open the URL http://your-server-ip/thruk on your web browser to access the Thruk web interface.
In this tutorial, you learned how to install Thruk on Debian latest. Thruk is a powerful monitoring web interface that makes it easy to monitor several backends like Nagios, Icinga, or Check_MK.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!