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

Balancer should prioritize draining shards

    XMLWordPrintableJSON

Details

    • Icon: Task Task
    • Resolution: Unresolved
    • Icon: Major - P3 Major - P3
    • None
    • None
    • None
    • Catalog and Routing
    • Sharding EMEA 2022-11-14
    • 3

    Description

      The balancer randomly chooses collections to balance each round. Within these collections, we prioritize draining shards, but if the balancer chooses collections that are not present on the draining shard, the balancer will move chunks between other shards rather than drain those that are trying to be removed.

      This problem is exacerbated if the user is trying to remove more than half of their shards. A user signaled that the draining of empty chunks was slowed down by the balancer moving chunks between the 2 non-draining shards. This prevented any chunks being drained from the shards being dropped during that round because the only two receiving shards were already involved in a migration.

      Attachments

        Activity

          People

            backlog-server-catalog-and-routing Backlog - Catalog and Routing
            allison.easton@mongodb.com Allison Easton
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated: