]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
os/bluestore: add debug option to disable per pool statistics collection
authorIgor Fedotov <ifedotov@suse.com>
Mon, 5 Mar 2018 18:09:36 +0000 (21:09 +0300)
committerIgor Fedotov <ifedotov@suse.com>
Thu, 6 Dec 2018 15:54:21 +0000 (18:54 +0300)
Signed-off-by: Igor Fedotov <ifedotov@suse.com>
src/common/legacy_config_opts.h
src/common/options.cc
src/os/bluestore/BlueStore.cc

index 2ee8f85936c8d76e1530d4e13b4c25664f572eee..9e1a0608230453a71d23338917813da7c6d80a83 100644 (file)
@@ -1073,6 +1073,7 @@ OPTION(bluestore_debug_permit_any_bdev_label, OPT_BOOL)
 OPTION(bluestore_debug_random_read_err, OPT_DOUBLE)
 OPTION(bluestore_debug_inject_bug21040, OPT_BOOL)
 OPTION(bluestore_debug_inject_csum_err_probability, OPT_FLOAT)
+OPTION(bluestore_debug_no_per_pool_stats, OPT_BOOL)
 
 OPTION(kstore_max_ops, OPT_U64)
 OPTION(kstore_max_bytes, OPT_U64)
index 3d03c32b6e5d60d83b2e8631e78e381dcb9be18d..19c771000691a2bd82aca1e414c14a162e126b9d 100644 (file)
@@ -4385,6 +4385,10 @@ std::vector<Option> get_global_options() {
     .set_default(0.0)
     .set_description("inject crc verification errors into bluestore device reads"),
 
+    Option("bluestore_debug_no_per_pool_stats", Option::TYPE_BOOL, Option::LEVEL_DEV)
+    .set_default(false)
+    .set_description(""),
+    
     // -----------------------------------------
     // kstore
 
index 1494af6f2bfcd8b573a9f82cf98c35c451609292..4f57253b982d799bfb4ba78f311f86c73b5a0462 100644 (file)
@@ -7648,7 +7648,8 @@ int BlueStore::statfs(struct store_statfs_t *buf)
 int BlueStore::pool_statfs(uint64_t pool_id, struct store_statfs_t *buf)
 {
   dout(20) << __func__ << " pool " << pool_id<< dendl;
-  if (!per_pool_stat_collection) {
+  if (!per_pool_stat_collection ||
+      cct->_conf->bluestore_debug_no_per_pool_stats) {
     dout(20) << __func__ << " not supported in a legacy mode " << dendl;
     return -ENOTSUP;
   }