]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
os/bluestore/bluestore-tool: fix error output
authorIgor Fedotov <ifedotov@suse.com>
Wed, 19 Jun 2019 12:07:19 +0000 (15:07 +0300)
committerIgor Fedotov <ifedotov@suse.com>
Fri, 5 Jul 2019 09:04:33 +0000 (12:04 +0300)
Signed-off-by: Igor Fedotov <ifedotov@suse.com>
(cherry picked from commit 9297d0420dcf8e735cea88bad86c14e0de95b707)

src/os/bluestore/bluestore_tool.cc

index 629f0e2c6f29f1101691ec022a2c1cfd94aa401e..5e6b481cefd58ae10a7a15e5dc90e7ebfbf42ae3 100644 (file)
@@ -713,8 +713,6 @@ int main(int argc, char **argv)
        exit(EXIT_FAILURE);
       }
 
-      bool need_db = dev_target_id == BlueFS::BDEV_NEWDB;
-
       BlueStore bluestore(cct.get(), path);
       int r = bluestore.migrate_to_existing_bluefs_device(
        src_dev_ids,
@@ -727,8 +725,9 @@ int main(int argc, char **argv)
          }
        }
       } else {
+        bool need_db = dev_target_id == BlueFS::BDEV_DB;
        cerr << "failed to migrate to existing BlueFS device: "
-            << (need_db ? BlueFS::BDEV_DB : BlueFS::BDEV_DB)
+            << (need_db ? BlueFS::BDEV_DB : BlueFS::BDEV_WAL)
             << " " << dev_target
             << cpp_strerror(r)
             << std::endl;