[DOCS-12253] Add a comment in "Modify Replica Set Protocol Version" to prevent users from doing faster replica set protocol version upgrade or downgrade. Created: 10/Dec/18  Updated: 30/Oct/23  Resolved: 16/Jan/19

Status: Closed
Project: Documentation
Component/s: manual, Server
Affects Version/s: 3.6.6
Fix Version/s: Server_Docs_20231030

Type: Task Priority: Major - P3
Reporter: Suganthi Mani Assignee: Kay Kim (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to SERVER-38366 Replica set nodes update the term wit... Closed
related to SERVER-38504 On Primary, to verify that our lastAp... Closed
related to SERVER-38505 For pv1, to determine if the oplog e... Closed
related to DOCS-12368 Update replSetGetStatus.optimes to re... Closed
Participants:
Days since reply: 5 years, 4 weeks ago
Epic Link: DOCSP-1769
Story Points: 0.5

 Description   

Description

For mongod version < 4.0, if we have below upgrade/downgrade sequence.

1) Start a replica set in pv1.

2) Downgrade to pv0.

3) Before the secondaries downgrade to pv0, the user upgrades to pv1 again. 

Then it can lead to failures described in SERVER-38505SERVER-38366 and SERVER-38504.

In order to prevent those failures from occurring, we should add a comment in modify-replica-set-protocol-version stating that "Before user upgrades or downgrades the replica set protocol version, the user should make sure that at least one oplog entry generated from the current protocol version has replicated and applied to all secondaries. And, we can get the node's last applied oplog entry optime information from  either replSetGetStatus.optimes.appliedOpTime or getLastError.lastOp. If the current protocol version is pv0, then replSetGetStatus.optimes.appliedOpTime & getLastError.lastOp will have an optime with term field ("t") as -1. If it is pv1, then the term field will have a value greater than -1".

Scope

Update Modify Replica Set Protocol Version to call out that users must wait until the protocol version change has replicated and applied to all members of the replica set. Provide logic for testing as above.

Possibly generally dissuade users from rapidly changing pv values.

Note: 3.6 deprecates pv0. Apply to 3.6 and backport to 3.2 (when pv1 was introduced)



 Comments   
Comment by Githook User [ 16/Jan/19 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: before pv change, check lastCommittedOpTime.t
Branch: v3.2
https://github.com/mongodb/docs/commit/df06cc9d853735d0ba14ba97b89d3b5d6f1d4f5b

Comment by Githook User [ 16/Jan/19 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: before pv change, check lastCommittedOpTime.t
Branch: v3.4
https://github.com/mongodb/docs/commit/58e6b79c60a429690455a06c1e4fef0e276002eb

Comment by Githook User [ 16/Jan/19 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: before pv change, check lastCommittedOpTime.t
Branch: v3.6
https://github.com/mongodb/docs/commit/46bc437f44dfa24ee646a8c0e83d3eabc9f34e35

Comment by Githook User [ 16/Jan/19 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: before pv change, check lastCommittedOpTime.t
Branch: v4.0
https://github.com/mongodb/docs/commit/4d07b169765619a1111fea7149d06472db8715e2

Comment by Githook User [ 16/Jan/19 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: before pv change, check lastCommittedOpTime.t
Branch: master
https://github.com/mongodb/docs/commit/13e556722623d12196f6f05c399fe15362cc95c7

Comment by Suganthi Mani [ 16/Jan/19 ]

Since for pv0, rs.status().optimes.appliedOpTime returns only the timestamp of the operation, we won't be able to use rs.status().optimes.appliedOpTime.t to determine the term for that operation( see HELP-8664). So, we need to update Modify Replica Set Protocol Version doc section to instruct users to check rs.status().optimes.lastCommittedOpTime.t for mongoDB versions < 4.0. 

P.S: Sorry for the confusion.

Comment by Githook User [ 18/Dec/18 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: tweaks for backporting pv changes to 3.2
Branch: v3.2
https://github.com/mongodb/docs/commit/b83724d34c5afec9789855dcae2b4b6e75e2ac45

Comment by Githook User [ 18/Dec/18 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: tweaks for backporting pv changes to 3.4 and earlier
Branch: v3.4
https://github.com/mongodb/docs/commit/6b415c2286ee50ac4ea4f7df54631f56681fd48b

Comment by Githook User [ 18/Dec/18 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: tweaks for backporting pv changes to 3.6 and earlier
Branch: v3.6
https://github.com/mongodb/docs/commit/05e62f0ad3e155f102d8756cc8508988f535581a

Comment by Githook User [ 18/Dec/18 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: prereq for pv changes for 3.6 and earlier
Branch: v3.4
https://github.com/mongodb/docs/commit/7779de0f7a7836608e4c3a2996023ccc8962b69b

Comment by Githook User [ 18/Dec/18 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: prereq for pv changes for 3.6 and earlier
Branch: v3.6
https://github.com/mongodb/docs/commit/229d5095124e1790297b01c04a5876ebc41f0987

Comment by Githook User [ 18/Dec/18 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: prereq for pv changes for 3.6 and earlier
Branch: v4.0
https://github.com/mongodb/docs/commit/a70cca6f16c2892fee4e556b61e687e61fa535eb

Comment by Githook User [ 18/Dec/18 ]

Author:

{'email': 'kay.kim@mongodb.com', 'name': 'Kay Kim'}

Message: DOCS-12253: prereq for pv changes for 3.6 and earlier
Branch: master
https://github.com/mongodb/docs/commit/2eabe8242f31842b0d9fab535cb958733cd071ed

Generated at Thu Feb 08 08:04:47 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.