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

Node can crash if stepdown occurs after setting FCV to downgrading state but before reconfiguring config to use secondaryDelaySecs instead of slaveDelay

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • N/A
    • Affects Version/s: None
    • Component/s: Straight to 8
    • None
    • Cluster Scalability
    • Fully Compatible
    • ALL
    • S8 Team 2025-04-14
    • None
    • 0
    • None
    • None
    • None
    • None
    • None
    • None

      This is the specific sequence of events:

      1. setFCV is called to downgrade a node from FCV 7.0 to 4.4
      2. FCV is set to the downgrading state (`FCV::kDowngradingFrom_7_0_To_4_4`) which acts as though we are already in FCV 4.4 for the purpose of feature flag checking.
      3. Stepdown occurs before we can reconfig secondaryDelaySecs in the repl config to slaveDelay
      4. As part of stepping-up of a new primary, a reconfig must happen to increment the repl config term. However, that will fail because when validating the new config document for reconfig we run isFCVCompatiable() which will return false because    
        gUseSecondaryDelaySecs isn't enabled and the repl config still contains references secondaryDelaySecs. 
      5. The step-up code sees this error when attempting to increment the config term and throws a fatal error

       

            Assignee:
            wenqin.ye@mongodb.com Wenqin Ye
            Reporter:
            wenqin.ye@mongodb.com Wenqin Ye
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: