]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
qa/tasks/ceph_manager: avoid test_map_discontinuity stall with too few up osds
authorSage Weil <sage@redhat.com>
Wed, 6 Sep 2017 17:27:33 +0000 (13:27 -0400)
committerSage Weil <sage@redhat.com>
Tue, 20 Nov 2018 23:12:43 +0000 (17:12 -0600)
Some tests have m=2,k=2 and this will break them.  Sometimes even if we
have 5 up osds, we end up with 4 and CRUSH gets picky, so build in a
buffer and only do this if we have 6 up.

We don't have an easy way from here to see what the min up osds for healthy
is...  basically this map discontinuity test just sucks.

Signed-off-by: Sage Weil <sage@redhat.com>
qa/tasks/ceph_manager.py

index 5b579937d1562eef43573a9c874a5b080e83ef74..37aff1b262a35169804464966b27d1aca20705b2 100644 (file)
@@ -998,7 +998,8 @@ class Thrasher:
                     self.ceph_manager.raw_cluster_cmd('osd', 'reweight',
                                                       str(osd), str(1))
                 if random.uniform(0, 1) < float(
-                        self.config.get('chance_test_map_discontinuity', 0)):
+                        self.config.get('chance_test_map_discontinuity', 0)) \
+                        and len(self.live_osds) > 5: # avoid m=2,k=2 stall, w/ some buffer for crush being picky
                     self.test_map_discontinuity()
                 else:
                     self.ceph_manager.wait_for_recovery(