]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mon/Elector: ignore ACK from peers without required features
authorSage Weil <sage@inktank.com>
Wed, 9 Apr 2014 18:09:14 +0000 (11:09 -0700)
committerSage Weil <sage@inktank.com>
Wed, 9 Apr 2014 18:09:14 +0000 (11:09 -0700)
If an old peer gets a PROPOSE from us, we need to be sure to ignore their
ACK.  Ignoring their PROPOSEs isn't sufficient to keep them out of a
quorum.

Fixes: #8042
Signed-off-by: Sage Weil <sage@inktank.com>
src/mon/Elector.cc

index 3572c8b48c15acd234a725e6b80d0e9b08c274bc..539b291cd35e36b2ccb428c806b08730aea5884a 100644 (file)
@@ -278,6 +278,12 @@ void Elector::handle_ack(MMonElection *m)
     return;
   }
   assert(m->epoch == epoch);
+  if ((required_features ^ m->get_connection()->get_features()) &
+      required_features) {
+    dout(5) << " ignoring ack from mon" << from
+           << " without required features" << dendl;
+    return;
+  }
   
   if (electing_me) {
     // thanks