Red Hat Bugzilla – Bug 668115
virt-filesystems command fails on guest with corrupt filesystem label
Last modified: 2015-09-27 22:22:55 EDT
+++ This bug was initially created as a clone of Bug #668112 +++ Description of problem: virt-filesystems -d Ubuntu1010x64 --long --all -h libguestfs: error: vfs_label: /dev/vda2: Version-Release number of selected component (if applicable): libguestfs-1.8.0-1.fc14.x86_64 --- Additional comment from rjones@redhat.com on 2011-01-07 17:39:16 EST --- Created attachment 472310 [details] virt-filesystems -v -x output Full output from the command: virt-filesystems -d Ubuntu1010x64 --long --all -h -v -x --- Additional comment from rjones@redhat.com on 2011-01-07 17:43:41 EST --- /dev/vda2 is an extended partition (containing a logical partition which is the swap). Therefore it doesn't make sense to run guestfs_vfs_label on it. We should just ignore the result of vfs_label if it's an error.
Reproducer: $ guestfish -N part exit $ virt-filesystems -a test1.img --all --long -h libguestfs: error: vfs_label: /dev/vda1: When the bug is fixed it produces the following output instead: $ guestfish -N part exit $ virt-filesystems -a test1.img --all --long -h Name Type VFS Label Size Parent /dev/sda1 filesystem unknown - 100M - /dev/sda1 partition - - 100M /dev/sda /dev/sda device - - 100M -
Fix posted upstream: http://git.annexia.org/?p=libguestfs.git;a=commitdiff;h=97339a0f43d687efac6f7edafdf21e4b8d9b35e8
Following the steps in Comment 1: Reproduce the issue with libguestfs-1.7.17-4.el6: # guestfish -N part exit # virt-filesystems -a test1.img --all --long -h libguestfs: error: vfs_label: /dev/vda1: Verfied the issue with libguestfs-1.7.17-10.el6: # virt-filesystems -a test1.img --all --long -h Name Type VFS Label Size Parent /dev/sda1 filesystem unknown - 100M - /dev/sda1 partition - - 100M /dev/sda /dev/sda device - - 100M - According to the result above, move to VERIFIED.
Technical note added. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. New Contents: The virt-filesystems command failed when used against a guest without a label. This command has been updated to handle guest file systems without labels. Note that this bug was reported and corrected during development. It was not seen in production systems in the field.
Technical note updated. If any revisions are required, please edit the "Technical Notes" field accordingly. All revisions will be proofread by the Engineering Content Services team. Diffed Contents: @@ -1,3 +1,3 @@ -The virt-filesystems command failed when used against a guest without a label. This command has been updated to handle guest file systems without labels. +The virt-filesystems command failed when used on a guest which had a missing or corrupt file system label. This command has been updated to handle guest file systems with missing or corrupt file system labels. Note that this bug was reported and corrected during development. It was not seen in production systems in the field.
I updated the technical notes field.
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2011-0586.html