[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Libguestfs] [PATCH] v2v: inspect source: Don't tell people twice to run virt-v2v -v -x (RHBZ#1167623).



There were two related bugs in the virt-v2v error messages when source
inspection failed.

Firstly it would print the message about running 'virt-v2v -v -x' twice:

  virt-v2v: error: inspection could not detect the source guest (or physical
  machine).

  Assuming that you are running virt-v2v/virt-p2v on a source which is
  supported (and not, for example, a blank disk), then this should not
  happen.  You should run 'virt-v2v -v -x ... >& log' and attach the complete
  log to a new bug report (see http://libguestfs.org).

  No root device found in this operating system image.

  If reporting bugs, run virt-v2v with debugging enabled and include the
  complete output:

    virt-v2v -v -x [...]

And secondly it would tell you to run virt-v2v -v -x even if you were
running with verbose messages.

Further fix for https://bugzilla.redhat.com/show_bug.cgi?id=1167623
which updates commit ab7197476de1cb3c8727caf4da429f6293ca4227.

Thanks: Kun Wei.
---
 v2v/inspect_source.ml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/v2v/inspect_source.ml b/v2v/inspect_source.ml
index 2b422e003..6f02fb20e 100644
--- a/v2v/inspect_source.ml
+++ b/v2v/inspect_source.ml
@@ -108,7 +108,7 @@ let rec inspect_source root_choice g =
 
 and choose_root root_choice g = function
   | [] ->
-     error (f_"inspection could not detect the source guest (or physical machine).\n\nAssuming that you are running virt-v2v/virt-p2v on a source which is supported (and not, for example, a blank disk), then this should not happen.  You should run 'virt-v2v -v -x ... >& log' and attach the complete log to a new bug report (see http://libguestfs.org).\n\nNo root device found in this operating system image.");
+     error (f_"inspection could not detect the source guest (or physical machine).\n\nAssuming that you are running virt-v2v/virt-p2v on a source which is supported (and not, for example, a blank disk), then this should not happen.\n\nNo root device found in this operating system image.");
   | [root] -> root (* only one root, so return it *)
   | roots ->
      (* If there are multiple roots, use the [--root] option supplied
@@ -212,5 +212,5 @@ and sanity_check_inspection inspect =
 
 and error_if_unknown fieldname value =
   if value = "unknown" then
-    error (f_"inspection could not detect the source guest (or physical machine).\n\nAssuming that you are running virt-v2v/virt-p2v on a source which is supported (and not, for example, a blank disk), then this should not happen.  You should run 'virt-v2v -v -x ... >& log' and attach the complete log to a new bug report (see http://libguestfs.org).\n\nInspection field '%s' was 'unknown'.")
+    error (f_"inspection could not detect the source guest (or physical machine).\n\nAssuming that you are running virt-v2v/virt-p2v on a source which is supported (and not, for example, a blank disk), then this should not happen.\n\nInspection field '%s' was 'unknown'.")
           fieldname
-- 
2.12.0


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]