first version with combined plugin for pressure, temperature, and power
This commit is contained in:
@@ -8,9 +8,9 @@ Personally, I use them for checking mainly temperatures, pressures and earned en
|
|||||||
- prerequisite is of course a running munin installation on the local host
|
- prerequisite is of course a running munin installation on the local host
|
||||||
- to install the plugins:
|
- to install the plugins:
|
||||||
- git checkout https://github.com/john30/ebusd-munin.git
|
- git checkout https://github.com/john30/ebusd-munin.git
|
||||||
- chmod a+x ebusd-munin/plugins/*
|
- sudo cp ebusd-munin/plugins/* /usr/share/munin/plugins/
|
||||||
- sudo cp ebusd-munin/plugins/* /etc/munin/plugins
|
|
||||||
- sudo munin-node-configure --shell
|
- sudo munin-node-configure --shell
|
||||||
- run all "ln -s" commands printed by munin-node-configure
|
- run all "ln -s" commands printed by munin-node-configure and containing "ebusd_"
|
||||||
- sudo service munin-node reload
|
- sudo service munin-node reload
|
||||||
- that's it
|
|
||||||
|
that's it.
|
||||||
|
|||||||
Executable
+46
@@ -0,0 +1,46 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
#%# family=auto
|
||||||
|
#%# capabilities=autoconf
|
||||||
|
#%# capabilities=suggest
|
||||||
|
. $MUNIN_LIBDIR/plugins/plugin.sh
|
||||||
|
if [ "$1" = "autoconf" ]; then
|
||||||
|
echo "yes"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
if [ "$1" = "suggest" ]; then
|
||||||
|
echo "temp"
|
||||||
|
echo "press"
|
||||||
|
echo "power"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
prefix=`basename "$0"`
|
||||||
|
if [ "$prefix" = "ebusd_temp" ]; then
|
||||||
|
sensors="outsidetemp BrineTempInput BrineTempOutput FlowTemp mcFlowTempSensor hwTankTemp"
|
||||||
|
elif [ "$prefix" = "ebusd_press" ]; then
|
||||||
|
sensors="BrinePress HeatSystemPress VaporPressHigh VaporPressLow"
|
||||||
|
else
|
||||||
|
sensors="ActualEnvironmentPower"
|
||||||
|
fi
|
||||||
|
if [ "$1" = "config" ]; then
|
||||||
|
if [ "$prefix" = "ebusd_temp" ]; then
|
||||||
|
echo "graph_title ebusd Temperaturen"
|
||||||
|
echo "graph_vlabel Grad"
|
||||||
|
elif [ "$prefix" = "ebusd_press" ]; then
|
||||||
|
echo "graph_title ebusd Drucksensoren"
|
||||||
|
echo "graph_vlabel Bar"
|
||||||
|
else
|
||||||
|
echo "graph_title ebusd Ertrag"
|
||||||
|
echo "graph_vlabel kW"
|
||||||
|
fi
|
||||||
|
echo 'graph_category Heizung'
|
||||||
|
for sensor in $sensors; do
|
||||||
|
echo ${prefix}_${sensor}.label $sensor
|
||||||
|
print_warning ${prefix}_$sensor
|
||||||
|
print_critical ${prefix}_$sensor
|
||||||
|
done
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
for sensor in $sensors; do
|
||||||
|
RESULT=`echo "r $sensor"|nc localhost 8888 2>/dev/null|head -n 1|sed -e 's#;.*$##'`
|
||||||
|
echo ${prefix}_${sensor}.value $RESULT
|
||||||
|
done
|
||||||
Reference in New Issue
Block a user