====== Munin ======
I shall not start by repeating cliche ''apt-get install munin-node''.
Update 1.1.2016: Debian jessie has linux_diskstat_ in munin-plugins-core, but named "diskstat_" so be careful. This plugin needs to be enabled for auto configuration by changing comment family
#%# family=manual
to
#%# family=auto
Important detailed disk statistics requires more then //apt-get//.
wget http://somewhere/linux_diskstat_
chmod a+x linux_diskstat_
cp linux_diskstat_ /usr/share/munin/plugins/linux_diskstat_
munin-node-configure --shell
The last command should return a lot of lines to cut&paste. Carefully select relevant lines. You probably want only local devices (ie. no iscsi and so on).
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_iops_cciss:c0d0'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_iops_cciss:c0d1'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_iops_dm-0'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_iops_dm-1'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_iops_dm-2'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_iops_dm-3'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_latency_cciss:c0d0'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_latency_cciss:c0d1'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_latency_dm-0'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_latency_dm-1'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_latency_dm-2'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_latency_dm-3'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_throughput_cciss:c0d0'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_throughput_cciss:c0d1'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_throughput_dm-0'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_throughput_dm-1'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_throughput_dm-2'
ln -s '/usr/share/munin/plugins/linux_diskstat_' '/etc/munin/plugins/linux_diskstat_throughput_dm-3'
//That's all!//
**Kratky popis patche:**
Skript ignoroval vsechny zarizeni se dvema cislicemi, napr. /dev/md-56 to nevzalo, protoze si skript myslel, ze je to 6. partition na zarizeni "md-5". Hledal jsem to asi hodinu :-(
--- /usr/share/munin/plugins/linux_diskstat_~ 2013-02-07 16:52:41.000000000 +0100
+++ /usr/share/munin/plugins/linux_diskstat_ 2013-11-06 03:08:26.000000000 +0100
@@ -172,6 +172,7 @@
# Filter out devices (partitions) which are matched by existing ones
# e.g. sda1 -> sda, c0d0p1 -> c0d0
+ next if ( $devname =~ m/dm-/ );
next DEVICE if ( $devname =~ m/$existing_device/ );
}
====== munin-node.conf ======
**Vzdy doplnte hostname server.domena.cz**, z neznamych (cti: dementnich) duvodu se neaktualizuje ''munin-spool/datafile'', ze ktereho se pak generuji grafy a cely html xicht, pokud nesouhlasi jmeno na serveru munin [ahoj.example.cz] s tim, ktere zahlasi client. A jen kvuli tomu se vse zahodi :(.