Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-12561

Docs for SERVER-38994: Step down on SIGTERM

    XMLWordPrintableJSON

Details

    Description

      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.)

      Attachments

        Activity

          People

            kay.kim@mongodb.com Kay Kim (Inactive)
            kay.kim@mongodb.com Kay Kim (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              4 years, 10 weeks, 2 days ago