]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
os/bluestore: fix inappropriate ENOSPC from avl/hybrid allocator 38475/head
authorIgor Fedotov <ifedotov@suse.com>
Thu, 3 Dec 2020 19:08:43 +0000 (22:08 +0300)
committerIgor Fedotov <ifedotov@suse.com>
Mon, 7 Dec 2020 13:38:19 +0000 (16:38 +0300)
commit809ed124d8c814cb23de2e695f3b28a88a99af0d
tree2d5c939ede8eba09bf6a59519c995bbc96ee3eed
parent113c464360ba2b5e92399525bd74abacaafcabb2
os/bluestore: fix inappropriate ENOSPC from avl/hybrid allocator

Under high fragmentation circumstances (in best-fit mode) these allocators might fail to
return continuous(longer than a single alloc unit) extents. Occurs when
requested size is longer than the maximum available extents and these
extents are unaligned with alloc unit. The latter results in the actual lengths of these extens are shorter
than the requested length and they do not match to the lookup. Which
finally causes no allocation at all.

Fixes: https://tracker.ceph.com/issues/47883
Signed-off-by: Igor Fedotov <ifedotov@suse.com>
(cherry picked from commit f927549d2d54e7464151d234377aa82bb753bca9)

 Conflicts:
src/test/objectstore/Allocator_test.cc
 Legacy gtest macros name
src/os/bluestore/AvlAllocator.cc
src/test/objectstore/Allocator_test.cc