From 5503b2014c5c56e11da7b739262771876c86c732 Mon Sep 17 00:00:00 2001 From: Patrick Donnelly Date: Thu, 12 Apr 2018 23:05:22 -0700 Subject: [PATCH] qa: remove use of mds deactivate Signed-off-by: Patrick Donnelly --- qa/tasks/cephfs/filesystem.py | 7 ------- qa/tasks/cephfs/test_failover.py | 2 -- qa/tasks/cephfs/test_strays.py | 11 ++--------- 3 files changed, 2 insertions(+), 18 deletions(-) diff --git a/qa/tasks/cephfs/filesystem.py b/qa/tasks/cephfs/filesystem.py index a90c99d215fb6..f0c5d089399dc 100644 --- a/qa/tasks/cephfs/filesystem.py +++ b/qa/tasks/cephfs/filesystem.py @@ -432,13 +432,6 @@ class Filesystem(MDSCluster): raise RuntimeError("cannot specify fscid when configuring overlay") self.metadata_overlay = overlay - def deactivate(self, rank): - if rank < 0: - raise RuntimeError("invalid rank") - elif rank == 0: - raise RuntimeError("cannot deactivate rank 0") - self.mon_manager.raw_cluster_cmd("mds", "deactivate", "%d:%d" % (self.id, rank)) - def set_var(self, var, *args): a = map(str, args) self.mon_manager.raw_cluster_cmd("fs", "set", self.name, var, *a) diff --git a/qa/tasks/cephfs/test_failover.py b/qa/tasks/cephfs/test_failover.py index 3306e9441c712..2c1559af2b834 100644 --- a/qa/tasks/cephfs/test_failover.py +++ b/qa/tasks/cephfs/test_failover.py @@ -277,7 +277,6 @@ class TestStandbyReplay(CephFSTestCase): # Shrink the cluster fs_a.set_max_mds(1) - fs_a.mon_manager.raw_cluster_cmd("mds", "deactivate", "{0}:1".format(fs_a.name)) self.wait_until_equal( lambda: fs_a.get_active_names(), [mds_a], 60 @@ -424,7 +423,6 @@ class TestMultiFilesystems(CephFSTestCase): # Shrink fs_b back to 1, see a daemon go back to standby fs_b.set_max_mds(1) - fs_b.deactivate(1) self.wait_until_equal(lambda: len(fs_b.get_active_names()), 1, 30, reject_fn=lambda v: v > 2 or v < 1) diff --git a/qa/tasks/cephfs/test_strays.py b/qa/tasks/cephfs/test_strays.py index ea73ae2c0917e..5cc17f52e8ca9 100644 --- a/qa/tasks/cephfs/test_strays.py +++ b/qa/tasks/cephfs/test_strays.py @@ -579,7 +579,6 @@ class TestStrays(CephFSTestCase): # Shut down rank 1 self.fs.set_max_mds(1) - self.fs.deactivate(1) # It shouldn't proceed past stopping because its still not allowed # to purge @@ -593,10 +592,7 @@ class TestStrays(CephFSTestCase): "--mds_max_purge_files 100") # It should now proceed through shutdown - self.wait_until_true( - lambda: self._is_stopped(1), - timeout=60 - ) + self.fs.wait_for_daemons(timeout=120) # ...and in the process purge all that data self.await_data_pool_empty() @@ -639,10 +635,7 @@ class TestStrays(CephFSTestCase): # Shut down rank 1 self.fs.set_max_mds(1) - self.fs.deactivate(1) - - # Wait til we get to a single active MDS mdsmap state - self.wait_until_true(lambda: self._is_stopped(1), timeout=120) + self.fs.wait_for_daemons(timeout=120) # See that the stray counter on rank 0 has incremented self.assertEqual(self.get_mdc_stat("strays_created", rank_0_id), 1) -- 2.39.5