mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-07-22 22:25:23 +00:00
Update multibandwidth
Correction of a bug with spaces when there was an output of more than 2 digits
This commit is contained in:
parent
aa3cd8311c
commit
d638d14a41
1 changed files with 1 additions and 1 deletions
|
@ -91,7 +91,7 @@ for host in $hosts; do
|
||||||
#bing output example: host: 4.592Mbps 0.223ms 0.217773us/bit
|
#bing output example: host: 4.592Mbps 0.223ms 0.217773us/bit
|
||||||
bing localhost "$host" -n -c 1 -e "$samples" -s "$small_packet_size" -S "$big_packet_size" 2>/dev/null \
|
bing localhost "$host" -n -c 1 -e "$samples" -s "$small_packet_size" -S "$big_packet_size" 2>/dev/null \
|
||||||
| grep -E "bit$" \
|
| grep -E "bit$" \
|
||||||
| cut -d " " -f3 \
|
| awk -F" +" '{ print $2}' | cut -c -5 \
|
||||||
| cut -c -5 \
|
| cut -c -5 \
|
||||||
| awk '{a+=$1} END{print a/NR}'
|
| awk '{a+=$1} END{print a/NR}'
|
||||||
done
|
done
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue