User Tools

Site Tools


munin_neu

Munin

Munin manuell ausführen

su -s /bin/bash munin
/usr/bin/munin-cron

:!: NIE ALS ROOT AUSFÜHREN!

Probleme bei Update

Problem

Munin aktualisiert nicht mehr automatisch. Zugriffsrechte prüfen. Der Munin-Benutzer muss Schreibzugriff auf /var/lib/munin/* haben

Lösung

Falls Munin mit “–force-root” ausgeführt wurde folgendes

 chown -R munin:munin /var/lib/munin/org

und

 chown -R munin:munin /var/run/munin/munin-update.lock /var/run/munin/munin-org-knallimall.org.lock /var/run/munin/munin-datafile.lock

Plugins verwalten

Installierte Plugins

munin-node-configure

Munin - Plugins vorschlagen lassen

munin-node-configure --suggest

Zeige Symlinks die angelegt werden können um Plugins zu aktivieren

munin-node-configure --shell

MySQL chart leer

Schöne Doku hier: https://alexcline.net/2013/07/12/setting-up-the-mysql-plugin-in-munin/

Problem:

Der MySQL Chart ist leer. Es wird nichts angezeigt. Ursache kann oft der Fehlende MySQL Benutzer für Munin sein der die Statistik abfragt oder die oder die Zugriffsrechte falsch sind.

Lösung:

Zugriffsrechte für MySQL neu setzen bzw. erst mal anlegen.

mysql> CREATE USER 'mysqlmonitor'@'localhost' IDENTIFIED BY 's5e6etre5EvA';
mysql> GRANT PROCESS ON *.* TO 'mysqlmonitor'@'localhost';
mysql> FLUSH PRIVILEGES;

Benutzer unter /etc/munin/plugin-conf.d/munin-node mit Passwort eintragen

Beispiel:

[mysql_*]
  env.mysqlconnection DBI:mysql:mysql;host=127.0.0.1;port=3306
  env.mysqluser MUNINUSER
  env.mysqlpassword PASSWORT

:!: Wichtig, kein space zwischen Pramater und Wert bei Passwort und Benutzername für MySQL

Munin 2 on CentOS 6.5

Install Epel repo:

wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
sudo rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm

:!: disable Epel repo: /etc/yum.repos.d/epel.repo: enabled=0

Install Munin:

yum install --enablerepo=epel --disablerepo=rpmforge munin-node.noarch munin.noarch

Munin Apache Config:

nano -w /etc/httpd/conf.d/munin.conf

Run munin-cron as munin user:

su -s /bin/bash munin
/usr/bin/munin-cron

Completely remove Munin source install

yum remove munin-common munin-node
cd /usr/local/share/perl5
rm -rf Munin
find /. -print | grep -i munin

SNMP Monitoring (e.g. Synology NAS)

origin: http://munin-monitoring.org/wiki/Using_SNMP_plugins

  • NAS Hostname: synology
  • NAS IP: 192.168.1.150

Suggest available Plugins:

munin-node-configure --shell --snmp synology --snmpversion 1 --snmpcommunity community

Sample output:

ln -s '/usr/share/munin/plugins/snmp__cpuload' '/etc/munin/plugins/snmp_synology_cpuload'
ln -s '/usr/share/munin/plugins/snmp__df' '/etc/munin/plugins/snmp_synology_df'
Copy and paste each line to enable plugins for your NAS in Munin

Add hostname to /etc/hosts

192.168.1.150  synology

Add these lines to /etc/munin/munin.conf (this will create a seperate node on the interface)

[synology]
  address 127.0.0.1
  use_node_name no

Restart munin:

/etc/init.d/munin-node restart

Wait a few minutes and let Munin gather some data, you may want to run plugins manually

Monitor OpenWRT using muninlite

On OpenWRT

opkg update
opkg install muninlite xinetd

Enable xinetd on boot

ln -s /etc/init.d/xinetd /etc/rc.d/S70xinetd

Edit /etc/services and add if not present:

munin           4949/tcp

On Munin Master Server

add node to /etc/munin/munin.conf:

[openwrt]
  address 192.168.1.1
  use_node_name yes

check for usable plugins:

munin-node-configure --shell

Ubuntu 14.04 - Apache 2.4

Due to changes in Apache some changes in Munins Apache config are required.

Make sure you have following set in munin.conf for apache 2.4

Allow from All
Require all granted

Apache Monitoring - apache_status

munin_neu.txt · Last modified: 2016/09/02 21:27 by admin