Download PDF here.
January 9, 2018
The purpose of this document is to provide the steps necessary for upgrading an instance of Icinga 2, version 2.8 or later, to a new version. The steps contained within are sourced from the official Icinga 2 documentation in Section 18, “Upgrading Icinga 2”
This version of the documentation has been adapted to match the necessary upgrade steps for an instance of the Shadow-Soft Marketplace VHD image.
Upgrading Icinga 2
This guide assumes that you have the most up to date version of the
icinga-stable-release repository installed.
Instructions for adding this repository can be found in the official documentation at section “2.1.1. Package Repositories”
Updating the Client
[root@master~]# yum update icinga2 -- OUTPUT OMITTED -- [root@master~]# icinga2 --version icinga2 - The Icinga 2 network monitoring daemon (version: r2.8.1-1)
Upgrading to Icinga Web 2 2.5.x
- Icinga Web 2 v2.5 requires at least PHP 5.6.
- Hash marks (
#) in INI files are no longer recognized as comments by parse_ini_file since PHP 7.0
- Existing sessions of logged-in users do no longer work as expected due to a change in the
Userdata structure. Everyone who was logged in before the upgrade has to log out once
- Icinga Web 2 v2.5.0 requires a schema update for the database
- Upgrading to PHP 7.0 / 7.1 via RedHat SCL (new dependency)
- See Upgrading to FPM for manual steps that are required
- Make sure to enable the new Apache module
a2enmod php7and restart
See the official documentation for more information.
Upgrading the MySQL Database
If you’re upgrading an existing Icinga 2 instance, you should check the
/usr/share/icinga2-ido-mysql/schema/upgrade directory for an incremental schema upgrade file. If there isn’t an upgrade file for your current version available, there’s nothing to do.
Apply all database schema upgrade files incrementally.
[root@master~]# mysql -u root -p icinga < /usr/share/icinga2-ido-mysql/schema/upgrade/<version>.sql
The Icinga 2 DB IDO module will check for the required database schema version on startup and generate an error message if not satisfied.
You are upgrading from Icinga2 from version 2.0.2 to 2.3.0. Look into the
<span style="color: #ff0000;">/usr/share/icinga2-ido-mysql/schema/upgrade</span> directory:
[root@master ~]# ls /usr/share/icinga2-ido-mysql/schema/upgrade/ 2.0.2.sql 2.1.0.sql 2.2.0.sql 2.3.0.sql
There are three new upgrade files:
<span style="color: #ff0000;">2.1.0.sql</span>,
<span style="color: #ff0000;">2.2.0.sql</span>, and
<span style="color: #ff0000;">2.3.0.sql</span> which must be applied incrementally to your IDO database.
[root@master ~]# mysql -u root -p icinga < /usr/share/icinga2-ido-mysql/schema/upgrade/2.1.0.sql Enter password: [root@master ~]# mysql -u root -p icinga < /usr/share/icinga2-ido-mysql/schema/upgrade/2.2.0.sql Enter password: [root@master ~]# mysql -u root -p icinga < /usr/share/icinga2-ido-mysql/schema/upgrade/2.3.0.sql Enter password: [root@master ~]#
Upgrading Director Module
Reference the official documentation for upgrading Icinga Director. github: Upgrading Director