Bug 591142

Summary: virt-inspector should give an error for unrecognized disk images
Product: [Community] Virtualization Tools Reporter: Richard W.M. Jones <rjones>
Component: libguestfsAssignee: Richard W.M. Jones <rjones>
Severity: high Docs Contact:
Priority: high    
Version: unspecifiedCC: mbooth, virt-maint, yuzhang
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-07-14 19:07:45 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Richard W.M. Jones 2010-05-11 14:32:48 UTC
Description of problem:

If you run virt-inspector on something which isn't a disk image (or is blank
or random) then it runs and produces no output and no error.

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. virt-inspector /dev/zero
2. echo $?
Actual results:

Status is 0 and no error.

Expected results:

An error message.

Additional info:

Comment 1 Richard W.M. Jones 2010-05-12 17:17:31 UTC
Patch posted upstream:


$ virt-inspector /dev/zero 
No operating system could be detected inside this disk image.

This may be because the file is not a disk image, or is not a virtual machine
image, or because the OS type is not understood by virt-inspector.

If you feel this is an error, please file a bug report including as much
information about the disk image as possible.
$ echo $?

Comment 2 Fedora Update System 2010-05-14 19:12:37 UTC
libguestfs-1.2.6-1.fc13 has been submitted as an update for Fedora 13.

Comment 3 Fedora Update System 2010-05-17 12:28:01 UTC
libguestfs-1.2.7-1.fc12 has been submitted as an update for Fedora 12.

Comment 4 Fedora Update System 2010-05-17 12:47:50 UTC
libguestfs-1.2.7-1.el5 has been submitted as an update for Fedora EPEL 5.

Comment 5 Fedora Update System 2010-05-17 13:00:16 UTC
libguestfs-1.2.7-2.fc13 has been submitted as an update for Fedora 13.

Comment 6 Fedora Update System 2010-05-21 11:33:30 UTC
libguestfs-1.2.7-2.fc13.1 has been submitted as an update for Fedora 13.