How to Setup Icinga Web 2 on Ubuntu 16.04 / Debian 8 / Mint


Icinga Web 2 is the web interface for Icinga 2 where you can monitor your infrastructure for issues. Icinga 2 can also be used with other web interfaces.

Article Series:

1: Install Icinga2 on Ubuntu 16.04 / Debian, and Mint

2: Add Remote Linux Host into Icinga 2 Server

3: Setup Icinga Web 2 on Ubuntu 16.04 / Debian 8 / Mint

This guide explains you to setup Icinga 2 with Icinga web 2. We can install Icinga web 2 either using an official repository or from source depending on the operating system and distribution you are running.

Assuming that you are coming from the previous article on Install Icinga 2 on Ubuntu 16.04 / Debian 8 / Mint


  1. A web server, e.g. Apache / Nginx
  2. PHP 5.3.0 and above with gettextt, intl, and OpenSSL support.
  3. PHP LDAP library when using LDAP or Active Directory authentication.
  4. Icinga 1.x and 2.x with IDO feature enabled.
  5. The IDO table prefix must be icinga_
  6. PHP libraries for MySQL or PostgreSQL

Installing PHP 5

Icinga Web 2 does not support PHP 7, so you would need to install PHP 5.x version on Ubuntu 16.04. Follow below steps to install PHP 5.6 on Ubuntu 16.04.

### Adding PHP 5.6 PPA for Ubuntu 16.04 ###

$ sudo add-apt-repository ppa:ondrej/php
$ sudo apt-get update
$ sudo apt-get install php5.6

Adding Package Repository

Skip this, if you have already setup the Icinga 2 repository

Let’s add Icinga repository to your package manager for installing Icinga Web 2.

### Ubuntu 16.04/14.04/12.04 / Mint ###

$ sudo add-apt-repository ppa:formorer/icinga

### Debian ###

# wget -O - 2>/dev/null | apt-key add -

---- Jessie ----
# echo 'deb debmon-jessie main' > /etc/apt/sources.list.d/debmon.list
# echo 'deb jessie-backports main' >> /etc/apt/sources.list.d/debmon.list
---- Wheezy ----
# echo 'deb debmon-wheezy main' > /etc/apt/sources.list.d/debmon.list
# echo 'deb wheezy-backports main' >> /etc/apt/sources.list.d/debmon.list

Update the repository cache.

# apt-get update

Installing Icinga Web 2

You can install Icinga Web 2 by installing icingaweb2 package, run the following command on the terminal to begin installing Icinga Web 2.

# apt-get install -y icingaweb2

Preparing Icinga Web 2 Setup

When you are visiting Icinga Web 2 for the first time, Icinga setup wizard will guide you through all the steps for successful completion of Icinga Web 2 installation.

By default, Icinga CLI is installed along with Icinga Web 2 which is used for performing administration tasks in the command line. Both Icinga Web 2 and CLI must have access to logs and configurations. Add web server user (www-data) to the system group (icingaweb2)

# addgroup --system icingaweb2
# usermod -a -G icingaweb2 www-data

Restart the apache server.

### For SysVinit systems ###

# service apache2 restart

### For Systemd systems ###

# systemctl restart apache2

Icinga Web 2 Setup Wizard:

Visit the following link to begin setting up the Icinga Web 2; you would need to go through the setup wizard and complete the installation of Icinga Web 2.


For security reason, you would require to generate the token and paste it on the first step of the wizard.

Generate the token using the following command.

# icingacli setup token create

The newly generated setup token is: 8229eeac93ea7ae3

Copy and paste the above token on the following page.

Setup Icinga Web 2 on Ubuntu 16.04 - Enter Security Token
Setup Icinga Web 2 on Ubuntu 16.04 – Enter Security Token

Further Reading

You might also like

How to Setup Icinga Web 2 on Ubuntu 16.04 / Debian 8 / Mint