]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mon: respect standby_for_fscid when choosing standby replay mds 21510/head
authorYan, Zheng <zyan@redhat.com>
Thu, 19 Apr 2018 02:44:11 +0000 (10:44 +0800)
committerYan, Zheng <zyan@redhat.com>
Thu, 19 Apr 2018 13:36:26 +0000 (21:36 +0800)
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
src/mon/MDSMonitor.cc

index 81989c2d76d7fe61915194ae93c884ee18bbc4bc..ea8c978cb72903c6269822e95d82f313716db985 100644 (file)
@@ -1970,6 +1970,10 @@ bool MDSMonitor::maybe_promote_standby(std::shared_ptr<Filesystem> &fs)
 
       // check everyone
       for (const auto &p : pending.filesystems) {
+       if (info.standby_for_fscid != FS_CLUSTER_ID_NONE &&
+           info.standby_for_fscid != p.first)
+         continue;
+
        bool assigned = false;
         const auto &fs = p.second;
         const MDSMap &mds_map = fs->mds_map;