Bug 1039995

Summary: virt-make-fs fails making fat/vfat whole disk: Device partition expected, not making filesystem on entire device '/dev/sda' (use -I to override)
Product: [Community] Virtualization Tools Reporter: Richard W.M. Jones <rjones>
Component: libguestfsAssignee: Richard W.M. Jones <rjones>
Status: CLOSED UPSTREAM QA Contact:
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: unspecifiedCC: acathrow, mbooth, ptoscano
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-12-10 16:41:31 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Richard W.M. Jones 2013-12-10 13:27:45 UTC
Description of problem:

$ virt-make-fs --type=fat . /tmp/test.img
'mkfs' (create filesystem) operation failed.
Instead of 'fat', try 'vfat' (long filenames) or 'msdos' (short filenames).
mkfs: fat: /dev/sda: mkfs.fat: Device partition expected, not making filesystem on entire device '/dev/sda' (use -I to override) at /usr/bin/virt-make-fs line 508, <PIPE> line 1.
	...propagated at /usr/bin/virt-make-fs line 518, <PIPE> line 1.

It looks as if the 'mkfs' command requires -I when the
filesystem type is fat/vfat/etc to force it to work.

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

libguestfs 1.25.8

How reproducible:

100%

Steps to Reproduce:

See command above.

Comment 1 Richard W.M. Jones 2013-12-10 13:48:39 UTC
Patch posted:
https://www.redhat.com/archives/libguestfs/2013-December/msg00058.html

Comment 2 Richard W.M. Jones 2013-12-10 16:41:31 UTC
This is fixed upstream:
https://github.com/libguestfs/libguestfs/commit/b1210152217b35f52f204a1d92ee988ca713949c

The fix should appear in libguestfs >= 1.25.14 and >= 1.24.3.