]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/cephfs: fix test_evict_client 28613/head
authorYan, Zheng <zyan@redhat.com>
Wed, 5 Jun 2019 14:04:22 +0000 (22:04 +0800)
committerPatrick Donnelly <pdonnell@redhat.com>
Mon, 17 Jun 2019 20:13:27 +0000 (13:13 -0700)
explictly kill stale session, otherwise session count check is racy.

Fixes: https://tracker.ceph.com/issues/40173
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
(cherry picked from commit 4fd0202fdf0410d788402f6eefda44b79cf0a643)

qa/tasks/cephfs/test_misc.py

index dd1ff2b752873c221dbdd0d0af3c374ac7a7695f..dae8eb03b2ccefe77e7eed690738bf8cb6b1c9e5 100644 (file)
@@ -123,6 +123,7 @@ class TestMisc(CephFSTestCase):
         ls_data = self.fs.mds_asok(['session', 'ls'])
         self.assert_session_count(1, ls_data)
 
+        mount_a_client_id = self.mount_a.get_global_id()
         self.mount_a.kill()
         self.mount_a.kill_cleanup()
 
@@ -130,6 +131,8 @@ class TestMisc(CephFSTestCase):
         ls_data = self.fs.mds_asok(['session', 'ls'])
         self.assert_session_count(1, ls_data)
 
+        self.fs.mds_asok(['session', 'evict', "%s" % mount_a_client_id])
+
         self.mount_a.mount()
         self.mount_a.wait_until_mounted()
         self.mount_b.mount()