Memory: Fixed inaccurate memory in Solaris

This commit is contained in:
Muhammad Herdiansyah 2017-01-05 13:55:28 +07:00
parent 7d65ae513d
commit c8bd5d4ea2
1 changed files with 1 additions and 1 deletions

View File

@ -1181,7 +1181,7 @@ get_memory() {
"Solaris") "Solaris")
mem_total="$(prtconf | awk '/Memory/ {print $3}')" mem_total="$(prtconf | awk '/Memory/ {print $3}')"
mem_free="$(($(sar -r 1 1 | awk 'NR==5 {print $2}') / 1024))" mem_free="$(($(vmstat | awk 'NR==3{printf $5}') / 1024))"
mem_used="$((mem_total - mem_free))" mem_used="$((mem_total - mem_free))"
;; ;;