[SERVER-31002] minValid should alway be set to existent OpTime Created: 08/Sep/17  Updated: 30/Oct/23  Resolved: 27/Oct/17

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: None
Fix Version/s: 3.6.0-rc2

Type: Bug Priority: Major - P3
Reporter: Judah Schvimer Assignee: Siyuan Zhou
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Duplicate
is duplicated by SERVER-31039 set minvalid term to -1 on pv1 downgrade Closed
Related
is related to SERVER-31004 persist term and initialize to it on ... Closed
is related to SERVER-31039 set minvalid term to -1 on pv1 downgrade Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v3.4
Sprint: Repl 2017-11-13
Participants:
Case:
Linked BF Score: 0

 Description   

We use a $max to update the minvalid which updates the timestamp and term independently: https://github.com/mongodb/mongo/blob/2197cedd9cc61cba6ceb81affc348d3e3932c1b8/src/mongo/db/repl/replication_consistency_markers_impl.cpp#L188-L192.

If we provide a timestamp that is greater than the current minValid, but a term that is less, we can end up with a minValid that never existed. This occurs primarily on protocol version downgrade and can lead to us being unable to choose a sync source.



 Comments   
Comment by Githook User [ 27/Oct/17 ]

Author:

{'email': 'siyuan.zhou@mongodb.com', 'name': 'Siyuan Zhou', 'username': 'visualzhou'}

Message: SERVER-31002 minValid should alway be set to existent OpTime.
Branch: master
https://github.com/mongodb/mongo/commit/db64381873afebf1532a0fd576499f72da00b703

Comment by Judah Schvimer [ 11/Sep/17 ]

While this is not ideal, we think this can be fixed with SERVER-31039 or SERVER-31004. I do not see a way to do this ticket without taking a significant performance regression.

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