From 92200d9d10d30ed35f640fd1120be65577a3ce64 Mon Sep 17 00:00:00 2001 From: Venky Shankar Date: Sat, 7 Oct 2023 20:42:29 +0530 Subject: [PATCH 1/2] qa: lower mds_session_metadata_threshold for tests ... and increase the number of files that are created so as to hit the threshold with a high probability. Fixes: http://tracker.ceph.com/issues/62873 Signed-off-by: Venky Shankar --- qa/tasks/cephfs/test_client_limits.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/qa/tasks/cephfs/test_client_limits.py b/qa/tasks/cephfs/test_client_limits.py index 7f3a91b96f9bd..2a4c8e79e2f88 100644 --- a/qa/tasks/cephfs/test_client_limits.py +++ b/qa/tasks/cephfs/test_client_limits.py @@ -272,15 +272,14 @@ def test_client_blocklisted_oldest_tid(self): # Wait for the health warnings. Assume mds can handle 10 request per second at least self.wait_for_health("MDS_CLIENT_OLDEST_TID", max_requests // 10, check_in_detail=str(self.mount_a.client_id)) - # why a multiplier of 20, you may ask - I arrieved at this from some debugs - # that I put when testing the fix in a vstart cluster where its a ratio of - # encoded session information to the number of completed requests. - self.config_set('mds', 'mds_session_metadata_threshold', max_requests*20); + # set the threshold low so that it has a high probability of + # hitting. + self.config_set('mds', 'mds_session_metadata_threshold', 5000); - # Create a few more files synchronously. This would hit the session metadata threshold + # Create lot many files synchronously. This would hit the session metadata threshold # causing the client to get blocklisted. with self.assertRaises(CommandFailedError): - self.mount_a.create_n_files("testdir/file2", 20, True) + self.mount_a.create_n_files("testdir/file2", 100000, True) self.mds_cluster.is_addr_blocklisted(self.mount_a.get_global_addr()) # the mds should bump up the relevant perf counter From 5856a1e6b72dc77d3b4d9109385481b924e4fe36 Mon Sep 17 00:00:00 2001 From: Venky Shankar Date: Mon, 9 Oct 2023 09:59:45 +0530 Subject: [PATCH 2/2] qa: typo fix when checking for perf counter - s/md_thresh_evicted/mdthresh_evicted Signed-off-by: Venky Shankar --- qa/tasks/cephfs/test_client_limits.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qa/tasks/cephfs/test_client_limits.py b/qa/tasks/cephfs/test_client_limits.py index 2a4c8e79e2f88..6961f4c72183b 100644 --- a/qa/tasks/cephfs/test_client_limits.py +++ b/qa/tasks/cephfs/test_client_limits.py @@ -284,7 +284,7 @@ def test_client_blocklisted_oldest_tid(self): self.mds_cluster.is_addr_blocklisted(self.mount_a.get_global_addr()) # the mds should bump up the relevant perf counter pd = self.perf_dump() - self.assertGreater(pd['mds_sessions']['md_thresh_evicted'], 0) + self.assertGreater(pd['mds_sessions']['mdthresh_evicted'], 0) # reset the config self.config_set('client', 'client inject fixed oldest tid', 'false')