Skip to content
This repository was archived by the owner on Dec 13, 2022. It is now read-only.

extend UK/FR documentation - add RRDCacheD configuration #8

Merged
merged 1 commit into from
Aug 6, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
84 changes: 84 additions & 0 deletions doc/en/faq/performance.rst
Original file line number Diff line number Diff line change
Expand Up @@ -76,3 +76,87 @@ Centreon storage database schema can be view here :

.. image:: ../database/centreon-storage.png

*********
RRDCacheD
*********

RRDCacheD is a process to reduce disk I/O during the update of performance's graphs and status' graphs.
The RRDCacheD process is loaded by the Centreon Broker module and mutualise I/O disques instead of recording
one by one the data from the collect.

Installation
============

The RRDCacheD process is available in **rrdtool** package and already installed on your server.

Configuration
=============

Main settings
*************

Edit the **/etc/sysconfig/rrdcached** file and complete informaiton::

# Settings for rrdcached
OPTIONS="-m 664 -l unix:/var/rrdtool/rrdcached/rrdcached.sock -s rrdcached -b /var/rrdtool/rrdcached -w 3600 -z 3600 -f 7200"
RRDC_USER=rrdcach

.. note::
The order of setting is pretty important. If **-m 664** is define before **-l unix:/var/rrdtool/rrdcached/rrdcached.sock** option then rights will be inccorrect on socket.

Options are following one:


+--------+-----------------------------------------------------------------------------------+
| Option | Description |
+========+===================================================================================+
| -w | Data are written every x seconds on disk (3600s in example reopresent 1h) |
+--------+-----------------------------------------------------------------------------------+
| -z | Should be less than **-w** option. RRDCacheD uses a range value from [0:-z] to do |
| | not write in RRDs in same time. |
+--------+-----------------------------------------------------------------------------------+
| -f | Timeout in cache before write data to disk. |
+--------+-----------------------------------------------------------------------------------+

.. note::
Please modify values with you needs.

Groups configuration
********************

Create groups using commands::

# usermod -a -g rrdcached centreon-broker
# usermod -a -g rrdcached apache
# usermod -a -g centreon rrdcached
# usermod -a -g centreon-broker rrdcached

Restart Apache process::

# /etc/init.d/httpd restart

Start RRDCacheD processus::

# /etc/init.d/rrdcached start

Centreon web configuration
**************************

Go to **Administration -> Options -> RRDTool** menu, enable processus and set unix socket path:

.. image:: /images/faq/rrdcached_config.png
:align: center

.. warning::
Instread of configuration was made into **Administration** you need to generate and export configuration of central server and restart cbd process to apply changes.

.. image:: /images/faq/rrd_file_generator.png
:align: center

Centreon web interface
**********************

RRDCacheD don't update performence's graphs in real time. If a blanc range aapear on right of performence's graphs it means that cache are not yet written to disk.

.. warning::
If the **RRDCacheD process crash** (in theory because it's a stable process) data will be lost! It is not possible to get data unless rebuild all graphs from Centeron web.
Binary file added doc/en/images/faq/rrd_file_generator.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/en/images/faq/rrdcached_config.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
87 changes: 87 additions & 0 deletions doc/fr/faq/performance.rst
Original file line number Diff line number Diff line change
Expand Up @@ -77,5 +77,92 @@ Le schéma de la base de données Centreon_storage ici :

.. image:: ../database/centreon-storage.png

*********
RRDCacheD
*********

RRDCacheD est un processus qui permet de limiter les E/S disque lors de la mise à jour des graphiques
de performance et/ou des graphiques de statut (fichiers RRDs).
Pour cela, le processus RRDCacheD est appelé par le module Centreon Broker et mutualise les écriture
sur disque plutôt que d'enregistrer une à une les données issues de la collecte.

Installation
============

Le processus RRDCacheD est disponible dnas le paquet **rrdtool** déjà installé sur votre serveur Centreon.

Configuration
=============

Options générales
*****************

Éditer le fichier **/etc/sysconfig/rrdcached** et modifier les informations suivantes ::

# Settings for rrdcached
OPTIONS="-m 664 -l unix:/var/rrdtool/rrdcached/rrdcached.sock -s rrdcached -b /var/rrdtool/rrdcached -w 3600 -z 3600 -f 7200"
RRDC_USER=rrdcached

.. note::
L'ordre des options est très important, si l'option ** -m 664** est placé eaprès l'option **-l unix:/var/rrdtool/rrdcached/rrdcached.sock** alors la socket sera créée avec les mauvais droits.

Concernant les autres options importantes :

+--------+-----------------------------------------------------------------------------------+
| Option | Description |
+========+===================================================================================+
| -w | Les données sont écrites sur le disques toutes les x secondes (ici 3600s donc 1h) |
+--------+-----------------------------------------------------------------------------------+
| -z | Doit être inférieur ou égale à l'option **-w**. RRDCacheD utilise une valeur |
| | aléatoire dans l'intervalle [0:-z] pour décaler l'écriture d'un fichier afin |
| | d'éviter que trop d'écritures soient mises en attente simultanément. |
+--------+-----------------------------------------------------------------------------------+
| -f | Correspond à un temps maximum de mise à jour (tilmeout). Si dans le cache des |
| | valeurs sont supérieures ou égales au nombre de secondes définies, alors celle-ci |
| | sont automatiquement écrite sur le disque. |
+--------+-----------------------------------------------------------------------------------+

.. note::
Ces valeurs doivent être adaptées en fonction du besoin/des contraintes de la plate-forme concernée !

Configuration des groupes
*************************

Créer les groupes en exécutant les commandes suivantes ::

# usermod -a -g rrdcached centreon-broker
# usermod -a -g rrdcached apache
# usermod -a -g centreon rrdcached
# usermod -a -g centreon-broker rrdcached

Redémarrer le processus Apache pour prendre en compte les modifications ::

# /etc/init.d/httpd restart

Démarrer le processus RRDCacheD ::

# /etc/init.d/rrdcached start

Configurer le processus dans l'interface web Centreon
*****************************************************

Se rendre dans le menu **Administration -> Options -> RRDTool**, activer l'utilisation du processus et renseigner l'accès au socket **/var/rrdtool/rrdcached/rrdcached.sock** :

.. image:: /images/faq/rrdcached_config.png
:align: center

.. warning::
Attention, même si la modification a été réalisé dans le menu **Administration**, il est nécessaire d'exporter la configuration et de redémarrer le processus centreon-broker via un export de la configuration du serveur central et un redémarrage du processus cbd.

.. image:: /images/faq/rrd_file_generator.png
:align: center

Interface web Centreon
======================

La mise en place de rrdcached fait que les graphiques ne sont plus mis à jours en temps réel.
Il est donc possible de voir un petit blanc sur la droite de certains graphiques.
Cela veut dire que les données sont encore dans le cache du processus, cela est normal !

.. warning::
Attention, si le **processus crash** pour une raison quelconque (aucune en théorie c'est plutôt stable), les **données** sont **perdues**, donc aucun moyen de les rejouer sauf en reconstruisant les graphiques via centreon-broker.
Binary file added doc/fr/images/faq/rrd_file_generator.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added doc/fr/images/faq/rrdcached_config.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.