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

Primary node stuck waiting for secondary to finish indexBuild when downgrading from 4.4 to 4.2

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 4.4.16
    • Affects Version/s: 4.4.13
    • Component/s: None
    • None
    • Fully Compatible
    • ALL
    • Execution Team 2022-07-11, Execution Team 2022-07-25
    • 0

      In versions 4.4 and up, we support two-phase index builds meaning that a primary will wait to fully commit an index until the index is built on all secondaries. This is not the case on 4.2; secondaries will not build the index and effectively ignore the "startIndexBuild" oplog entry

      There is a race condition on the primary when setting the index build protocol (single/two-phase) and downgrading the FCV which takes a global lock (whereas setting the protocol does not). So, if the index build protocol is set to two-phase and then we downgrade (on the primary), and then the secondary downgrades before building the index, the primary will wait for a response from the secondary signifying the index was built, but the secondary (on version 4.2 with the single index build protocol) will not build it.

            Assignee:
            fausto.leyva@mongodb.com Fausto Leyva (Inactive)
            Reporter:
            fausto.leyva@mongodb.com Fausto Leyva (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: