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

Update chunks during setFCV 4.4 «--» 5.0 must not block balancing for long periods

    • Type: Icon: Improvement Improvement
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 5.0.3
    • Affects Version/s: 5.0.0-rc1
    • Component/s: Sharding
    • Fully Compatible
    • v5.0
    • Sharding EMEA 2021-07-26, Sharding EMEA 2021-08-09

      As discovered during the investigation of SERVER-57309, the update of config.chunks entries during setFCV - happening under the chunk operations lock - may block migrations for long periods in presence of a lot of chunks.

      Following, the results of some simple downgrade/upgrade experiments with different number of chunks (executed on the virtual workstation):

        downgrade downgrade upgrade upgrade
      update operation
      number of chunks
      $set ns $unset uuid & timestamp $set uuid & timestamp $unset ns
      100K 32 s 27 s 22 s 31 s
      500K 180 s 164 s 117 s 144 s
      1M 324 s 313 s 211 s 271 s

      A possible improvement to reduce the window in which balancing is not allowed would be to perform the $unset operations outside such lock, but still during setFCV.

            Assignee:
            pierlauro.sciarelli@mongodb.com Pierlauro Sciarelli
            Reporter:
            pierlauro.sciarelli@mongodb.com Pierlauro Sciarelli
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: