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

Enabling sharding creates a database without an oplog entry

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Works as Designed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Replication, Sharding
    • Labels:
      None
    • Operating System:
      ALL
    • Steps To Reproduce:
      Hide

      I have attached a repro; it prints out the oplogs showing two dropDatabase entries in a row (and no createDatabase) for the affected database.

      Show
      I have attached a repro; it prints out the oplogs showing two dropDatabase entries in a row (and no createDatabase) for the affected database.

      Description

      If we run enableSharding and movePrimary on a database, we can cause it to be created (for the purpose of dropDatabase) without a "create" oplog entry. It appears that on the primary shard this does not cause a problem. On a non-primary shard the database will be created on the primary but not the secondary, so if a dropDatabase is run, it will create an oplog entry to delete a database the secondary does not think exists.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              garaudy.etienne Garaudy Etienne
              Reporter:
              matthew.russotto Matthew Russotto
              Participants:
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: