mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-12-24 19:00:11 +01:00
added mpstat to healthcheck.sh
Signed-off-by: Janos SUTO <sj@acts.hu>
This commit is contained in:
parent
4659af3dd2
commit
25c9e116ed
@ -7,8 +7,15 @@ set -o nounset
|
|||||||
SPHINX_DIR=/var/piler/sphinx
|
SPHINX_DIR=/var/piler/sphinx
|
||||||
ERROR_FILE=/var/piler/stat/error
|
ERROR_FILE=/var/piler/stat/error
|
||||||
|
|
||||||
echo "host: $(hostname | sha256sum | awk '{ print $1 }')"
|
if command -v mpstat; then
|
||||||
echo "cpus: $(grep -c ^processor /proc/cpuinfo)"
|
mpstat
|
||||||
|
echo
|
||||||
|
else
|
||||||
|
echo "host: $(hostname)"
|
||||||
|
echo "cpus: $(grep -c ^processor /proc/cpuinfo)"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "load: $(cat /proc/loadavg)"
|
||||||
echo "mem: $(grep MemTotal /proc/meminfo | sed 's/MemTotal\s*:\s*//' )"
|
echo "mem: $(grep MemTotal /proc/meminfo | sed 's/MemTotal\s*:\s*//' )"
|
||||||
echo disks:
|
echo disks:
|
||||||
while read -r p; do df -h "${p##* }" | tail -1; done < <(lsblk | grep part)
|
while read -r p; do df -h "${p##* }" | tail -1; done < <(lsblk | grep part)
|
||||||
|
Loading…
Reference in New Issue
Block a user