]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
qa: fix journal flush failure issue due to the MDS daemon crashes 51507/head
authorXiubo Li <xiubli@redhat.com>
Fri, 5 May 2023 10:41:54 +0000 (18:41 +0800)
committerXiubo Li <xiubli@redhat.com>
Fri, 9 Jun 2023 02:01:03 +0000 (10:01 +0800)
After the MDS daemon crashing, the journal flush request will fail.

Signed-off-by: Xiubo Li <xiubli@redhat.com>
(cherry picked from commit d851a9475c30d0b6fa4418c38d04fd602bc785eb)

qa/tasks/cephfs/test_misc.py

index e72f5a59963a1b036dcb550d69cde62c8e1a85e8..2405b7a9f771954db6314241a8cb00c35f4d152d 100644 (file)
@@ -472,14 +472,15 @@ class TestSkipReplayInoTable(CephFSTestCase):
         # This will make the MDS crash, since we only have one MDS in the
         # cluster and without the "wait=False" it will stuck here forever.
         self.mount_a.run_shell(["mkdir", "test_alloc_ino/dir1"], wait=False)
-        self.fs.mds_asok(['flush', 'journal'])
+
+        # sleep 10 seconds to make sure the journal logs are flushed and
+        # the mds crashes
+        time.sleep(10)
 
         # Now set the mds config to skip replaying the inotable
         self.fs.set_ceph_conf('mds', 'mds_inject_skip_replaying_inotable', True)
         self.fs.set_ceph_conf('mds', 'mds_wipe_sessions', True)
 
-        # sleep 5 seconds to make sure the journal log is flushed and applied
-        time.sleep(5)
         self.fs.mds_restart()
         # sleep 5 seconds to make sure the mds tell command won't stuck
         time.sleep(5)