Correct the grep pattern for ceph_healh_ok.

This commit is contained in:
gardouille 2015-08-28 09:45:34 +02:00
parent b0bcbb780c
commit 28c4688f13
1 changed files with 2 additions and 2 deletions

View File

@ -71,11 +71,11 @@ if [ -f /etc/ceph/*.keyring ]; then
printf '%b' "\n${MAGENTA}+ ${WHITEB}${keyring}: ${CEPH_COLOR}${CEPH_HEALTH}"
done
# Else use default
# Else use default
elif [ -f /etc/ceph/ceph.conf ]; then
printf '%b' "\n${MAGENTA}++++++++++++++++++++++++ ${WHITEB}Ceph${RESET} ${MAGENTA}:++++++++++++++++++++++++${RESET}"
CEPH_HEALTH=$(ceph health)
CEPH_HEALTH_OK=$(ceph health | grep -i -- 'ok')
CEPH_HEALTH_OK=$(ceph health | grep -i -- 'health_ok')
# Test health to determine the color to use
if [ ${CEPH_HEALTH_OK} ]; then