]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: add authority check for delay dirfrag split 12994/head
authorYan, Zheng <zyan@redhat.com>
Thu, 19 Jan 2017 07:24:54 +0000 (15:24 +0800)
committerYan, Zheng <zyan@redhat.com>
Thu, 19 Jan 2017 07:30:19 +0000 (15:30 +0800)
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" <zyan@redhat.com>
src/mds/MDBalancer.cc

index e16c40964eb5bfb4b029acedaf34ec8c8859eaf3..f3df8f1d2d2ec36ee82fe2be728890e0bd09ba39 100644 (file)
@@ -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.