Update a Centreon 22.04 platform
This chapter describes how to update your Centreon 22.04 platform (i.e. switch from version 22.04.x to version 22.04.y).
Perform a backupβ
Make sure that you have fully backed up your environment for the following servers:
- central server,
- database server.
Update the Centreon central serverβ
Prerequisitesβ
If you have installed debuginfo packages (or dbgsym on Debian), remove them before updating your platform. You can reinstall them after the update.
- Alma / RHEL / Oracle Linux 8
- Centos 7
- Debian 11
dnf remove \
centreon-collect-debuginfo-22.04.0-13.el8.x86_64 \
centreon-clib-debuginfo-22.04.0-13.el8.x86_64 \
centreon-engine-extcommands-debuginfo-22.04.0-13.el8.x86_64 \
centreon-engine-daemon-debuginfo-22.04.0-13.el8.x86_64 \
centreon-broker-cbmod-debuginfo-22.04.0-13.el8.x86_64 \
centreon-broker-core-debuginfo-22.04.0-13.el8.x86_64 \
centreon-broker-cbd-debuginfo-22.04.0-13.el8.x86_64
yum remove \
centreon-collect-debuginfo-22.04.0-13.el8.x86_64 \
centreon-clib-debuginfo-22.04.0-13.el8.x86_64 \
centreon-engine-extcommands-debuginfo-22.04.0-13.el8.x86_64 \
centreon-engine-daemon-debuginfo-22.04.0-13.el8.x86_64 \
centreon-broker-cbmod-debuginfo-22.04.0-13.el8.x86_64 \
centreon-broker-core-debuginfo-22.04.0-13.el8.x86_64 \
centreon-broker-cbd-debuginfo-22.04.0-13.el8.x86_64
apt remove 'centreon-*-dbgsym'
Update the Centreon solutionβ
Please make sure all users are logged out from the Centreon web interface before starting the update procedure.
- Alma / RHEL / Oracle Linux 8
- Centos 7
- Debian 11
Clean the cache:
dnf clean all --enablerepo=*
Then upgrade all the components with the following command:
dnf update centreon\*
Clean the cache:
yum clean all --enablerepo=*
Then upgrade all the components with the following command:
yum update centreon\*
Clean the cache:
apt clean all
apt updateThen upgrade all the components with the following command:
apt upgrade centreon
- Now you can either perform the update:
Finalize the update using the wizardβ
Log on to the Centreon web interface to continue the update process. Click on Next:
Click on Next:
The release notes describe the main changes. Click on Next:
This process performs the various upgrades. Click on Next:
Your Centreon server is now up to date. Click on Finish to access the login page:
If the Centreon BAM module is installed, refer to the update procedure.
Deploy the central's configuration from the Centreon web UI by following this procedure.
Finally, restart Broker, Engine and Gorgone on the central server by running this command:
systemctl restart cbd centengine gorgoned
You can now move to the Update extensions step.
Finalize the update using the API endpointβ
Log on to the central server through your terminal to continue the update process.
You need an authentication token to reach the API endpoint. Perform the following procedure to get a token.
In our case, we have the configuration described below (you need to adapt the procedure to your configuration).
- address: 10.25.XX.XX
- port: 80
- version: 22.04
- login: Admin
- password: xxxxx
Enter the following request:
curl --location --request POST '10.25.XX.XX:80/centreon/api/v22.04/login' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--data '{
"security": {
"credentials": {
"login": "Admin",
"password": "xxxxx"
}
}
}'This is how the result should look like:
{"contact":{"id":1,"name":"Admin Centreon","alias":"admin","email":"admin@localhost","is_admin":true},"security":{"token":"hwwE7w/ukiiMce2lwhNi2mcFxLNYPhB9bYSKVP3xeTRUeN8FuGQms3RhpLreDX/S"}}
Retrieve the token number to use it in the next request.
Then enter this request:
curl --location --request PATCH 'http://10.25.XX.XX:80/centreon/api/latest/platform/updates' \
--header 'X-AUTH-TOKEN: hwwE7w/ukiiMce2lwhNi2mcFxLNYPhB9bYSKVP3xeTRUeN8FuGQms3RhpLreDX/S' \
--header 'Content-Type: application/json' \
--data '{
"components": [
{
"name": "centreon-web"
}
]
}'This request does not return any result. To check if the update has been successfully applied, read the version number displayed on the Centreon web interface login page.
Finally, restart Broker, Engine and Gorgone on the central server by running this command:
systemctl restart cbd centengine gorgoned
Reinstall debuginfo or dbgsym packages (optional)β
If you uninstalled debuginfo or dbgsym packages before performing the update, you can reinstall them now.
Update extensionsβ
From Administration > Extensions > Manager, update all extensions, starting with the following:
- License Manager,
- Plugin Packs Manager,
- Auto Discovery.
Then you can update all other commercial extensions.
Update the Remote Serversβ
This procedure is the same as to update a Centreon central server.
At the end of the update, the configuration should be deployed from the central server.
Update the Pollersβ
- Alma / RHEL / Oracle Linux 8
- Centos 7
- Debian 11
Clean the cache:
dnf clean all --enablerepo=*
Then upgrade all the components with the following command:
dnf update centreon-poller
Clean the cache:
yum clean all --enablerepo=*
Then upgrade all the components with the following command:
yum update centreon-poller
Clean the cache:
apt clean all
apt updateThen upgrade all the components with the following command:
apt upgrade centreon-poller
Accept the new GPG keys from the repositories as needed.
Deploy the Poller's configuration from the Centreon web UI by following this procedure, and choose the Restart method for the Engine process.
Finally, restart the Gorgone service if it is used on the Poller:
systemctl restart centengine gorgoned