[SERVER-28695] step_down_during_draining.js should wait for writes to be durable before disable replication on secondaries using fail point Created: 07/Apr/17  Updated: 15/Aug/17  Resolved: 10/Apr/17

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: 3.4.3
Fix Version/s: 3.4.4

Type: Bug Priority: Major - P3
Reporter: Benety Goh Assignee: Benety Goh
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Related
is related to SERVER-27216 Increase catchup timeout to 300 secon... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Completed:
Sprint: Repl 2017-04-17
Participants:
Linked BF Score: 0

 Description   

On slow machines, it may be possible that the durable optime has not caught up with the committed optime before we disable replication the secondaries. This may lead to failed elections when we request one of the secondaries to step up to become primary.

    replSet.awaitReplication();
 
    // Enable fail point to stop replication.
    var secondaries = replSet.getSecondaries();
    secondaries.forEach(enableFailPoint);
...
    stepUp(secondary);



 Comments   
Comment by Githook User [ 11/Apr/17 ]

Author:

{u'username': u'benety', u'name': u'Benety Goh', u'email': u'benety@mongodb.com'}

Message: SERVER-28695 step_down_during_draining.js should wait for writes to be durable before disable replication on secondaries using fail point

(cherry picked from commit 9df49e4e8b6b60106bbaad9f97d4457395ffacd0)
Branch: v3.4
https://github.com/mongodb/mongo/commit/dce4c38455d8456e9439d725b5a14f9dd9170e95

Comment by Githook User [ 11/Apr/17 ]

Author:

{u'username': u'benety', u'name': u'Benety Goh', u'email': u'benety@mongodb.com'}

Message: Revert "SERVER-28695 step_down_during_draining.js should wait for writes to be durable before disable replication on secondaries using fail point"

This reverts commit 9df49e4e8b6b60106bbaad9f97d4457395ffacd0.

This commit is meant for the 3.4 branch only.
Branch: master
https://github.com/mongodb/mongo/commit/9eba33d5ee13b3cb9d71e255c5668e28f64c0f61

Comment by Githook User [ 10/Apr/17 ]

Author:

{u'username': u'benety', u'name': u'Benety Goh', u'email': u'benety@mongodb.com'}

Message: SERVER-28695 step_down_during_draining.js should wait for writes to be durable before disable replication on secondaries using fail point
Branch: master
https://github.com/mongodb/mongo/commit/9df49e4e8b6b60106bbaad9f97d4457395ffacd0

Comment by Spencer Brody (Inactive) [ 07/Apr/17 ]

Why would this cause failed elections? I thought elections only considered lastAppliedOpTime, not the durable optimes?

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