Bug 824043 - guestfish unrecognized mount option gives confusing error message
Summary: guestfish unrecognized mount option gives confusing error message
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libguestfs
Version: unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Richard W.M. Jones
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-05-22 15:47 UTC by Richard W.M. Jones
Modified: 2012-05-24 13:55 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-05-24 13:55:42 UTC
Embargoed:


Attachments (Terms of Use)

Description Richard W.M. Jones 2012-05-22 15:47:01 UTC
Description of problem:

$ guestfish --ro -a /dev/vg_pin/F16x64 -m /dev/vda2:/

Welcome to guestfish, the libguestfs filesystem interactive shell for
editing virtual machine filesystems.

Type: 'help' for help on commands
      'man' to read the manual
      'quit' to quit the shell

><fs> exit

$ guestfish --ro -a /dev/vg_pin/F16x64 -m /dev/vda2:/:blahblah
libguestfs: error: mount_options: /dev/vda2 on /: mount: wrong fs type, bad option, bad superblock on /dev/vda2,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail or so
guestfish: '/dev/vda2' could not be mounted.  Did you mean one of these?
	/dev/sda1 (unknown)
	/dev/sda2 (ext4)
	/dev/vg_f16x64/lv_root (ext4)
	/dev/vg_f16x64/lv_swap (swap)

The error message is confusing and wrong here.  It should at least
hint that the mount option could be causing the problem.

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

1.18.0.

How reproducible:

100%

Steps to Reproduce:
1. See above.

Comment 1 Richard W.M. Jones 2012-05-24 13:55:42 UTC
Fixed in commit ee9ab52bc3e087f63dcc51d3b6ac5c79277425e1.

The new error message is one of these 3 variations:


$ guestfish --ro -a /dev/vg_data/F16x64 -m /dev/vda2:/:blahblah
libguestfs: error: mount_options: /dev/vda2 on / (options: 'blahblah'): mount: wrong fs type, bad option, bad superblock on /dev/vda2,
       missing codepage or helper program, or other error
       In some cases useful info is found in syslog - try
       dmesg | tail or so
guestfish: '/dev/vda2' could not be mounted.
guestfish: Check mount(8) man page to ensure options 'blahblah'
guestfish: are supported by the filesystem that is being mounted.
guestfish: Did you mean to mount one of these filesystems?
guestfish: 	/dev/sda1 (unknown)
guestfish: 	/dev/sda2 (ext4)
guestfish: 	/dev/vg_f16x64/lv_root (ext4)
guestfish: 	/dev/vg_f16x64/lv_swap (swap)


$ guestfish --ro -a /dev/vg_data/F16x64 -m /dev/vg_f16x64/lv_swap:/
libguestfs: error: mount_options: /dev/vg_f16x64/lv_swap on / (options: 'ro'): mount: unknown filesystem type 'swap'
guestfish: '/dev/vg_f16x64/lv_swap' could not be mounted.
guestfish: Did you mean to mount one of these filesystems?
guestfish: 	/dev/sda1 (unknown)
guestfish: 	/dev/sda2 (ext4)
guestfish: 	/dev/vg_f16x64/lv_root (ext4)
guestfish: 	/dev/vg_f16x64/lv_swap (swap)


$ guestfish --ro -a /dev/vg_data/F16x64 -m /dev/vda8:/
libguestfs: error: mount_options: mount_options_stub: /dev/vda8: No such file or directory
guestfish: '/dev/vda8' could not be mounted.
guestfish: Did you mean to mount one of these filesystems?
guestfish: 	/dev/sda1 (unknown)
guestfish: 	/dev/sda2 (ext4)
guestfish: 	/dev/vg_f16x64/lv_root (ext4)
guestfish: 	/dev/vg_f16x64/lv_swap (swap)


Note You need to log in before you can comment on or make changes to this bug.