This guide will suppose you already have the following:
The starting point of the migration guide is an architecture such as the following:
|
This guide covers the migration of Shinken configuration and data collected by Shinken. This includes:
Because each environment has its own characteristics, this guide does not cover the migration of elements other than the Shinken architecture and configuration, meaning:
The first step of the migration is to copy the Shinken data of each machine to its counterpart in the new platform.
For each machine in the current plateform with Synchronizer, Arbiter or Broker daemons:
Create a backup of all the data in the machine:
shinken-backup |
Create an archive of the created backup folder and copy it to the new machine
Extract the archive and restore the backup on the new machine:
shinken-restore /path/to/backup/folder |
If you do not want to migrate the all available Shinken Enterprise data, you can select what you want with the parameters of shinken-backup and shinken-restore commands. These options are described on the Backup and restore commands documentation page. This can be useful for example if you have network disks for metrics and you can simply mount them on the new machines instead of copying all the metrology data. |
Restoring the configuration copies the configuration from the old machine as is on the new machine. This means the addresses of the different daemons still refer to the old daemons.
If the new platform is on another network with different addresses, you will have to change these addresses in the configuration to refer to the new daemons addresses.
If daemons use HTTPS and/or ports other than the default ports, the .ini files of the concerned daemons must be updated so that the communication ports and SSL communication options are properly configured. The inner workings of the daemons .ini files are explained in detail on the following documentation page: The Seven Demons.
The documentation pages for each daemon also contains a subpage that details the configuration process for using SSL. For example, for the Poller: Secure communications to the Poller
To keep hosts and checks status, Shinken uses retention on the Scheduler. When restarting a Scheduler, status are loaded from the retention instead of being "Unknown". This is important if you have notifications enabled, because by default an "Unknown" status on an host or check sends a notification. Without any retention, restarting your Scheduler might send a notification for each host of your monitoring configuration.
When migrating, you might want to also copy your retention data. If the retention module on the Schedulers is PickeRetentionFile, you can migrate your retention data by copying the /var/lib/shinken/retention.dat on the associated Scheduler in the new infrastructure.
The custom probes present in /var/lib/shinken-user/libexec are saved and restored by the shinken-backup and shinken-restore commands. If this folder contains custom probes, saving the configuration saves the entire /var/lib/shinken-user/libexec folder and restores it with shinken-restore.
This backup and restore operation for probes must be performed on all machines containing Pollers and Reactioners.
The probes present in /var/lib/shinken/libexec are the probes delivered by default during installation. This folder is not backed up or restored by the shinken-backup and shinken-restore commands. When updating Shinken, the content of this folder is overwritten by the content provided by the new version. Custom probes must then be placed in /var/lib/shinken-user/libexec to take advantage of backup utilities and avoid losing them when updating Shinken. |
The nagvis and nagvis-shinken-architecture addons each have their data and configuration files. The shinken-backup et and shinken-restore utilities can saved these data and configurations by using them with the "--addon" parameter.