From 5de08f099bdafc351b24f2078d53b3c62d6bb2d7 Mon Sep 17 00:00:00 2001 From: "Yan, Zheng" Date: Thu, 19 Jan 2017 15:24:54 +0800 Subject: [PATCH] mds: add authority check for delay dirfrag split the dirfrag can be migareted to other mds while waiting in the timer. Fixes: http://tracker.ceph.com/issues/18487 Signed-off-by: "Yan, Zheng" --- src/mds/MDBalancer.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/mds/MDBalancer.cc b/src/mds/MDBalancer.cc index e16c40964eb5b..f3df8f1d2d2ec 100644 --- a/src/mds/MDBalancer.cc +++ b/src/mds/MDBalancer.cc @@ -400,6 +400,10 @@ void MDBalancer::queue_split(const CDir *dir, bool fast) dout(10) << "drop split on " << frag << " because not in cache" << dendl; return; } + if (!split_dir->is_auth()) { + dout(10) << "drop split on " << frag << " because non-auth" << dendl; + return; + } // Pass on to MDCache: note that the split might still not // happen if the checks in MDCache::can_fragment fail. -- 2.47.3