From 5ef725d07bcd159c6478e581ca5e0323b4193b7d Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Wed, 14 Sep 2016 18:38:05 -0400 Subject: [PATCH] os/bluestore/BlueFS: config option for allocator (default stupid) StupidAllocator is probably a more appropriate choice for bluefs. Either way, it needn't be tied to what BlueStore is using. Signed-off-by: Sage Weil --- src/common/config_opts.h | 1 + src/os/bluestore/BlueFS.cc | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/common/config_opts.h b/src/common/config_opts.h index b601f300be7..ea96c01888d 100644 --- a/src/common/config_opts.h +++ b/src/common/config_opts.h @@ -934,6 +934,7 @@ OPTION(bluefs_log_compact_min_size, OPT_U64, 16*1048576) // before we consider OPTION(bluefs_min_flush_size, OPT_U64, 65536) // ignore flush until its this big OPTION(bluefs_compact_log_sync, OPT_BOOL, false) // sync or async log compaction? OPTION(bluefs_buffered_io, OPT_BOOL, false) +OPTION(bluefs_allocator, OPT_STR, "stupid") // stupid | bitmap OPTION(bluestore_bluefs, OPT_BOOL, true) OPTION(bluestore_bluefs_env_mirror, OPT_BOOL, false) // mirror to normal Env for debug diff --git a/src/os/bluestore/BlueFS.cc b/src/os/bluestore/BlueFS.cc index a6b4d18abb6..f4c0f1e0fdc 100644 --- a/src/os/bluestore/BlueFS.cc +++ b/src/os/bluestore/BlueFS.cc @@ -314,7 +314,7 @@ void BlueFS::_init_alloc() continue; } assert(bdev[id]->get_size()); - alloc[id] = Allocator::create(g_conf->bluestore_allocator, + alloc[id] = Allocator::create(g_conf->bluefs_allocator, bdev[id]->get_size(), g_conf->bluefs_alloc_size); interval_set& p = block_all[id]; -- 2.39.5