]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/tools/store_nbd/fs_driver: fix mount and mkfs to handle new mkfs signature 43629/head
authorSamuel Just <sjust@redhat.com>
Fri, 22 Oct 2021 06:15:07 +0000 (23:15 -0700)
committerSamuel Just <sjust@redhat.com>
Fri, 22 Oct 2021 06:48:38 +0000 (23:48 -0700)
Introduced: e5f7ff
Fixes: https://tracker.ceph.com/issues/53012
Signed-off-by: Samuel Just <sjust@redhat.com>
src/crimson/tools/store_nbd/fs_driver.cc

index 436ceeb9dc5121e2054470c26da7a8e12f476a30..c2834dcc6e52b16d714e04154f7b95da0bc1d9e1 100644 (file)
@@ -199,7 +199,18 @@ seastar::future<> FSDriver::mkfs()
     init();
     return fs->start();
   }).then([this] {
-    return fs->mount();
+    return fs->mount(
+    ).handle_error(
+      crimson::stateful_ec::handle([] (const auto& ec) {
+        crimson::get_logger(
+         ceph_subsys_test
+       ).error(
+         "error mounting object store in {}: ({}) {}",
+         crimson::common::local_conf().get_val<std::string>("osd_data"),
+         ec.value(),
+         ec.message());
+       std::exit(EXIT_FAILURE);
+      }));
   }).then([this] {
     return seastar::do_for_each(
       boost::counting_iterator<unsigned>(0),
@@ -231,7 +242,18 @@ seastar::future<> FSDriver::mount()
     init();
     return fs->start();
   }).then([this] {
-    return fs->mount();
+    return fs->mount(
+    ).handle_error(
+      crimson::stateful_ec::handle([] (const auto& ec) {
+        crimson::get_logger(
+         ceph_subsys_test
+       ).error(
+         "error mounting object store in {}: ({}) {}",
+         crimson::common::local_conf().get_val<std::string>("osd_data"),
+         ec.value(),
+         ec.message());
+        std::exit(EXIT_FAILURE);
+      }));
   }).then([this] {
     return seastar::do_for_each(
       boost::counting_iterator<unsigned>(0),