mirror of
https://github.com/munin-monitoring/contrib.git
synced 2018-11-08 00:59:34 +01:00
Plugins tc_*: check existence of "tc" during autoconf
This commit is contained in:
parent
272220c61a
commit
6995742e59
@ -50,10 +50,12 @@ mytc() {
|
||||
|
||||
case "$1" in
|
||||
autoconf)
|
||||
if [ -r /proc/net/dev ]; then
|
||||
echo yes
|
||||
else
|
||||
if [ ! -r /proc/net/dev ]; then
|
||||
echo "no (/proc/net/dev not found)"
|
||||
elif [ ! -x /sbin/tc ]; then
|
||||
echo "no (missing 'tc' executable)"
|
||||
else
|
||||
echo yes
|
||||
fi
|
||||
exit 0
|
||||
;;
|
||||
|
@ -21,10 +21,12 @@ mytc() {
|
||||
|
||||
case $1 in
|
||||
autoconf)
|
||||
if [ -r /proc/net/dev ]; then
|
||||
echo yes
|
||||
else
|
||||
if [ ! -r /proc/net/dev ]; then
|
||||
echo "no (/proc/net/dev not found)"
|
||||
elif ! which tc >/dev/null; then
|
||||
echo "no (missing 'tc' executable)"
|
||||
else
|
||||
echo yes
|
||||
fi
|
||||
exit 0
|
||||
;;
|
||||
|
@ -21,10 +21,12 @@ mytc() {
|
||||
|
||||
case $1 in
|
||||
autoconf)
|
||||
if [ -r /proc/net/dev ]; then
|
||||
echo yes
|
||||
else
|
||||
if [ ! -r /proc/net/dev ]; then
|
||||
echo "no (/proc/net/dev not found)"
|
||||
elif ! which tc >/dev/null; then
|
||||
echo "no (missing 'tc' executable)"
|
||||
else
|
||||
echo yes
|
||||
fi
|
||||
exit 0
|
||||
;;
|
||||
|
Loading…
Reference in New Issue
Block a user