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

_configsvrCommitChunkMigration might return before changes are majority committed

    XMLWordPrintable

Details

    • Fully Compatible
    • ALL
    • Hide
      1. Start a migration
      2. Step down the primary of the config server after successfully committing the migration but before ending the _configsvrCommitChunkMigration command
      3. Check that both the donor and the recipient shard have the data locally.
      Show
      Start a migration Step down the primary of the config server after successfully committing the migration but before ending the _configsvrCommitChunkMigration command Check that both the donor and the recipient shard have the data locally.
    • Sharding 2020-08-10, Sharding 2020-08-24
    • 40

    Description

      SERVER-49147 transformed the _configsvrCommitChunkMigration to make it idempotent so a retry would not generate errors, however, it added the possibility to return with two (1 2) reads with local read concern on a command that has a majority written write concern. The result of this is that if a successful commit returns an error (like for example, if the config server steps down right after successfully written the changes) and the command is retried, it will return before the commit is replicated, which might cause a race between the subsequent refresh and the replication. This might cause an invalid state in which the shard does not see it's own change, and will prevent the range deletion task to execute, leaving garbage data on the shard, and serving data which no longer owns.

      Attachments

        Issue Links

          Activity

            People

              tommaso.tocci@mongodb.com Tommaso Tocci
              marcos.grillo@mongodb.com Marcos José Grillo Ramirez
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: