-
Type: Task
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Labels:None
Description
Description:
This changes the behavior of clean shutdown.
Probably most noticeable for users, a shutdown initiated by SIGTERM will now attempt a step down in a way very similar to the shutdown command without arguments. It differs in that:
- Where a default shutdown command would have failed, returning to the user with an error, failing to stepdown will not stop shutdown in this path.
- The node will not vote in elections that occur after the step down
Engineering Ticket Description:
Kubernetes uses SIGTERM to spin down containers, and our sysv init and systemd unit files use SIGTERM to shutdown the mongodb service. It would greatly reduce election time and prevent potential data loss due to replicaset rollback if we were able to use the election handoff path of stepdown instead of waiting for the full electionTimeoutMillis.
Scope of changes
Impact to Other Docs
MVP (Work and Date)
Resources (Scope or Design Docs, Invision, etc.)
- documents
-
SERVER-38994 Step down on SIGTERM
- Closed