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

Rollback does not wait for applier to finish before starting

    XMLWordPrintableJSON

Details

    • Fully Compatible
    • ALL
    • Repl E (01/08/16)
    • 0

    Description

      This error message is a bit mislead as well. The error is due to trying to re-apply the last/current oplog entry again.

      [rsSync] Fatal assertion 34361 OplogOutOfOrder Attempted to apply an earlier oplog entry (ts: Dec 18 01:16:07:1) when our lastWrittenOptime was (term: 2, timestamp: Dec 18 01:16:07:1)
      

      After looking a bit more into this, I have found this sequence which caused the problem:

      • Chained replication
      • Failover with rollback
      • Chained replica starts rollback while still apply with buffered oplog entries

      Under these conditions it is race where this error occurs when the rollback happens during/before all the buffered oplog entries are applied.

      Attachments

        Issue Links

          Activity

            People

              scotthernandez Scott Hernandez (Inactive)
              scotthernandez Scott Hernandez (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: