mirror of
https://github.com/pstadler/metrics.sh.git
synced 2025-02-28 13:59:12 -05:00
fix metrics on Ubuntu
This commit is contained in:
parent
ff5bc25eec
commit
470ed0a828
@ -21,7 +21,9 @@ if is_osx; then
|
||||
}
|
||||
else
|
||||
__disk_io_bgproc () {
|
||||
echo $(iostat -y -d 1 $DISK_IO_MOUNTPOINT)
|
||||
iostat -y -m -d 1 $DISK_IO_MOUNTPOINT | while read line; do
|
||||
echo $line | awk '/[0-9.]/{ print $3 }' > $__disk_io_fifo
|
||||
done
|
||||
}
|
||||
fi
|
||||
|
||||
|
@ -13,8 +13,8 @@ if is_osx; then
|
||||
}
|
||||
else
|
||||
collect () {
|
||||
report $(free | awk '/buffers\/cache/
|
||||
{ printf "%.1f", 100 - $4 / ($3 + $4) * 100.0 }')
|
||||
report $(free | awk '/buffers\/cache/ {
|
||||
printf "%.1f", 100 - $4 / ($3 + $4) * 100.0 }')
|
||||
}
|
||||
fi
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user