[SERVER-13627] Disallow 0-vote arbiters Created: 17/Apr/14  Updated: 27/Oct/15  Resolved: 03/Jun/14

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: 2.6.0
Fix Version/s: 2.7.2

Type: Bug Priority: Major - P3
Reporter: Asya Kamsky Assignee: Matt Dannenberg
Resolution: Done Votes: 0
Labels: cap-ticket-needed, pull-request
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to SERVER-15838 Wrong error code from replSetInitiate... Closed
is related to DOCS-4320 Make clear that arbiters cannot have ... Closed
Tested
Backwards Compatibility: Minor Change
Operating System: ALL
Participants:

 Description   

I was able to reconfigure giving arbiter node "votes:0" which was accepted. This seems very wrong and we should reject that as invalid combination of options.

[conn1] command admin.$cmd command: replSetReconfig { replSetReconfig: 
     { _id: "asyaRS", 
       version: 64512.0, 
       members: [ 
           { _id: 0.0, host: "localhost:27017", priority: 2.0 }, 
           { _id: 1.0, host: "localhost:29017", votes: 0.0, priority: 0.0, hidden: true }, 
           { _id: 2.0, host: "localhost:33333", votes: 0.0, priority: 0.0, arbiterOnly: true } 
        ] 
       } } keyUpdates:0 numYields:0 locks(micros) W:1447 w:263 reslen:37 6ms



 Comments   
Comment by Githook User [ 12/Nov/14 ]

Author:

{u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}

Message: SERVER-13627 Test that replSetReconfig prohibits 0-vote arbiter.

This re-applies commit 6eccc037b1e6d22d60d0e7aec39dcc183a756790 with a fix
for occasional failures of zero_vote_arbiter.js:

Don't assume that the first member started is always the primary.

Closes #856

Signed-off-by: Benety Goh <benety@mongodb.com>
Branch: master
https://github.com/mongodb/mongo/commit/3ebd970fb88d0fb9494f894e3d78d66930ad71e2

Comment by Githook User [ 04/Nov/14 ]

Author:

{u'username': u'milkie', u'name': u'Eric Milkie', u'email': u'milkie@10gen.com'}

Message: Revert "SERVER-13627 Test that replSetReconfig prohibits 0-vote arbiter."

This reverts commit 6eccc037b1e6d22d60d0e7aec39dcc183a756790.
Branch: master
https://github.com/mongodb/mongo/commit/6d0405b1d94e1dd05ffba500f0c3a071202fd1d4

Comment by Githook User [ 04/Nov/14 ]

Author:

{u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}

Message: SERVER-13627 Test that replSetReconfig prohibits 0-vote arbiter.

Closes #856

Signed-off-by: Benety Goh <benety@mongodb.com>
Branch: master
https://github.com/mongodb/mongo/commit/6eccc037b1e6d22d60d0e7aec39dcc183a756790

Comment by Eric Milkie [ 15/Oct/14 ]

After some discussion, we decided that the state should be UNKNOWN and this is expected behavior, when dealing with mixed replica sets and invalid configs.

Comment by A. Jesse Jiryu Davis [ 15/Oct/14 ]

Adding a 2.8 arbiter with 0 votes to a 2.6 replica set appears to work (replSetReconfig returns "ok"). But the arbiter itself logs "REPLSETS [rsStart] replSet cfg parsing exception for members[3] arbiter must vote (cannot have 0 votes)" and refuses to join. It remains in state UNKNOWN. Is this as designed, or should it move to state REMOVED?

Comment by Eric Milkie [ 15/Oct/14 ]

jesse to confirm, were you testing a build with "--replication-implementation=impl"?

Comment by A. Jesse Jiryu Davis [ 15/Oct/14 ]

There are two error codes associated with this prohibition: trying to add a 0-vote arbiter with replSetReconfig causes an error 13135, but trying to replSetInitiate with an initial config that includes a 0-vote arbiter causes error 93. Is this expected or a bug?

Comment by Githook User [ 03/Jun/14 ]

Author:

{u'username': u'dannenberg', u'name': u'matt dannenberg', u'email': u'matt.dannenberg@10gen.com'}

Message: SERVER-13627 disallow 0-vote arbiters
Branch: master
https://github.com/mongodb/mongo/commit/7f74dfc223f6aafac1c01ae12da8db52bbf25a59

Comment by Matt Dannenberg [ 30/May/14 ]

reopening due to revert due to majority.js depending on the bad behavior

Comment by Githook User [ 30/May/14 ]

Author:

{u'username': u'dannenberg', u'name': u'matt dannenberg', u'email': u'matt.dannenberg@10gen.com'}

Message: Revert "SERVER-13627 disallow 0-vote arbiters"

This reverts commit 07838d04bece908d12d7f0ded46a0a75ff77608f.
Branch: master
https://github.com/mongodb/mongo/commit/66681e760ad6d5d361128cda94e08a4c9380a312

Comment by Githook User [ 30/May/14 ]

Author:

{u'username': u'dannenberg', u'name': u'matt dannenberg', u'email': u'matt.dannenberg@10gen.com'}

Message: SERVER-13627 disallow 0-vote arbiters
Branch: master
https://github.com/mongodb/mongo/commit/07838d04bece908d12d7f0ded46a0a75ff77608f

Generated at Thu Feb 08 03:32:20 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.