Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-9013

Graceful Server Shutdown (no new connections, wait for existing ops to complete)

    • Type: Icon: New Feature New Feature
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 4.7.0
    • Affects Version/s: None
    • Component/s: Admin
    • None
    • Fully Compatible
    • Repl 2020-06-01

      mongod secondaries and mongos now enter a quiesce mode prior to shutdown, to allow short-running operations to finish. During this time, new and existing operations are allowed to run, but isMaster requests return a ShutdownInProgress error, to indicate that clients should start routing operations to other nodes. On mongod, quiesce mode happens after the stepdown attempt, and only if the node is now in state SECONDARY. The combined time for stepdown and quiesce mode is specified by the timeoutSecs parameter to the shutdown command (for command-based shutdown) or the shutdownTimeoutMillisForSignaledShutdown/mongosShutdownTimeoutMillisForSignaledShutdown server parameter (for signaled shutdown). This work is fully implemented following SERVER-46952 and SERVER-46958.

      Original description:
      It would be nice to have a feature that would allow open connections to complete existing operations to complete while disallowing new ones to begin, perhaps with a configurable timeout for the existing clients. This is a common feature in relational databases, like Oracle's shutdown "normal" / "immediate" / "abort".

      http://docs.oracle.com/cd/B28359_01/server.111/b28310/start003.htm has some details on this particular comparison.

            Assignee:
            tess.avitabile@mongodb.com Tess Avitabile (Inactive)
            Reporter:
            scott.d'aquila@morganstanley.com Scott D'Aquila
            Votes:
            2 Vote for this issue
            Watchers:
            11 Start watching this issue

              Created:
              Updated:
              Resolved: