From: Samuel Just Date: Fri, 20 Aug 2021 03:41:50 +0000 (-0700) Subject: crimson/tools/store_nbd/tm_driver: reset segment_manager in mkfs() X-Git-Tag: v17.1.0~1003^2~5 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=6da99216867b47c5881195827c98c13e2d9439fc;p=ceph.git crimson/tools/store_nbd/tm_driver: reset segment_manager in mkfs() Otherwise, instantiating segment_manager in mount() results in two instances and a duplicate metric exception. Signed-off-by: Samuel Just --- diff --git a/src/crimson/tools/store_nbd/tm_driver.cc b/src/crimson/tools/store_nbd/tm_driver.cc index 8f4acf0b917..c6182de0320 100644 --- a/src/crimson/tools/store_nbd/tm_driver.cc +++ b/src/crimson/tools/store_nbd/tm_driver.cc @@ -181,6 +181,7 @@ seastar::future<> TMDriver::mkfs() return segment_manager->close(); }).safe_then([this] { clear(); + segment_manager.reset(); logger().debug("mkfs complete"); return TransactionManager::mkfs_ertr::now(); }).handle_error(