From b436930779569330cde7b8a004a19f08423e278f Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Thu, 6 Mar 2014 12:35:19 -0800 Subject: [PATCH] qa/workunits/rest/test.py: do not test 'osd thrash' This wreaks havoc on our QA because it marks osds up and down and then immediately after that we try to scrub and some osds are still down. Adjust the CLI test to wait for all OSDs to come back up after thrashing. Signed-off-by: Sage Weil --- qa/workunits/cephtool/test.sh | 13 +++++++++++-- qa/workunits/rest/test.py | 1 - 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/qa/workunits/cephtool/test.sh b/qa/workunits/cephtool/test.sh index 0a65494a2e76..21b37f8a71de 100755 --- a/qa/workunits/cephtool/test.sh +++ b/qa/workunits/cephtool/test.sh @@ -283,6 +283,17 @@ for ((i=0; i < 100; i++)); do break fi done + +ceph osd thrash 10 +for ((i=0; i < 100; i++)); do + if ceph osd dump | grep 'down in'; then + echo "waiting for osd(s) to come back up" + sleep 10 + else + break + fi +done + ceph osd dump | grep 'osd.0 up' ceph osd find 1 ceph osd metadata 1 | grep 'distro' @@ -453,8 +464,6 @@ ceph osd pool set rbd cache_min_evict_age 234 ceph osd pool get rbd crush_ruleset | grep 'crush_ruleset: 0' -ceph osd thrash 10 - set +e diff --git a/qa/workunits/rest/test.py b/qa/workunits/rest/test.py index efedcb880ac8..2bf97718a4fc 100755 --- a/qa/workunits/rest/test.py +++ b/qa/workunits/rest/test.py @@ -431,5 +431,4 @@ if __name__ == '__main__': r = expect('osd/pool/get.json?pool=rbd&var=crush_ruleset', 'GET', 200, 'json') assert(r.myjson['output']['crush_ruleset'] == 0) - expect('osd/thrash?num_epochs=10', 'PUT', 200, '') print 'OK' -- 2.47.3