]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/seastore/nbd: destruct the store before create
authorYingxin Cheng <yingxin.cheng@intel.com>
Wed, 16 Jun 2021 08:00:44 +0000 (16:00 +0800)
committerKefu Chai <kchai@redhat.com>
Wed, 16 Jun 2021 16:23:58 +0000 (00:23 +0800)
Otherwise the store will register the conflicting metrics and result in
double_registration.

Signed-off-by: Yingxin Cheng <yingxin.cheng@intel.com>
src/crimson/tools/store_nbd/fs_driver.cc

index 76db2c27082649c620c83b1f1b0f1a3315bb4ce3..8de6d86a3a6fffb56c2625418647a2c120367bb9 100644 (file)
@@ -159,6 +159,7 @@ seastar::future<> FSDriver::close()
 
 void FSDriver::init()
 {
+  fs.reset();
   fs = FuturizedStore::create(
     config.get_fs_type(),
     *config.path,