]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: print subtrees only after merge 17712/head
authorPatrick Donnelly <pdonnell@redhat.com>
Mon, 4 Sep 2017 18:36:00 +0000 (11:36 -0700)
committerPatrick Donnelly <pdonnell@redhat.com>
Thu, 14 Sep 2017 03:30:02 +0000 (20:30 -0700)
During up:resolve, the MDS tries to merge each subtree with its parent. During
testing, QE found that many thousands of subtrees in a directory (made possible
using pins) would cause the MDS to spend minutes printing out subtree maps to
the debug log. This causes the heartbeat code to consider the MDS as stalled so
beacons are no longer sent to the mons resulting in the MDS being removed from
the rank.

A more complete solution to this problem is to selectively print subtrees
relating to the operation (e.g. the subtree and its parents).

Fixes: http://tracker.ceph.com/issues/21221
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1485783
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
(cherry picked from commit d0747a37fd06053b2206bb9a952f7ab77f0db2f0)

src/mds/MDCache.cc

index e6600dbd4ea77e4cd6b10d2fb93842c24299f505..17023bb205053b1d05db93f1c664e5ef6cd18880 100644 (file)
@@ -941,9 +941,9 @@ void MDCache::try_subtree_merge_at(CDir *dir, set<CInode*> *to_eval)
 
     if (to_eval && dir->get_inode()->is_auth())
       to_eval->insert(dir->get_inode());
-  } 
 
-  show_subtrees(15);
+    show_subtrees(15);
+  }
 }
 
 void MDCache::subtree_merge_writebehind_finish(CInode *in, MutationRef& mut)