diff options
author | Suren A. Chilingaryan <csa@suren.me> | 2019-08-25 03:49:35 +0200 |
---|---|---|
committer | Suren A. Chilingaryan <csa@suren.me> | 2019-08-25 03:49:35 +0200 |
commit | c8c277200169dfadf88dd176e5c056967550e059 (patch) | |
tree | ec1a519ef550c2206c7863503627388e343778a3 /remote/check_server_status.sh | |
parent | 5e6c83d51d0f52ecb464f137ad68f0bd1a83f5e4 (diff) | |
download | conky-c8c277200169dfadf88dd176e5c056967550e059.tar.gz conky-c8c277200169dfadf88dd176e5c056967550e059.tar.bz2 conky-c8c277200169dfadf88dd176e5c056967550e059.tar.xz conky-c8c277200169dfadf88dd176e5c056967550e059.zip |
Add remote services
Diffstat (limited to 'remote/check_server_status.sh')
-rwxr-xr-x | remote/check_server_status.sh | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/remote/check_server_status.sh b/remote/check_server_status.sh deleted file mode 100755 index 791ad12..0000000 --- a/remote/check_server_status.sh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/bash - -fs=`df -m | grep /dev/sda2 | sed -e 's/[[:space:]]\+/ /g' | cut -d ' ' -f 4` -mem=`free -m | grep "buffers/cache" | sed -e 's/[[:space:]]\+/ /g' | cut -d ' ' -f 4` -cpu=`uptime | sed -e "s/[[:space:]]/\n/g" | tail -n 1` - -if [ $fs -le 8192 ]; then - echo "Only $(($fs / 1024)) GB left in the file system" -fi - -if [ $mem -le 128 ]; then - echo "The system is starving on memory, $mem MB left free" -fi - -#Multiply by number of CPU cores -if [ `echo "$cpu < 0.98" | bc` -eq 0 ]; then - echo "The system is starving on cpu, $cpu is load average for the last 15 min" -fi |