]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
os/bluestore: Improve fragmentation calculation
authorAdam Kupczyk <akupczyk@ibm.com>
Thu, 26 Jan 2023 12:21:28 +0000 (12:21 +0000)
committerAdam Kupczyk <akupczyk@ibm.com>
Wed, 22 Feb 2023 17:27:35 +0000 (18:27 +0100)
commit1ca6e1f0389f1894bdc91ca3c872b17fe2b3fae1
tree26ff5d85ea31186675950c19642202010b03c846
parentb62ad2d807bc443cc44e530eb78f2e7cd04ec961
os/bluestore: Improve fragmentation calculation

The fragmentation is calculated by giving value to each free chunk.
Simplified, byte chunk size X*2 is 1.1 more worth then byte in chunk size X.
This logic is not very useful when chunks are really large.
So, for large chunks (>8MB) we change value coefficient to 1.02.

Overall, the change is intended so split into large chunks will only slightly
increase fragmentation, but preserving the sharp increase of fragmentation when
small chunks start dominating.

Partially fixes: https://tracker.ceph.com/issues/58022

Signed-off-by: Adam Kupczyk <akupczyk@ibm.com>
src/os/bluestore/Allocator.cc