"
This commit is contained in:
parent
c8d0b1dca7
commit
77e3975159
1 changed files with 4 additions and 4 deletions
|
@ -340,16 +340,16 @@ function get_disk_value {
|
|||
while read -r line; do
|
||||
echo $line | grep KiB | awk '/(free-hdd-space:)/ {
|
||||
gsub(/KiB/,"",$2)
|
||||
print free_disk.value $2 }'
|
||||
print "free_disk.value" $2 }'
|
||||
echo $line | grep MiB | awk '/(free-hdd-space:)/ {
|
||||
gsub(/MiB/,"",$2)
|
||||
print free_disk.value $2*1024}'
|
||||
print "free_disk.value" $2*1024}'
|
||||
echo $line | grep KiB | awk '/(total-hdd-space:)/ {
|
||||
gsub(/KiB/,"",$2)
|
||||
print total_disk.value $2 }'
|
||||
print "total_disk.value" $2 }'
|
||||
echo $line | grep MiB | awk '/(total-hdd-space:)/ {
|
||||
gsub(/MiB/,"",$2)
|
||||
print total_disk.value $2*1024}'
|
||||
print "total_disk.value" $2*1024}'
|
||||
done <<< "$data"
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue