]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/workunites/ceph-helpers.sh: do not bail when num_pg==0
authorSage Weil <sage@redhat.com>
Tue, 16 May 2017 21:25:04 +0000 (17:25 -0400)
committerSage Weil <sage@redhat.com>
Fri, 2 Jun 2017 17:02:11 +0000 (13:02 -0400)
Right after the cluster is created when the first mgr report hasn't come
in yet we will report 0 pgs.

Signed-off-by: Sage Weil <sage@redhat.com>
qa/workunits/ceph-helpers.sh

index 0bb099b205f3b2a9fbdba8cfcca3258766dc1024..fee18dc4d10c2a2a555cf9670bb44181df8b365c 100755 (executable)
@@ -1258,7 +1258,10 @@ function wait_for_clean() {
     local cur_active_clean
     local -a delays=($(get_timeout_delays $TIMEOUT .1))
     local -i loop=0
-    test $(get_num_pgs) != 0 || return 1
+
+    while test $(get_num_pgs) == 0 ; do
+       sleep 1
+    done
 
     while true ; do
         # Comparing get_num_active_clean & get_num_pgs is used to determine