mirror of
https://github.com/munin-monitoring/contrib.git
synced 2025-09-19 09:03:20 +00:00
Fix bug with Gibibyte
This commit is contained in:
parent
617994ca9d
commit
7a05e29c76
1 changed files with 3 additions and 3 deletions
|
@ -13,7 +13,7 @@ fi
|
||||||
|
|
||||||
top -un | nawk '
|
top -un | nawk '
|
||||||
function scale(v) {
|
function scale(v) {
|
||||||
if (value ~ /G$/) { sub("G", "", v); v *= 1024 }
|
if (v ~ /G$/) { sub("G", "", v);v *= 1024 }
|
||||||
else if (v ~ /M$/) sub("M", "", v)
|
else if (v ~ /M$/) sub("M", "", v)
|
||||||
else if (v ~ /K$/) { sub("K", "", v);v /= 1024 }
|
else if (v ~ /K$/) { sub("K", "", v);v /= 1024 }
|
||||||
else v /= 1024 * 1024;
|
else v /= 1024 * 1024;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue