]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
os/bluestore: provide a different name for fallback allocator 37794/head
authorIgor Fedotov <ifedotov@suse.com>
Mon, 14 Sep 2020 20:28:42 +0000 (23:28 +0300)
committerIgor Fedotov <ifedotov@suse.com>
Mon, 30 Nov 2020 23:10:31 +0000 (02:10 +0300)
Originally primary Hybrid allocator provided its own name when creating a
secondary fallback allocator. This resulted in duplicate admin socket
command registrations for both allocator. Registration return code was
ignored and henoe nobody was aware of the issue. Nautilus might suffer
from the issue though since it asserts on command deregistration failure.
And duplicate name causes such a failure for the secode
unregister_command() call.

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

src/os/bluestore/HybridAllocator.cc

index 484a664bf0d4422853a1a8521d11a9731f39d5ee..6caf5c6dd8924be68db1301ddb180e84d9a35299 100644 (file)
@@ -204,7 +204,7 @@ void HybridAllocator::_spillover_range(uint64_t start, uint64_t end)
     bmap_alloc = new BitmapAllocator(cct,
       get_capacity(),
       get_block_size(),
-      get_name());
+      get_name() + ".fallback");
   }
   bmap_alloc->init_add_free(start, size);
 }