Skip to content

Commit 12c707a

Browse files
author
Andrew Leung
committed
adding in information from the wiki
1 parent bd7a76b commit 12c707a

File tree

5 files changed

+31
-31
lines changed

5 files changed

+31
-31
lines changed

source/administration/replication-architectures.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -132,10 +132,10 @@ for these kinds of nodes:
132132
<replica-set-hidden-members>`.)
133133

134134
- **Voting**: This changes the number of votes that a member of the
135-
set node has in elections for primary. In general use priority to
135+
replica set has in elections. In general, use priority to
136136
control the outcome of elections, as weighting votes introduces
137-
operational complexities and risks set failure. Only modify the
138-
number of votes, if you need to have more than 7 members of a
137+
operational complexities and risks. Only modify the
138+
number of votes when you need to have more than 7 members in a
139139
replica set. (:ref:`see also <replica-set-non-voting-members>`.)
140140

141141
.. note::

source/core/replication-internals.txt

Lines changed: 10 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ modify the configuration of an existing replica set.
115115
Elections
116116
---------
117117

118-
When you initialize a replica set for the first time, and when any
118+
When you initialize a replica set for the first time, or when any
119119
failover occurs, an election takes place to decide which member should
120120
become :term:`primary`. A primary is the only member in the replica
121121
set that can accept write commands such as :func:`insert()
@@ -126,7 +126,7 @@ Elections are the process replica set members use to
126126
select the primary in a cluster. Elections follow two events:
127127
a primary that "steps down" or a :term:`secondary` that
128128
loses contact with a :term:`primary` member. All members have one vote
129-
in an election, and every :program:`mongod` can veto an election. A
129+
in an election, and any :program:`mongod` can veto an election. A
130130
single veto will invalidate the election.
131131

132132
An existing primary will step down in response to the
@@ -183,8 +183,10 @@ aware of the following conditions and possible situations:
183183

184184
.. note::
185185

186-
The only exception is that members with a priority of ``0`` cannot
187-
become :term:`primary` and will not seek election.
186+
The only exception is that members with a priority of ``0``
187+
cannot become :term:`primary` and will not seek election. See
188+
:ref:`replica-set-node-priority-configuration` for more
189+
information.
188190

189191
- Replica set members cannot become primary *unless* they have the
190192
highest "optime" of any visible members in the set.
@@ -194,23 +196,11 @@ aware of the following conditions and possible situations:
194196
:term:`primary` until the member with the highest priority catches up
195197
to the latest operation.
196198

197-
Each member in a replica set has only one vote, by default. You may
198-
change the number of votes each member has to allow for larger replica
199-
sets. Each replica set is limited to 12 total members with 7 voting
200-
members.
201199

202-
- The number of votes is modifiable in the :data:`replica set configuration <members[n].votes>`
203-
204-
- The number of votes each member has can be any non-negative integer,
205-
but it is highly recommended each member has 1 or 0 votes.
206-
207-
- To select a member to be a "preferred primary", modify the member's
208-
:ref:`priority value <replica-set-node-priority-configuration>`
209-
instead of adjusting the number of votes the member has.
210-
211-
.. TODO verify this. what should one do when >7 members are in a set?
212-
- When there are more than seven members in a replica set, adjust the
213-
number of votes for each active member.
200+
.. seealso:: ":ref:`Non-voting members in a replica
201+
set<replica-set-non-voting-members>`",
202+
":ref:`replica-set-node-priority-configuration`",
203+
":data:`replica configuration <members[n].votes>`
214204

215205
Syncing
216206
-------

source/core/replication.txt

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -170,11 +170,11 @@ participate in :term:`elections <election>`.
170170
Non-Voting
171171
~~~~~~~~~~
172172

173-
You may choose to change the number of votes that each node has in
173+
You may choose to change the number of votes that each member has in
174174
:term:`elections <election>` for :term:`primary`. In general, all
175-
nodes should have only 1 vote to prevent intermittent ties, deadlock,
175+
members should have only 1 vote to prevent intermittent ties, deadlock,
176176
or the wrong nodes from becoming :term:`primary`. Use ":ref:`replica
177-
set priorities <replica-set-node-priority>`" to control which nodes
177+
set priorities <replica-set-node-priority>`" to control which members
178178
are more likely to become primary.
179179

180180
.. index:: pair: replica set; failover
@@ -247,8 +247,6 @@ have a single vote in :ref:`elections <replica-set-elections>`.
247247
:data:`members[n].votes` except to permit more than 7 secondary
248248
nodes.
249249

250-
.. COMMENT a bit unclear. ALWAYS set, but except to have more than 7 secondary?
251-
252250
.. seealso:: ":ref:`Node Priority Configuration <replica-set-node-priority-configuration>`"
253251

254252
.. index:: pair: replica set; consistency

source/reference/replica-configuration.txt

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -174,9 +174,12 @@ Configuration Variables
174174
**Default**: 1
175175

176176
Controls the number of votes a server has in a :ref:`replica set
177-
election <replica-set-elections>`. If you need more than 7 nodes,
178-
use this setting to add additional non-voting nodes with a
179-
:data:`members[n].votes` value of ``0``.
177+
election <replica-set-elections>`. The number of votes each member
178+
has can be any non-negative integer, but it is highly recommended
179+
each member has 1 or 0 votes.
180+
181+
If you need more than 7 nodes, use this setting to add additional
182+
non-voting nodes with a :data:`members[n].votes` value of ``0``.
180183

181184
For most deployments and most members, use the default value,
182185
``1``, for :data:`members[n].votes`.

source/tutorial/expand-replica-set.txt

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,4 +126,13 @@ Production Notes
126126
:term:`primary` member's :term:`oplog`. The new secondary must be
127127
able to become current using operations from the primary's oplog.
128128

129+
- There is a maximum of seven :ref:`voting members
130+
<replica-set-election-internals>` in any replica set. When adding
131+
more members to a replica set that already has seven votes, you must
132+
either:
129133

134+
- add the new member as a :ref:`non-voting members <replica-set-non-voting-members>`.
135+
136+
- remove votes from an :data:`existing member <members[n].priority>`
137+
138+
.. seealso:: :data:`Modifying member votes <members[n].votes>`

0 commit comments

Comments
 (0)