]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
qa/cephfs: add session_timeout option support 37840/head
authorXiubo Li <xiubli@redhat.com>
Tue, 20 Oct 2020 05:26:33 +0000 (01:26 -0400)
committerNathan Cutler <ncutler@suse.com>
Tue, 27 Oct 2020 08:30:46 +0000 (09:30 +0100)
When the mds revoking the Fwbl caps, the clients need to flush
the dirty data back to the OSDs, but the flush may make the OSDs
to be overloaded and slow, which may take more than 60 seconds to
finish. Then the MDS daemons will report the WRN messages.

For the teuthology test cases, let's just increase the timeout
value to make it work.

Fixes: https://tracker.ceph.com/issues/47565
Signed-off-by: Xiubo Li <xiubli@redhat.com>
(cherry picked from commit 0422673b6150df851a4ea1662637a77585cde52d)

qa/cephfs/overrides/session_timeout.yaml [new file with mode: 0644]
qa/suites/fs/basic_workload/overrides/session_timeout.yaml [new symlink]
qa/suites/fs/thrash/overrides/session_timeout.yaml [new symlink]
qa/suites/fs/verify/overrides/session_timeout.yaml [new symlink]
qa/tasks/ceph.py
qa/tasks/cephfs/filesystem.py
qa/tasks/vstart_runner.py

diff --git a/qa/cephfs/overrides/session_timeout.yaml b/qa/cephfs/overrides/session_timeout.yaml
new file mode 100644 (file)
index 0000000..a7a1633
--- /dev/null
@@ -0,0 +1,4 @@
+overrides:
+  ceph:
+    cephfs:
+      session_timeout: 300
diff --git a/qa/suites/fs/basic_workload/overrides/session_timeout.yaml b/qa/suites/fs/basic_workload/overrides/session_timeout.yaml
new file mode 120000 (symlink)
index 0000000..fce0318
--- /dev/null
@@ -0,0 +1 @@
+.qa/cephfs/overrides/session_timeout.yaml
\ No newline at end of file
diff --git a/qa/suites/fs/thrash/overrides/session_timeout.yaml b/qa/suites/fs/thrash/overrides/session_timeout.yaml
new file mode 120000 (symlink)
index 0000000..fce0318
--- /dev/null
@@ -0,0 +1 @@
+.qa/cephfs/overrides/session_timeout.yaml
\ No newline at end of file
diff --git a/qa/suites/fs/verify/overrides/session_timeout.yaml b/qa/suites/fs/verify/overrides/session_timeout.yaml
new file mode 120000 (symlink)
index 0000000..fce0318
--- /dev/null
@@ -0,0 +1 @@
+.qa/cephfs/overrides/session_timeout.yaml
\ No newline at end of file
index fc303087e79cc7a161a15c92ff70b331dc7f37de..ae2d587ffd48ddfffdfc612b76f59824968a4267 100644 (file)
@@ -1729,6 +1729,13 @@ def task(ctx, config):
             cephfs:
               max_mds: 2
 
+    To change the mdsmap's default session_timeout (60 seconds), use::
+
+        tasks:
+        - ceph:
+            cephfs:
+              session_timeout: 300
+
     Note, this will cause the task to check the /scratch_devs file on each node
     for available devices.  If no such file is found, /dev/sdb will be used.
 
index 1e9ad4b3c019832aca08dcf8567aac9bb3c85d82..09f44a1f5f8e0d2d50ed4eb89b30943daac8c6dd 100644 (file)
@@ -515,6 +515,9 @@ class Filesystem(MDSCluster):
     def set_max_mds(self, max_mds):
         self.set_var("max_mds", "%d" % max_mds)
 
+    def set_session_timeout(self, timeout):
+        self.set_var("session_timeout", "%d" % timeout)
+
     def set_allow_standby_replay(self, yes):
         self.set_var("allow_standby_replay", str(yes).lower())
 
@@ -582,6 +585,11 @@ class Filesystem(MDSCluster):
             if max_mds > 1:
                 self.set_max_mds(max_mds)
 
+            # If absent will use the default value (60 seconds)
+            session_timeout = self.fs_config.get('session_timeout', 60)
+            if session_timeout != 60:
+                self.set_session_timeout(session_timeout)
+
         self.getinfo(refresh = True)
 
         
index a2199483b72c310448c66923be59b3d51b5afa61..f815c9e6f88df236b54f9758122947cecda70675 100644 (file)
@@ -742,6 +742,7 @@ class LocalFilesystem(Filesystem, LocalMDSCluster):
         self.metadata_overlay = False
         self.data_pool_name = None
         self.data_pools = None
+        self.fs_config = None
 
         # Hack: cheeky inspection of ceph.conf to see what MDSs exist
         self.mds_ids = set()