>=16.0.0
--------
+* New bluestore_rocksdb_options_annex config parameter. Complements
+ bluestore_rocksdb_options and allows setting rocksdb options without repeating
+ the existing defaults.
* $pid expansion in config paths like `admin_socket` will now properly expand
to the daemon pid for commands like `ceph-mds` or `ceph-osd`. Previously only
`ceph-fuse`/`rbd-nbd` expanded `$pid` with the actual daemon pid.
OPTION(bluestore_max_deferred_txc, OPT_U64)
OPTION(bluestore_max_defer_interval, OPT_U64)
OPTION(bluestore_rocksdb_options, OPT_STR)
+OPTION(bluestore_rocksdb_options_annex, OPT_STR)
OPTION(bluestore_fsck_on_mount, OPT_BOOL)
OPTION(bluestore_fsck_on_mount_deep, OPT_BOOL)
OPTION(bluestore_fsck_quick_fix_on_mount, OPT_BOOL)
Option("bluestore_rocksdb_options", Option::TYPE_STR, Option::LEVEL_ADVANCED)
.set_default("compression=kNoCompression,max_write_buffer_number=4,min_write_buffer_number_to_merge=1,recycle_log_file_num=4,write_buffer_size=268435456,writable_file_max_buffer_size=0,compaction_readahead_size=2097152,max_background_compactions=2,max_total_wal_size=1073741824")
- .set_description("Rocksdb options"),
+ .set_description("Full set of rocksdb settings to override"),
+
+ Option("bluestore_rocksdb_options_annex", Option::TYPE_STR, Option::LEVEL_ADVANCED)
+ .set_default("")
+ .set_description("An addition to bluestore_rocksdb_options. Allows setting rocksdb options without repeating the existing defaults."),
Option("bluestore_rocksdb_cf", Option::TYPE_BOOL, Option::LEVEL_ADVANCED)
.set_default(true)
if (bluefs_layout.shared_bdev == BlueFS::BDEV_SLOW) {
string options = cct->_conf->bluestore_rocksdb_options;
+ string options_annex = cct->_conf->bluestore_rocksdb_options_annex;
+ if (!options_annex.empty()) {
+ if (!options.empty() &&
+ *options.rbegin() != ',') {
+ options += ',';
+ }
+ options += options_annex;
+ }
rocksdb::Options rocks_opts;
r = RocksDBStore::ParseOptionsFromStringStatic(
int r;
ceph_assert(!(create && read_only));
string options;
+ string options_annex;
stringstream err;
string kv_dir_fn;
string kv_backend;
}
if (kv_backend == "rocksdb") {
options = cct->_conf->bluestore_rocksdb_options;
+ options_annex = cct->_conf->bluestore_rocksdb_options_annex;
+ if (!options_annex.empty()) {
+ if (!options.empty() &&
+ *options.rbegin() != ',') {
+ options += ',';
+ }
+ options += options_annex;
+ }
+
if (cct->_conf.get_val<bool>("bluestore_rocksdb_cf")) {
sharding_def = cct->_conf.get_val<std::string>("bluestore_rocksdb_cfs");
}