From b51a929c6f70e68b503db92754ef40033b095530 Mon Sep 17 00:00:00 2001 From: John Spray Date: Wed, 28 Oct 2015 14:28:42 +0900 Subject: [PATCH] tasks/cephfs: quick test for `tell`... ...specifically that we don't have lingering MDS sessions after running it. This is testing that Client::shutdown is doing the right thing and closing sessions. Signed-off-by: John Spray --- tasks/cephfs/test_sessionmap.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/tasks/cephfs/test_sessionmap.py b/tasks/cephfs/test_sessionmap.py index 70ee1984dde02..fcf92fe9ca0e3 100644 --- a/tasks/cephfs/test_sessionmap.py +++ b/tasks/cephfs/test_sessionmap.py @@ -10,6 +10,20 @@ class TestSessionMap(CephFSTestCase): CLIENTS_REQUIRED = 2 MDSS_REQUIRED = 2 + def test_tell_session_drop(self): + """ + That when a `tell` command is sent using the python CLI, + its MDS session is gone after it terminates + """ + self.mount_a.umount_wait() + self.mount_b.umount_wait() + + mds_id = self.fs.get_lone_mds_id() + self.fs.mon_manager.raw_cluster_cmd("tell", "mds.{0}".format(mds_id), "session", "ls") + + ls_data = self.fs.mds_asok(['session', 'ls']) + self.assertEqual(len(ls_data), 0) + def test_version_splitting(self): """ That when many sessions are updated, they are correctly -- 2.39.5