DebianDebian Based

How To Install Icinga on Debian 12

Install Icinga on Debian 12

In this tutorial, we will show you how to install Icinga on Debian 12. Icinga is a powerful open-source monitoring system that allows users to check the availability of their network resources, notifies users of outages, and generates performance data for reporting. Scalable and extensible, Icinga can monitor large, complex environments across multiple locations.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo‘ to the commands to get root privileges. I will show you the step-by-step installation of Icinga monitoring on a Debian 12 (Bookworm).


  • A server running one of the following operating systems: Debian 12 (Bookworm).
  • It’s recommended that you use a fresh OS install to prevent any potential issues.
  • SSH access to the server (or just open Terminal if you’re on a desktop).
  • An active internet connection. You’ll need an internet connection to download the necessary packages and dependencies for Icinga.
  • A user account with sudo privileges to execute administrative commands.

Install Icinga on Debian 12 Bookworm

Step 1. Before embarking on the installation journey, it’s crucial to ensure your Debian system is up-to-date. This step not only enhances security but also ensures compatibility with the Icinga software. Begin by executing the following commands:

sudo apt update
sudo apt upgrade

Next, install the necessary packages that will facilitate the installation process:

sudo apt install apt-transport-https wget gnupg

Step 2. Installing LAMP on Debian.

Before installing Icinga, the LAMP server must be installed on your server. If you do not have a LAMP (Linux, Apache, MySQL, and PHP) stack installed, you can follow our guide here.

Step 3. Installing Icinga on Debian 12.

Install Icinga2, along with the Icinga2-ido-mysql module and monitoring plugins, using the following commands:

sudo apt install icinga2 icinga2-ido-mysql monitoring-plugins

After installation, ensure that the Icinga 2 service is enabled and running:

sudo systemctl enable icinga2
sudo systemctl start icinga2

Check the status to confirm it’s active:

sudo systemctl status icinga2

Step 4. Database Setup.

Secure your MySQL/MariaDB installation and create a dedicated database and user for Icinga:

sudo mysql_secure_installation
sudo mysql -u root -p
GRANT ALL PRIVILEGES ON icinga2.* TO 'icingauser'@'localhost' IDENTIFIED BY 'your-strong-password';

Next, enable the ido-mysql feature to allow Icinga to interact with the MySQL database:

sudo icinga2 feature enable ido-mysql
sudo systemctl restart icinga2

Then, generate a secret token with the following command:

icingacli setup token create

You should get the following output:

The newly generated setup token is: 888meyaa6ab5758

Step 5. Installing Icinga Web 2.

For those who prefer a web interface, Icinga Web 2 offers a convenient and user-friendly way to manage your monitoring setup:

apt install icingaweb2 icingacli

After installation, navigate to the web-based setup wizard to complete the configuration. This step involves connecting to your database and setting up the monitoring module, streamlining the process of bringing your Icinga Web 2 interface online.

Step 6. Configure Firewall.

Now we set up an Uncomplicated Firewall (UFW) with Apache to allow public access on default web ports for HTTP and HTTPS:

sudo ufw allow OpenSSH
sudo ufw allow 'Apache Full'
sudo ufw enable

Step 7. Accessing Icinga 2 Web UI.

Once successfully installed, open the web interface at http://your_server_ip/icingaweb2/setup to complete the setup wizard. You will be redirected to the following page:

Congratulations! You have successfully installed Icinga. Thanks for using this tutorial for installing the latest version of Icinga 2 monitoring on Debian 12 Bookworm. For additional help or useful information, we recommend you check the official Icinga website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!


r00t is a seasoned Linux system administrator with a wealth of experience in the field. Known for his contributions to, r00t has authored numerous tutorials and guides, helping users navigate the complexities of Linux systems. His expertise spans across various Linux distributions, including Ubuntu, CentOS, and Debian. r00t's work is characterized by his ability to simplify complex concepts, making Linux more accessible to users of all skill levels. His dedication to the Linux community and his commitment to sharing knowledge makes him a respected figure in the field.
Back to top button