[munin/uptime_switch] timeout plus faible, manifesteement munin n'aime pas les...

[munin/uptime_switch] timeout plus faible, manifesteement munin n'aime pas les tirets dans les noms de variables

darcs-hash:20090526141940-bd074-676eb42d7bbf85bb2226f8ce59875eb53f9138c5.gz
parent 11a4da6a
......@@ -18,13 +18,13 @@ if [ "$1" = "config" ]; then
echo 'graph_vlabel uptime in days'
for i in multiprise \
`host -l adm.crans.org | sed -ne 's/\(bat[a-u]-[0-9]\).*$/\1/p'`; do
echo "$i.label uptime $i"; done
echo "${i/-/}.label uptime $i"; done
exit 0
fi
for i in multiprise \
`host -l adm.crans.org | sed -ne 's/\(bat[a-u]-[0-9]\).*$/\1/p'`; do
(snmpget -O v -v 1 -c public $i sysUpTimeInstance 2> /dev/null || true) | \
perl -nle "{ /[0-9]+/; print sprintf(\"$i.value %.2f\", ($& / 8640000));}"&
snmpget -t 0.05 -O v -v 1 -c public $i sysUpTimeInstance 2> /dev/null | \
perl -nle "{ /\d+/; print sprintf(\"${i/-/}.value %.2f\", ($&/8640000));}"&
done
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment