Merge pull request #1580 from ceph/fix_check_pgs

Common: Improve check pgs
pull/1419/merge
Sébastien Han 2017-06-02 12:11:05 +02:00 committed by GitHub
commit bd4a7dd6c8
1 changed files with 1 additions and 1 deletions

View File

@ -6,7 +6,7 @@ CEPH_CLI="--name client.bootstrap-osd --keyring /var/lib/ceph/bootstrap-osd/{{ c
check_pgs() {
while [ $RETRIES -ne 0 ]; do
ceph $CEPH_CLI -s | grep -sq 'active+clean'
test "$(ceph $CEPH_CLI -s | grep pgmap | sed -r 's/.*: ([0-9]+) pgs.*/\1/g')" -eq "$(ceph $CEPH_CLI -s | egrep '\sactive\+clean' | sed -r 's/[^0-9]*//g')" && ceph $CEPH_CLI health | egrep -sq "HEALTH_OK|HEALTH_WARN"
RET=$?
test $RET -eq 0 && exit 0
sleep $DELAY