[SERVER-27118] Default shutdown command's 'timeoutSecs' argument to 10 seconds Created: 18/Nov/16  Updated: 11/Jan/19  Resolved: 14/Dec/16

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: None
Fix Version/s: 3.2.12, 3.4.2, 3.5.2

Type: Task Priority: Major - P3
Reporter: Spencer Brody (Inactive) Assignee: Jack Mulrow
Resolution: Done Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Related
related to SERVER-27461 Retry connecting to shut down primary... Closed
related to SERVER-26747 replSetStepDown should wait for last ... Closed
is related to SERVER-27015 db.shutdownServer doesn't find electa... Closed
Backwards Compatibility: Fully Compatible
Backport Requested:
v3.4, v3.2
Sprint: Repl 2016-12-12, Repl 2017-01-23
Participants:

 Description   

When the shutdown command is run against the primary of a replica set, it first tries to step down. The shutdown command takes a 'timeoutSecs' argument to control how long it waits for secondaries to catch up after it has blocked new writes before it aborts the stepdown and shutdown attempt. This argument, however, defaults to 0, so unless a majority of secondaries are fully caught up to the primary at the moment that the shutdown command is issued then it will fail - which if there are a steady stream of writes happening will likely always be the case. The replSetStepDown command has similar behavior, but its equivalent argument - 'secondaryCatchUpPeriodSecs' - defaults to 10 seconds. We should change shutdown to match the behavior of stepdown so that it's actually possible to use the default behavior to shut down a primary while it is taking writes.



 Comments   
Comment by Githook User [ 29/Dec/16 ]

Author:

{u'username': u'jsmulrow', u'name': u'Jack Mulrow', u'email': u'jack.mulrow@mongodb.com'}

Message: SERVER-27118 Default shutdown command's timeoutSecs argument to 10 seconds

(cherry picked from commit 232832a0e79252a29061def2fb89b985f29b78c7)
Branch: v3.2
https://github.com/mongodb/mongo/commit/56ea371a1ebb6062cfee204e22103242bd7ec8dc

Comment by Githook User [ 28/Dec/16 ]

Author:

{u'username': u'jsmulrow', u'name': u'Jack Mulrow', u'email': u'jack.mulrow@mongodb.com'}

Message: SERVER-27118 Default shutdown command's timeoutSecs argument to 10 seconds

(cherry picked from commit 232832a0e79252a29061def2fb89b985f29b78c7)
Branch: v3.4
https://github.com/mongodb/mongo/commit/6997a1196146f46ddad5f63a61292ed0c4198dac

Comment by Githook User [ 14/Dec/16 ]

Author:

{u'name': u'Jack Mulrow', u'email': u'jack.mulrow@mongodb.com'}

Message: SERVER-27118 Default shutdown command's timeoutSecs argument to 10 seconds
Branch: master
https://github.com/mongodb/mongo/commit/232832a0e79252a29061def2fb89b985f29b78c7

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