From 9a51633f3ed91cb2a196321cde37d6615cc7b2d0 Mon Sep 17 00:00:00 2001 From: lpoujol Date: Tue, 5 Jun 2018 17:36:11 +0200 Subject: [PATCH] =?UTF-8?q?Compl=C3=A9ments=20munin?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- HowtoMySQL/Replication.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/HowtoMySQL/Replication.md b/HowtoMySQL/Replication.md index 0b6ef2da..2729db12 100644 --- a/HowtoMySQL/Replication.md +++ b/HowtoMySQL/Replication.md @@ -194,6 +194,8 @@ log-slave-updates ## Monitoring +### Icinga/nagios + Pour surveiller que la réplication se fait bien et n'est pas en retard ou cassé par une erreur, on peut mettre en place un check nrpe *mysql_slave* Il faut pour cela donner les droits "REPLICATION CLIENT" a l'utilisateur MySQL nrpe : @@ -202,6 +204,15 @@ Il faut pour cela donner les droits "REPLICATION CLIENT" a l'utilisateur MySQL n GRANT REPLICATION CLIENT on *.* TO 'nrpe'@'localhost' IDENTIFIED BY 'PASSWORD'; ~~~ +### Munin + +Il est aussi intéressant d'ajouter certains graphes à munin pour suivre la application dans le temps. + +~~~ +ln -s '/usr/share/munin/plugins/mysql_' '/etc/munin/plugins/mysql_bin_relay_log' +ln -s '/usr/share/munin/plugins/mysql_' '/etc/munin/plugins/mysql_replication' +~~~ + ## Résolution des erreurs lors de la réplication On vérifie les erreurs avec les commandes `SHOW SLAVE STATUS` et `SHOW MASTER STATUS`.