From c47626a82d93e49b57d012063e16461f9df2971b Mon Sep 17 00:00:00 2001 From: UltimateByte Date: Tue, 26 Jul 2016 17:23:36 +0200 Subject: [PATCH] Added cached memory varible Will cause no error if "cached:" doesn't exist --- lgsm/functions/info_distro.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lgsm/functions/info_distro.sh b/lgsm/functions/info_distro.sh index b75499f3d..7c5c261c7 100644 --- a/lgsm/functions/info_distro.sh +++ b/lgsm/functions/info_distro.sh @@ -63,6 +63,7 @@ fi physmemtotal=$(free ${humanreadable} | awk '/Mem:/ {print $2}') physmemused=$(free ${humanreadable} | awk '/Mem:/ {print $3}') physmemfree=$(free ${humanreadable} | awk '/Mem:/ {print $4}') +pysmemcached=$(free ${humanreadable} | awk '/cache:/ {print $4}') swaptotal=$(free ${humanreadable} | awk '/Swap:/ {print $2}') swapused=$(free ${humanreadable} | awk '/Swap:/ {print $3}') swapfree=$(free ${humanreadable} | awk '/Swap:/ {print $4}') @@ -111,4 +112,4 @@ if [ -d "${backupdir}" ]; then # size of most recent backup. lastbackupsize=$(du -h "${lastbackup}" | awk '{print $1}') -fi \ No newline at end of file +fi