Make AutoGetOplog behave consistently in replica set node started as standalone

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 7.2.0-rc0, 7.0.5, 6.0.13, 7.1.2, 5.0.24
    • Affects Version/s: None
    • Component/s: None
    • None
    • Fully Compatible
    • ALL
    • v7.1, v7.0, v6.0, v5.0
    • Execution EMEA Team 2023-09-18
    • 5
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      AutoGetOplog does not behave as expected due to the collection pointer not being cached in standalone mode, even if the collection exists because previously the node was started as part of a replica set.

       

      Example:

      When validate cmd detects and inconsistency it attempts to fetch the associated oplog entry. To do so, it uses AutoGetOplog, which relies on LocalOplogInfo. 

      The Collection ptr in LocalOplogInfo is not populated in standalone mode (acquireOplogCollectionForLogging) unless recoverFromOplogAsStandalone, resulting in a segmentation fault due to dereferencing a nullptr.

              Assignee:
              Yujin Kang Park
              Reporter:
              Yujin Kang Park
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: