1 Installation de OS
Nous utiliserons l’image Raspbian Jessie, disponible ici : https://www.raspberrypi.org/downloads/raspbian/
2 Premier paramétrage et configuration
Nous utiliserons PUTTY pour se connecter en utilisateur le compte : pi avec le mot de passe : raspberry
Nous utiliserons la commande sudo pour éviter d’utiliser le compte root
Le raspberry Pi 3 comprend une interface Wifi, que je n’utiliserai pas dans mon exemple
Commencons par mettre l’ensemble de Raspbian à jour
sudo apt-get update
sudo apt-get -y upgrade
sudo apt-get -y dist-upgrade
sudo apt-get -y autoclean
Nous desactivons le service dhcpcd
sudo update-rc.d -f dhcpcd remove
Au cas ou voici la commande pour le réactiver
sudo update-rc.d dhcpcd defaults
Puis nous allons configurer celui-ci
Nous laisserons le mode par defaut en mode console, nous rajoutons le clavier europeen, le bon fuseau horaire
sudo raspi-config
Nous allons configurer la carte réseau avec une adresse IP fixe
Pour cela, nous allons modifiez le fichier /etc/network/interfaces
sudo nano /etc/network/interfaces
Nous rajoutons les ligne ci-dessous :
iface eth0 inet static
address 192.168.1.30
netmask 255.255.255.0
gateway 192.168.1.1
3 Pré requis global installation des bibliothéques
Des paquets de développement sont déjà chargés dans la version de Raspbian, mais il en manque un certains nombre pour l’installation de centreon
sudo apt-get install cmake libperl-dev libssh2-1-dev libgcrypt11-dev libcgsi-gsoap-dev zlib1g-dev libssl-dev libxerces-c-dev -y
sudo apt-get install nagios-plugins-basic librrd-dev libqt4-dev libqt4-sql-mysql libgnutls28-dev lsb-release librrds-perl libconfig-inifiles-perl -y
sudo apt-get install libnet-snmp-perl libdigest-hmac-perl libcrypt-des-ede3-perl libdbd-sqlite3-perl libdbd-mysql-perl snmp snmpd snmptrapd -y
sudo apt-get install libsnmp-perl snmp-mibs-downloader tofrodos bsd-mailx mariadb-server libmysqlclient-dev apache2 apache2-mpm-prefork -y
sudo apt-get install php5 php5-mysql php-pear php5-ldap php5-snmp php5-gd rrdtool librrds-perl libcrypt-des-perl libdigest-sha-perl -y
sudo apt-get install libgd-gd2-perl php5-sqlite php5-intl phpmyadmin -y
4 Téléchargement des sources
Nous pouvons télécharger l’ensemble des sources d’installation de centreon ainsi que les décompresser
cd ~
wget https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-clib/centreon-clib-1.4.2.tar.gz
–2016-08-09 18:04:51– https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-clib/centreon-clib-1.4.2.tar.gz
Résolution de s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com) ¦ 52.218.16.188
Connexion à s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com)|52.218.16.188|:443 ¦ connecté.
requéte HTTP transmise, en attente de la réponse ¦ 200OK
Taille : 124319 (121K) [application/x-gzip]
Sauvegarde en : « centreon-clib-1.4.2.tar.gz »centreon-clib-1.4.2.tar.gz [======================================================================================>] 121,41K –.-KB/s ds 0,1s
tar xzf centreon-clib-1.4.2.tar.gz
wget https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-connectors/centreon-connector-1.1.2.tar.gz
–2016-08-09 18:06:46– https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-connectors/centreon-connector-1.1.2.tar.gz
Résolution de s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com) ¦ 52.218.16.20
Connexion à s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com)|52.218.16.20|:443 ¦ connecté.
requéte HTTP transmise, en attente de la réponse ¦ 200OK
Taille : 94033 (92K) [application/x-gzip]
Sauvegarde en : « centreon-connector-1.1.2.tar.gz »centreon-connector-1.1.2.tar.gz [======================================================================================>] 91,83K –.-KB/s ds 0,1s
2016-08-09 18:06:46 (885 KB/s) « centreon-connector-1.1.2.tar.gz » sauvegardé [94033/94033]
tar xzf centreon-connector-1.1.2.tar.gz
wget https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-engine/centreon-engine-1.5.1.tar.gz
–2016-08-09 18:07:07– https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-engine/centreon-engine-1.5.1.tar.gz
Résolution de s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com) ¦ 52.218.48.52
Connexion à s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com)|52.218.48.52|:443 ¦ connecté.
requéte HTTP transmise, en attente de la réponse ¦ 200OK
Taille : 2262059 (2,2M) [application/x-gzip]
Sauvegarde en : « centreon-engine-1.5.1.tar.gz »centreon-engine-1.5.1.tar.gz [======================================================================================>] 2,16M 3,30MB/s ds 0,7s
2016-08-09 18:07:08 (3,30 MB/s) « centreon-engine-1.5.1.tar.gz » sauvegardé [2262059/2262059]
tar xzf centreon-engine-1.5.1.tar.gz
wget https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-broker/centreon-broker-2.11.5.tar.gz
–2016-08-09 18:08:01– https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-broker/centreon-broker-2.11.5.tar.gz
Résolution de s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com) ¦ 52.218.48.4
Connexion à s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com)|52.218.48.4|:443 ¦ connecté.
requéte HTTP transmise, en attente de la réponse ¦ 200OK
Taille : 1947881 (1,9M) [application/x-gzip]
Sauvegarde en : « centreon-broker-2.11.5.tar.gz »centreon-broker-2.11.5.tar.gz [======================================================================================>] 1,86M 1,66MB/s ds 1,1s
2016-08-09 18:08:02 (1,66 MB/s) « centreon-broker-2.11.5.tar.gz » sauvegardé [1947881/1947881]
tar xzf centreon-broker-2.11.5.tar.gz
wget https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon/centreon-web-2.7.6.tar.gz
–2016-08-09 18:08:48– https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon/centreon-web-2.7.6.tar.gz
Résolution de s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com) ¦ 52.218.48.236
Connexion à s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com)|52.218.48.236|:443 ¦ connecté.
requéte HTTP transmise, en attente de la réponse ¦ 200OK
Taille : 32423810 (31M) [application/x-gzip]
Sauvegarde en : « centreon-web-2.7.6.tar.gz »centreon-web-2.7.6.tar.gz [======================================================================================>] 30,92M 1,44MB/s ds 24s
2016-08-09 18:09:13 (1,29 MB/s) « centreon-web-2.7.6.tar.gz » sauvegardé [32423810/32423810]
tar xzf centreon-web-2.7.6.tar.gz
wget https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-translations/centreon-lang-fr_FR-2.7.tar.gz
–2016-08-09 18:10:03– https://s3-eu-west-1.amazonaws.com/centreon-download/public/centreon-translations/centreon-lang-fr_FR-2.7.tar.gz
Résolution de s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com) ¦ 52.218.16.188
Connexion à s3-eu-west-1.amazonaws.com (s3-eu-west-1.amazonaws.com)|52.218.16.188|:443 ¦ connecté.
requéte HTTP transmise, en attente de la réponse ¦ 200OK
Taille : 120644 (118K) [application/x-gzip]
Sauvegarde en : « centreon-lang-fr_FR-2.7.tar.gz »centreon-lang-fr_FR-2.7.tar.gz [======================================================================================>] 117,82K –.-KB/s ds 0,1s
2016-08-09 18:10:03 (922 KB/s) « centreon-lang-fr_FR-2.7.tar.gz » sauvegardé [120644/120644]
tar xzf centreon-lang-fr_FR-2.7.tar.gz
5 Installation clib
Commencons l’installation avec la Clib
cd ~/centreon-clib-1.4.2/build
Nous commencons par executer la compilation
cmake -DWITH_TESTING=0 -DWITH_PREFIX=/usr -DWITH_SHARED_LIB=1 -DWITH_STATIC_LIB=0 -DWITH_PKGCONFIG_DIR=/usr/lib/pkgconfig
Extrait du résultat :
— Configuration Summary
— ———————
—
— Project
— – Name Centreon Clib
— – Version 1.4.2
— – With shared library Yes
— – With static library No
—
— System
— – Name Linux
— – Version 4.1.19-v7+
— – Processor armv7l
—
— Build
— – Compiler /usr/bin/c++ (GNU)
— – Extra compilation flags
— – Build unit tests No
—
— Installation
— – Prefix /usr
— – Library directory /usr/lib
— – Include directory /usr/include
— – Package None
— – pkg-config directory /usr/lib/pkgconfig
—
— Configuring done
— Generating done
— Build files have been written to: /home/pi/centreon-clib-1.4.2/build
Ensuite compilons cette configuration
make
Enfin nous lancons installation
sudo make install
6 Centreon Perl Connector
Lancons l'installation du module PERL
cd ~/centreon-connector-1.1.2/perl/build
Nous commencons par executer la compilation
cmake -DWITH_PREFIX=/usr -DWITH_PREFIX_BINARY=/usr/lib/centreon-connector -DWITH_CENTREON_CLIB_INCLUDE_DIR=/usr/include -DWITH_TESTING=0
Extrait du résultat :-- Configuration Summary
-- ---------------------
--
-- Project
-- - Name Centreon Perl Connector
-- - Version 1.1.2
--
-- System
-- - Name Linux
-- - Version 4.1.19-v7+
-- - Processor armv7l
--
-- Build
-- - Compiler /usr/bin/c++ (GNU)
-- - Extra compilation flags -D_REENTRANT -D_GNU_SOURCE -DDEBIAN -fwrapv -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/lib/arm-linux-gnueabihf/perl/5.20/CORE
-- - Unit tests disabled
--
-- Install
-- - Prefix /usr
-- - Binary prefix /usr/lib/centreon-connector
-- - Package None
--
-- Libraries
-- - clib include directory /usr/include
-- - clib library directory /usr/lib/libcentreon_clib.so
-- Configuring done
-- Generating done
-- Build files have been written to: /home/pi/centreon-connector-1.1.2/perl/buildEnsuite compilons cette configuration
make
Enfin nous lancons installation
sudo make install
7 Centreon SSH Connector
Lancons l'installation du module SSH Connector
cd ~/centreon-connector-1.1.2/ssh/build
Nous commencons par executer la compilation
cmake -DWITH_PREFIX=/usr -DWITH_PREFIX_BINARY=/usr/lib/centreon-connector -DWITH_CENTREON_CLIB_INCLUDE_DIR=/usr/include -DWITH_TESTING=0
Extrait du résultat :-- Configuration Summary
-- ---------------------
--
-- Project
-- - Name Centreon SSH Connector
-- - Version 1.1.2
-- - Known hosts check disabled
--
-- System
-- - Name Linux
-- - Version 4.1.19-v7+
-- - Processor armv7l
--
-- Build
-- - Compiler /usr/bin/c++ (GNU)
-- - Extra compilation flags
-- - Unit tests disabled
--
-- Install
-- - Prefix /usr
-- - Binary prefix /usr/lib/centreon-connector
-- - Package None
--
-- Libraries
-- - clib include directory /usr/include
-- - clib library directory /usr/lib/libcentreon_clib.so
-- Configuring done
-- Generating done
-- Build files have been written to: /home/pi/centreon-connector-1.1.2/ssh/buildEnsuite compilons cette configuration
make
Enfin nous lancons installation
sudo make install
8 Installation du centreon-engine
8.1 Pré requis
Tout d'abord, Il faudra créer un utilisateur centreon-engine
sudo groupadd -g 6001 centreon-engine
sudo useradd -u 6001 -g centreon-engine -m -r -d /var/lib/centreon-engine -c "Centreon-engine Admin" centreon-engine
8.1 Installation
cd ~/centreon-engine-1.5.1/build/
Nous commencons par executer la compilation
cmake -DWITH_CENTREON_CLIB_INCLUDE_DIR=/usr/include -DWITH_CENTREON_CLIB_LIBRARY_DIR=/usr/lib -DWITH_PREFIX=/usr -DWITH_PREFIX_BIN=/usr/sbin -DWITH_PREFIX_CONF=/etc/centreon-engine -DWITH_USER=centreon-engine -DWITH_GROUP=centreon-engine -DWITH_LOGROTATE_SCRIPT=1 -DWITH_VAR_DIR=/var/log/centreon-engine -DWITH_RW_DIR=/var/lib/centreon-engine/rw -DWITH_STARTUP_DIR=/etc/init.d -DWITH_PKGCONFIG_SCRIPT=1 -DWITH_PKGCONFIG_DIR=/usr/lib/pkgconfig -DWITH_TESTING=0
Extrait du résultat :-- Configuration Summary
-- ---------------------
--
-- Project
-- - Name Centreon Engine
-- - Version 1.5.1
--
-- System
-- - Name Linux
-- - Version 4.1.19-v7+
-- - Processor armv7l
--
-- Build
-- - Compiler /usr/bin/c++ (GNU)
-- - Extra compilation flags
-- - Build static core library yes
-- - External commands module enabled
-- - Unit tests disabled
-- - pkg-config script enabled
-- - logrotate script enabled
-- - Startup script SysV-style script
--
-- Install
-- - Prefix /usr
-- - Binary prefix /usr/sbin
-- - Configuration prefix /etc/centreon-engine
-- - Library prefix /usr/lib/centreon-engine
-- - Include prefix /usr/include/centreon-engine
-- - var directory /var/log/centreon-engine
-- - Log archive directory /var/log/centreon-engine/archives
-- - RW directory /var/lib/centreon-engine/rw
-- - Lock prefix /var/lock/subsys/centengine.lock
-- - pkg-config directory /usr/lib/pkgconfig
-- - logrotate directory /etc/logrotate.d
-- - Startup directory /etc/init.d
-- - User centreon-engine
-- - Group centreon-engine
-- - Package None
--
-- Libraries
-- - clib include directory /usr/include
-- - clib library directory /usr/lib/libcentreon_clib.so
-- Configuring done
-- Generating done
-- Build files have been written to: /home/pi/centreon-engine-1.5.1/buildEnsuite compilons cette configuration
make
Enfin nous lancons installation
sudo make install
Vérifier le bon fonctionnement avec la commande suivante
root@supervision:~# centengine -V
[1458942079] [23451] Centreon Engine 1.5.1
[1458942079] [23451]
[1458942079] [23451] Copyright 1999-2009 Ethan Galstad
[1458942079] [23451] Copyright 2009-2010 Nagios Core Development Team and Community Contributors
[1458942079] [23451] Copyright 2011-2015 Merethis
[1458942079] [23451]
[1458942079] [23451] This program is free software: you can redistribute it and/or
[1458942079] [23451] modify it under the terms of the GNU General Public License version 2
[1458942079] [23451] as published by the Free Software Foundation.
[1458942079] [23451]
[1458942079] [23451] Centreon Engine is distributed in the hope that it will be useful,
[1458942079] [23451] but WITHOUT ANY WARRANTY; without even the implied warranty of
[1458942079] [23451] MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
[1458942079] [23451] General Public License for more details.
[1458942079] [23451]
[1458942079] [23451] You should have received a copy of the GNU General Public License
[1458942079] [23451] along with this program. If not, see
[1458942079] [23451] <http://www.gnu.org/licenses/>.Mettre le service centenaire en démarrage automatique
sudo update-rc.d centengine defaults
9 Plugins Nagios
Il faudra procéder à une modification des droits pour le plugin check_icmp
sudo chown root:centreon-engine /usr/lib/nagios/plugins/check_icmp
sudo chmod u+s /usr/lib/nagios/plugins/check_icmp
10 installation du Broker
10.1 Pré requis
Tout d'abord, Il faudra créer un groupe système et un utilisateur système centreon-Broker
sudo groupadd -g 6002 centreon-Broker
sudo useradd -u 6002 -g centreon-Broker -m -r -d /var/lib/centreon-Broker -c "Centreon-Broker Admin" -s /bin/bash centreon-Broker
sudo usermod -aG centreon-Broker centreon-engine
10.2 Installation
cd ~/home/pi/centreon-Broker-2.11.5/build/
Nous commencons par executer la compilation
cmake -DWITH_DAEMONS='central-Broker;central-rrd' -DWITH_GROUP=centreon-Broker -DWITH_PREFIX=/usr -DWITH_PREFIX_BIN=/usr/sbin -DWITH_PREFIX_CONF=/etc/centreon-Broker -DWITH_PREFIX_LIB=/usr/lib/centreon-Broker -DWITH_PREFIX_MODULES=/usr/share/centreon/lib/centreon-Broker -DWITH_STARTUP_DIR=/etc/init.d -DWITH_STARTUP_SCRIPT=auto -DWITH_TESTING=0 -DWITH_USER=centreon-Broker
Extrait du résultat :-- Configuration Summary
-- ---------------------
--
-- Project
-- - Name Centreon Broker
-- - Version 2.11.5
--
-- System
-- - Name Linux
-- - Version 4.1.19-v7+
-- - Processor armv7l
--
-- Build
-- - Compiler /usr/bin/c++ (GNU)
-- - Extra compilation flags
-- - Qt 4.8.6
-- - Unit tests disabled
-- - Startup script sysv
-- - Module stats, neb, file, compression, correlation, dumper, rrd, sql, storage, influxdb, graphite, bam, tcp, tls, bbdo, ndo
--
-- Install
-- - Prefix /usr
-- - Binary prefix /usr/sbin
-- - Library prefix /usr/lib/centreon-Broker
-- - Modules prefix /usr/share/centreon/lib/centreon-Broker
-- - Include prefix /usr/include/centreon-Broker
-- - Configuration prefix /etc/centreon-Broker
-- - Startup dir /etc/init.d
-- - User centreon-Broker
-- - Group centreon-Broker
-- - Package None
--
-- Configuring done
-- Generating done
-- Build files have been written to: /home/pi/centreon-Broker-2.11.5/buildEnsuite compilons cette configuration
make
Enfin nous lancons installation
sudo make install
Mettre le service cbd en démarrage automatique
sudo update-rc.d cbd defaults
11 Installation du SNMP
Modifiez le fichier /etc/snmp/snmpd.conf
sudo nano /etc/snmp/snmpd.conf
agentAddress udp:localhost:161
rocommunity public localhostiquerySecName internalUser
trapsink localhost public
Pour éviter d’avoir un deamon snmpd trop bavard, (réduction des logs), modifiez le fichier /etc/default/snmpd
sudo nano /etc/default/snmpd
# snmpd options (use syslog, close stdin/out/err).
SNMPDOPTS='-LS4d -Lf /dev/null -u snmp -g snmp -I -smux,mteTrigger,mteTriggerConf -p /run/snmpd.pid'Pour recevoir les traps, modifiez le fichier /etc/default/snmptrapd
sudo nano /etc/default/snmptrapd
TRAPDRUN=yes
.....
# snmptrapd options (use syslog).
TRAPDOPTS='-On -Lsd -p /var/run/snmptrapd.pid'12 Installation des mibs
Le dépôt non-free est déjà paramétré, il suffit d’ajouter le paquet suivant.
Créez un lien symbolique
sudo ln -s /usr/share/mibs/ /usr/share/snmp/mibs
Modifiez le fichier /etc/default/snmpd
sudo nano /etc/default/snmpd
export MIBDIRS=/usr/share/snmp/mibs
export MIBS=ALLCommentez la ligne du fichier /etc/snmp/snmp.conf
sudo nano /etc/snmp/snmp.conf
#mibs ALL
Redémarrez les services SNMP
sudo service snmpd snmptrapd restart
Vérification du fonctionnementPour vérifier le fonctionnement, saisir la ligne suivante
snmpwalk -c public -v 2c localhost
13 Installation centreon web
13.1 Pré requis
Tout d'abord, Il faudra créer un utilisateur centreon
sudo groupadd -g 6000 centreon
sudo useradd -u 6000 -g centreon -m -r -d /var/lib/centreon -c "Centreon Admin" centreon
13.2 Installation partie ligne de commande
cd /home/pi/centreon-web-2.7.6
sudo ./install.sh -i
###############################################################################
# #
# Centreon (www.centreon.com) #
# Thanks for using Centreon #
# #
# v2.7.6 #
# #
# infos@centreon.com #
# #
# Make sure you have installed and configured #
# sudo - sed - php - apache - rrdtool - mysql #
# #
###############################################################################
------------------------------------------------------------------------
Checking all needed binaries
------------------------------------------------------------------------
rm OK
cp OK
mv OK
/bin/chmod OK
/bin/chown OK
echo OK
more OK
mkdir OK
find OK
/bin/grep OK
/bin/cat OK
/bin/sed OKYou will now read Centreon Licence.
Press enter to continue.This General Public License does not permit incorporating your program into
proprietary programs. If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library. If this is what you want to do, use the GNU Library General
Public License instead of this License.Do you accept GPL license ?
[y/n], default to [n]:
> y------------------------------------------------------------------------
Please choose what you want to install
------------------------------------------------------------------------Do you want to install : Centreon Web Front
[y/n], default to [n]:
> yDo you want to install : Centreon CentCore
[y/n], default to [n]:
> yDo you want to install : Centreon Nagios Plugins
[y/n], default to [n]:
> yDo you want to install : CentreonTrapd process
[y/n], default to [n]:
> y------------------------------------------------------------------------
Start CentWeb Installation
------------------------------------------------------------------------Where is your Centreon directory?
default to [/usr/local/centreon]
> /usr/share/centreon
Path /usr/share/centreon OKWhere is your Centreon log directory
default to [/usr/local/centreon/log]
> /var/log/centreonDo you want me to create this directory ? [/var/log/centreon]
[y/n], default to [n]:
> y
Path /var/log/centreon OKWhere is your Centreon etc directory
default to [/etc/centreon]
>Do you want me to create this directory ? [/etc/centreon]
[y/n], default to [n]:
> y
Path /etc/centreon OKWhere is your Centreon binaries directory
default to [/usr/local/centreon/bin]
> /usr/share/centreon/binDo you want me to create this directory ? [/usr/share/centreon/bin]
[y/n], default to [n]:
> y
Path /usr/share/centreon/bin OKWhere is your Centreon data informations directory
default to [/usr/local/centreon/data]
> /usr/share/centreon/dataDo you want me to create this directory ? [/usr/share/centreon/data]
[y/n], default to [n]:
> y
Path /usr/share/centreon/data OKWhere is your Centreon variable library directory?
default to [/var/lib/centreon]
>Do you want me to create this directory ? [/var/lib/centreon]
[y/n], default to [n]:
> y
Path /var/lib/centreon OK
/usr/bin/rrdtool OK
/usr/bin/mail OK
/usr/bin/php OKWhere is PEAR [PEAR.php]
default to [/usr/share/php/PEAR.php]
>
Path /usr/share/php OK
/usr/bin/perl OK
Enable Apache configuration OK
ERROR: Conf centreon does not exist!
Finding Apache user : www-data
Finding Apache group : www-dataWhat is the Centreon group ? [centreon]
default to [centreon]
>What is the Centreon user ? [centreon]
default to [centreon]
>What is the Monitoring engine user ?
> centreon-engineWhat is the Broker user ? (optional)
> centreon-BrokerWhat is the Monitoring engine log directory ?
> /var/log/centreon-engineWhere is your monitoring plugins (libexec) directory ?
default to [/usr/lib/nagios/plugins]
>
Path /usr/lib/nagios/plugins OK
Add group centreon to user www-data OK
Add group centreon to user centreon-engine OK
Add group centreon-engine to user www-data OK
Add group centreon-engine to user centreon OK------------------------------------------------------------------------
Configure Sudo
------------------------------------------------------------------------Where is sudo configuration file
default to [/etc/sudoers]
>
/etc/sudoers OKWhat is the Monitoring engine init.d script ?
> /etc/init.d/centengineWhat is the Monitoring engine binary ?
> /usr/sbin/centengineWhat is the Monitoring engine configuration directory ?
> /etc/centreon-engineWhere is the configuration directory for Broker module ?
> /etc/centreon-BrokerWhere is the init script for Broker module daemon ?
> /etc/init.d/cbd
Your sudo is not configuredDo you want me to configure your sudo ? (WARNING)
[y/n], default to [n]:
> y
Configuring Sudo OK------------------------------------------------------------------------
Configure Apache server
------------------------------------------------------------------------Do you want to add Centreon Apache sub configuration file ?
[y/n], default to [n]:
> y
Create '/etc/apache2/conf-available/centreon.conf' OK
Configuring Apache OKDo you want to reload your Apache ?
[y/n], default to [n]:
> y
Reloading Apache service OK
Preparing Centreon temporary files
Change right on /var/log/centreon OK
Change right on /etc/centreon OK
Change macros for insertBaseConf.sql OK
Change macros for sql update files OK
Change macros for php files OK
Change macros for php config file OK
Change macros for perl binary OK
Change right on /etc/centreon-engine OK
Add group centreon-Broker to user www-data OK
Add group centreon-Broker to user centreon-engine OK
Add group centreon to user centreon-Broker OK
Change right on /etc/centreon-Broker OK
Copy CentWeb in system directory
Install CentWeb (web front of centreon) OK
Change right for install directory
Change right for install directory OK
Install libraries OK
Write right to Smarty Cache OK
Copying libinstall OK
Change macros for centreon.cron OK
Install Centreon cron.d file OK
Change macros for centAcl.php OK
Change macros for downtimeManager.php OK
Install cron directory OK
Change right for eventReportBuilder OK
Change right for dashboardBuilder OK
Change macros for centreon.logrotate OK
Install Centreon logrotate.d file OK
Prepare centFillTrapDB OK
Install centFillTrapDB OK
Prepare centreon_trap_send OK
Install centreon_trap_send OK
Prepare centreon_check_perfdata OK
Install centreon_check_perfdata OK
Prepare centreonSyncPlugins OK
Install centreonSyncPlugins OK
Prepare centreonSyncArchives OK
Install centreonSyncArchives OK
Prepare generateSqlLite OK
Install generateSqlLite OK
Install changeRrdDsName.pl OK
Prepare export-mysql-indexes OK
Install export-mysql-indexes OK
Prepare import-mysql-indexes OK
Install import-mysql-indexes OK
Prepare clapi binary OK
Install clapi binary OK
Centreon Web Perl lib installed OK------------------------------------------------------------------------
Pear Modules
------------------------------------------------------------------------
Check PEAR modules
PEAR 1.4.9 1.10.1 OK
DB 1.7.6 OK
DB_DataObject 1.8.4 OK
DB_DataObject_FormBuilder 1.0.0RC4 OK
MDB2 2.0.0 OK
Date 1.4.6 OK
Archive_Tar 1.1 1.4.0 OK
Auth_SASL 1.0.1 OK
Console_Getopt 1.2 1.4.1 OK
Validate 0.6.2 OK
Log 1.9.11 OK
Archive_Zip 0.1.2 OKDo you want me to install/upgrade your PEAR modules
[y/n], default to [y]:
> yUpgrading PEAR modules
Installing PEAR modules
DB 1.7.6 1.9.2 OK
DB_DataObject 1.8.4 1.11.5 OK
DB_DataObject_FormBuilder 1.0.0RC4 1.0.2 OK
MDB2 2.0.0 2.4.1 OK
Auth_SASL 1.0.1 1.0.6 OK
Validate 0.6.2 0.8.5 OK
Log 1.9.11 1.12.9 OK
Archive_Zip 0.1.2 0.1.2 OK
Check PEAR modules
PEAR 1.4.9 1.10.1 OK
DB 1.7.6 1.9.2 OK
DB_DataObject 1.8.4 1.11.5 OK
DB_DataObject_FormBuilder 1.0.0RC4 1.0.2 OK
MDB2 2.0.0 2.4.1 OK
Date 1.4.6 1.4.7 OK
Archive_Tar 1.1 1.4.0 OK
Auth_SASL 1.0.1 1.0.6 OK
Console_Getopt 1.2 1.4.1 OK
Validate 0.6.2 0.8.5 OK
Log 1.9.11 1.12.9 OK
Archive_Zip 0.1.2 0.1.2 OK
All PEAR modules OK------------------------------------------------------------------------
Centreon Post Install
------------------------------------------------------------------------
Create /usr/share/centreon/www/install/install.conf.php OK
Create /etc/centreon/instCentWeb.conf OK------------------------------------------------------------------------
Start CentStorage Installation
------------------------------------------------------------------------Where is your Centreon Run Dir directory?
default to [/var/run/centreon]
>Do you want me to create this directory ? [/var/run/centreon]
[y/n], default to [n]:
> y
Path /var/run/centreon OKWhere is your CentStorage binary directory
default to [/usr/share/centreon/bin]
>
Path /usr/share/centreon/bin OKWhere is your CentStorage RRD directory
default to [/var/lib/centreon]
>
Path /var/lib/centreon OK
Preparing Centreon temporary files
/tmp/centreon-setup exists, it will be moved...
install www/install/createTablesCentstorage.sql OK
Creating Centreon Directory '/var/lib/centreon/status' OK
Creating Centreon Directory '/var/lib/centreon/metrics' OK
Change right : /var/run/centreon OK
Install logAnalyserBroker OK
Install nagiosPerfTrace OK
Change macros for centstorage.cron OK
Install CentStorage cron OK
Change macros for centstorage.logrotate OK
Install Centreon Storage logrotate.d file OK
Create /etc/centreon/instCentStorage.conf OK------------------------------------------------------------------------
Start CentCore Installation
------------------------------------------------------------------------Where is your CentCore binary directory
default to [/usr/share/centreon/bin]
>
Path /usr/share/centreon/bin OK
Preparing Centreon temporary files
/tmp/centreon-setup exists, it will be moved...
Copy CentCore in binary directory OK
Change right : /var/run/centreon OK
Change right : /var/lib/centreon OK
Change macros for centcore.logrotate OK
Install Centreon Core logrotate.d file OK
Replace CentCore init script Macro OK
Replace CentCore default script Macro OKDo you want me to install CentCore init script ?
[y/n], default to [n]:
> y
CentCore init script installed OK
CentCore default script installed OKDo you want me to install CentCore run level ?
[y/n], default to [n]:
> y
update-rc.d: warning: start and stop actions are no longer supported; falling back to defaults
CentCore Perl lib installed OK
Create /etc/centreon/instCentCore.conf OK------------------------------------------------------------------------
Start CentPlugins Traps Installation
------------------------------------------------------------------------Where is your SNMP configuration directory
default to [/etc/snmp]
>
/etc/snmp OKWhere is your CentreonTrapd binaries directory
default to [/usr/local/centreon/bin]
> /usr/share/centreon/bin
/usr/share/centreon/bin OK
Finding Apache user : www-data
Preparing Centreon temporary files
/tmp/centreon-setup exists, it will be moved...
Change macros for snmptrapd.conf OK
Replace CentreonTrapd init script Macro OK
Replace CentreonTrapd default script Macro OKDo you want me to install CentreonTrapd init script ?
[y/n], default to [n]:
> y
CentreonTrapd init script installed OK
CentreonTrapd default script installed OKDo you want me to install CentreonTrapd run level ?
[y/n], default to [n]:
> y
update-rc.d: warning: start and stop actions are no longer supported; falling back to defaults
trapd Perl lib installed OK
Install : snmptrapd.conf OK
Install : centreontrapdforward OK
Install : centreontrapd OK
Change macros for centreontrapd.logrotate OK
Install Centreon Trapd logrotate.d file OK
Create /etc/centreon/instCentPlugins.conf OK
###############################################################################
# #
# Go to the URL : http://raspberrypi/centreon/ #
# to finish the setup #
# #
# Report bugs at https://github.com/centreon/centreon/issues #
# #
# Thanks for using Centreon. #
# ----------------------- #
# Contact : infos@centreon.com #
# http://www.centreon.com #
# #
###############################################################################
sudo vi /etc/php5/apache2/php.ini
Saisissez la valeur adaptée à votre configuration[Date]
; Defines the default timezone used by the date functions
; http://php.net/date.timezone
date.timezone = Europe/ParisIl faut autoriser la configuration Centreon pour le serveur Web Apache
sudo a2enconf centreon.conf
sudo service apache2 reload
14 Installation partie Web
Utilisez un navigateur internet récent et saisissez l’url suivante :
http://@IP/centreon/
Démarrage de l'installation Web, cliquez sur Next
Validation des dépendances, cliquez sur Next
Nous choisirons comme moteur de supervision centreon-engine. Saisissez les chemins ci-dessousCentreon Engine directory: /usr/sbin/
Centreon Engine Stats binary: /usr/sbin/centenginestats
Centreon Engine var lib directory: /var/lib/centreon-engine
Centreon Engine Connector path: /usr/lib/centreon-connector
Centreon Engine Library (*.so) directory: /usr/lib/centreon-engine/Cliquez sur Next
Auparavant, il faudra créer le dossier /var/log/centreon-Broker et donner la permission au processus centengine d'écrire le fichier de statistique.sudo mkdir /var/log/centreon-Broker
sudo chown centreon-Broker:centreon-Broker /var/log/centreon-Broker
sudo chmod 775 /var/log/centreon-Broker
sudo chmod 775 /var/lib/centreon-Broker
Nous choisirons comme Broker centreon-Broker. Saisissez les chemins ci-dessousCentreon Broker etc directory: /etc/centreon-Broker
Centreon Broker module (cbmod.so): /usr/lib/centreon-Broker/cbmod.so
Centreon Broker log directory: /var/log/centreon-Broker
Retention file directory: /var/lib/centreon-Broker
Centreon Broker lib (*.so) directory: /usr/share/centreon/lib/centreon-BrokerCréation du user "Administrateur", admin et son mot de passe. Saisir une adresse valide pour l’email
Cliquez sur Next
Définir les Accès MySQL, le mot de passe de MySQL
Laisser les noms de base par défaut CENTREON, CENTSTORAGE et CENTSTATUS
Saisir le mot de passe pour ces bases de données.
Cliquez sur NextAttention, la création des bases est relativement longue, patientez
Cliquez sur Next
Fin de l'installation, cliquez sur Finish
Vous devriez avoir cette vue. Vous pouvez vous connecter à l'interface d'administration.
-IMAGE-15 Installation du module de language
16 Configuration des services
Démarrez les services ci-dessous
sudo service centcore start
sudo service centreontrapd start
Connectez-vous à l'interface de Centreon. Sélectionnez le menu Configuration / Pollers
-IMAGE-Cochez le poller Central et cliquez sur Apply configuration.
-IMAGE-cochez les quatre premières options et cliquez sur Export
-IMAGE-Il faut lancez le service Broker.
sudo service cbd start
Au bout de quelques secondes, vous devriez voir apparaître les hôtes et services dans la barre d'état en haut à droite.
-IMAGE-Hôte et services de la barre d'état
Votre supervision est en état de fonctionnement
Les services commencent à s'initialiser.
Votre installation est fonctionnelle
Il ne reste pour qu'a passer à la configuration
17 Mise à jour
17.1 Des modules
17.1 Du module web
Nous lancons la mise à jour avec la ligne de commande
sudo ./install.sh -u /etc/centreon
###############################################################################
# #
# Centreon (www.centreon.com) #
# Thanks for using Centreon #
# #
# v2.6.0 #
# #
# infos@centreon.com #
# #
# Make sure you have installed and configured #
# sudo - sed - php - apache - rrdtool - mysql #
# #
###############################################################################
------------------------------------------------------------------------
Checking all needed binaries
------------------------------------------------------------------------
rm OK
cp OK
mv OK
/bin/chmod OK
/bin/chown OK
echo OK
more OK
mkdir OK
find OK
/bin/grep OK
/bin/cat OK
/bin/sed OK
------------------------------------------------------------------------
Detecting old installation
------------------------------------------------------------------------
Finding configuration file in: /etc/centreon OK
You seem to have an existing Centreon.Do you want to use the last Centreon install parameters ?
[y/n], default to [y]:
> yUsing: /etc/centreon/instCentCore.conf
/etc/centreon/instCentPlugins.conf
/etc/centreon/instCentStorage.conf
/etc/centreon/instCentWeb.confDo you want to install : Centreon Web Front
[y/n], default to [n]:
> yDo you want to install : Centreon CentCore
[y/n], default to [n]:
> yDo you want to install : Centreon Nagios Plugins
[y/n], default to [n]:
> yDo you want to install : Centreon Snmp Traps process
[y/n], default to [n]:
> y
Convert variables for upgrade:------------------------------------------------------------------------
Start CentWeb Installation
------------------------------------------------------------------------Where is your Centreon binaries directory
default to [/usr/local/centreon/bin]
>
Path /usr/local/centreon/bin OKWhere is your Centreon data information directory
default to [/usr/local/centreon/data]
>Do you want me to create this directory ? [/usr/local/centreon/data]
[y/n], default to [n]:
> y
Path /usr/local/centreon/data
/usr/bin/perl OK
Finding Apache user : www-data
Finding Apache group : www-dataWhat is the Centreon group ? [centreon]
default to [centreon]
>Do you want me to create this group ? [centreon]
[y/n], default to [n]:
> yWhat is the Centreon user ? [centreon]
default to [centreon]
>Do you want me to create this user ? [centreon]
[y/n], default to [n]:
> yCentreon Broker : centreon-broker
What is the Broker user ? (optional)
>Centreon Engine : /var/log/centreon-engine
Where is your monitoring plugins (libexec) directory ?
default to [/usr/lib/nagios/plugins]
>Path /usr/lib/nagios/plugins OK
Add group centreon to user www-data OK
Add group centreon to user nagios OK
Add group nagios to user www-data OK
Add group nagios to user centreon OK------------------------------------------------------------------------
Configure Sudo
------------------------------------------------------------------------Centreon Engine : /etc/init.d/centengine
Centreon Broker : /etc/centreon-broker
Centreon Broker : /etc/init.d/cbd
Do you want me to reconfigure your sudo ? (WARNING)
[y/n], default to [n]:
> y
Configuring Sudo OK------------------------------------------------------------------------
Configure Apache server
------------------------------------------------------------------------
Create '/etc/apache2/conf.d/centreon.conf' OK
Configuring Apache OKDo you want to reload your Apache ?
[y/n], default to [n]:
> y
Reloading Apache service OK
Preparing Centreon temporary files
Change right on /usr/local/centreon/log OK
Change right on /etc/centreon OK
Change macros for insertBaseConf.sql OK
Change macros for sql update files OK
Change macros for php files OK
Disconnect users from WebUI
All users are disconnected OK
Copy CentWeb in system directory
Install CentWeb (web front of centreon) OK
Change right for install directory
Change right for install directory OK
Install libraries OK
Write right to Smarty Cache OK
Copying libinstall OK
Change macros for centreon.cron OK
Install Centreon cron.d file OK
Change macros for centAcl.php OK
Change macros for downtimeManager.php OK
Change macros for eventReportBuilder.pl OK
Change macros for dashboardBuilder.pl OK
Install cron directory OK
Change right for eventReportBuilder.pl OK
Change right for dashboardBuilder.pl OK
Change macros for centreon.logrotate OK
Install Centreon logrotate.d file OK
Prepare export-mysql-indexes OK
Install export-mysql-indexes OK
Prepare import-mysql-indexes OK
Install import-mysql-indexes OK
Prepare indexes schema OK
Install indexes schema OK------------------------------------------------------------------------
Pear Modules
------------------------------------------------------------------------
Check PEAR modules
PEAR 1.4.9 1.9.4 OK
DB 1.7.6 1.7.14 OK
DB_DataObject 1.8.4 1.10.0 OK
DB_DataObject_FormBuilder 1.0.0RC4 1.0.2 OK
MDB2 2.0.0 2.4.1 OK
Date 1.4.6 1.4.7 OK
HTML_Common 1.2.2 1.2.5 OK
HTML_QuickForm 3.2.5 3.2.13 OK
HTML_QuickForm_advmultiselect 1.1.0 1.5.1 OK
HTML_Table 1.6.1 1.8.3 OK
Archive_Tar 1.1 1.3.7 OK
Auth_SASL 1.0.1 1.0.6 OK
Console_Getopt 1.2 1.2.3 OK
Net_SMTP 1.2.8 1.6.1 OK
Net_Socket 1.0.1 1.0.10 OK
Net_Traceroute 0.21 0.21.3 OK
Net_Ping 2.4.1 2.4.5 OK
Validate 0.6.2 0.8.5 OK
XML_RPC 1.4.5 1.5.5 OK
SOAP 0.10.1 0.13.0 OK
Log 1.9.11 1.12.7 OK
Archive_Zip 0.1.2 0.1.2 OK
All PEAR modules OK------------------------------------------------------------------------
Centreon Post Install
------------------------------------------------------------------------
Create /usr/local/centreon/www/install/install.conf.php OK
Create /etc/centreon/instCentWeb.conf OK
Convert variables for upgrade:------------------------------------------------------------------------
Start CentStorage Installation
------------------------------------------------------------------------
Preparing Centreon temporary files
/tmp/centreon-setup exists, it will be moved...
install www/install/createTablesCentstorage.sql OK
CentStorage status Directory already exists PASSED
CentStorage metrics Directory already exists PASSED
Change macros for centstorage binary OK
Install CentStorage binary OK
Install library for centstorage OK
Change right : /var/run/centreon OK
Change macros for centstorage init script OK
Replace CentCore default script Macro OKDo you want me to install CentStorage init script ?
[y/n], default to [n]:
> y
CentStorage init script installed OK
CentStorage default script installed OKDo you want me to install CentStorage run level ?
[y/n], default to [n]:
> y
update-rc.d: using dependency based boot sequencing
insserv: warning: current start runlevel(s) (3 5) of script 'centstorage' overwrites defaults (2 3 4 5).
Change macros for logAnalyser OK
Install logAnalyser OK
Change macros for logAnalyser-cbroker OK
Install logAnalyser-cbroker OK
Change macros for nagiosPerfTrace OK
Install nagiosPerfTrace OK
Change macros for purgeLogs OK
Install purgeLogs OK
Change macros for purgeCentstorage OK
Install purgeCentstorage OK
Change macros for centreonPurge.sh OK
Install centreonPurge.sh OK
Change macros for centstorage.cron OK
Install CentStorage cron OK
Change macros for centstorage.logrotate OK
Install Centreon Storage logrotate.d file OK
Create /etc/centreon/instCentStorage.conf OK
Convert variables for upgrade:------------------------------------------------------------------------
Start CentCore Installation
------------------------------------------------------------------------
Preparing Centreon temporary files
/tmp/centreon-setup exists, it will be moved...
Change CentCore Macro OK
Copy CentCore in binary directory OK
Change right : /var/run/centreon OK
Change right : /var/lib/centreon OK
Change macros for centcore.logrotate OK
Install Centreon Core logrotate.d file OK
Replace CentCore init script Macro OK
Replace CentCore default script Macro OKDo you want me to install CentCore init script ?
[y/n], default to [n]:
> y
CentCore init script installed OK
CentCore default script installed OKDo you want me to install CentCore run level ?
[y/n], default to [n]:
> y
update-rc.d: using dependency based boot sequencing
insserv: warning: current start runlevel(s) (3 5) of script 'centcore' overwrites defaults (2 3 4 5).
Create /etc/centreon/instCentCore.conf OK
Convert variables for upgrade:------------------------------------------------------------------------
Start CentPlugins Traps Installation
------------------------------------------------------------------------
Finding Apache user : www-data
Preparing Centreon temporary files
/tmp/centreon-setup exists, it will be moved...
Change macros for CentPluginsTraps OK
Change macros for init scripts OK
Installing the plugins Trap binaries OK
Backup all your snmp files OK
Change macros for snmptrapd.conf OK
Change macros for snmptt.ini OK
SNMPTT init script installed OK
SNMPTT default script installed OK
update-rc.d: using dependency based boot sequencing
Install : snmptrapd.conf OK
Install : snmp.conf OK
Install : snmptt.ini OK
Install : snmptt OK
Install : snmptthandler OK
Install : snmpttconvertmib OK
Generate SNMPTT configuration OK
Create /etc/centreon/instCentPlugins.conf OK###############################################################################
# #
# Go to the URL : http://localhost/centreon/ #
# to finish the setup #
# #
# Report bugs at https://github.com/centreon/centreon/issues #
# #
# Thanks for using Centreon. #
# ----------------------- #
# Contact : infos@centreon.com #
# http://www.centreon.com #
# #
###############################################################################Nous lancons la mise à jour avec l'interface web
http://@IP/centreon/