mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-09-20 09:33:19 +00:00
[chrony] switch from bash to sh; fix shell style issues
This commit is contained in:
parent
39976312f7
commit
6cb29a3bf3
1 changed files with 5 additions and 5 deletions
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/bash
|
#!/bin/sh
|
||||||
#
|
#
|
||||||
# Script to parse Chrony Tracking Output
|
# Script to parse Chrony Tracking Output
|
||||||
#
|
#
|
||||||
|
@ -52,11 +52,11 @@ if [ "$1" = "config" ]; then
|
||||||
echo 'graph_category time'
|
echo 'graph_category time'
|
||||||
i=0
|
i=0
|
||||||
for a in $fields ; do
|
for a in $fields ; do
|
||||||
i=$(expr $i + 1);
|
i=$((i + 1))
|
||||||
word=`echo $fieldnames | cut -f $i -d '='`;
|
word="$(echo "$fieldnames" | cut -f "$i" -d '=')"
|
||||||
factor=`echo $fieldfactors | cut -f $i -d ' '`;
|
factor="$(echo "$fieldfactors" | cut -f "$i" -d ' ')"
|
||||||
echo "$a.label $word$factor)";
|
echo "$a.label $word$factor)";
|
||||||
echo "$a.type GAUGE";
|
echo "$a.type GAUGE"
|
||||||
done
|
done
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue