Bug 290951

Summary: -todisk script can't mount partition
Product: [Fedora] Fedora Reporter: Bastien Nocera <bnocera>
Component: e2fsprogsAssignee: Eric Sandeen <esandeen>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: medium    
Version: rawhideCC: katzj, kzak
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: e2fsprogs-1.40.2-7.fc8 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-09-18 17:51:32 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
bug fix patch none

Description Bastien Nocera 2007-09-14 15:00:43 UTC
livecd-tools-011-1.fc8

# file -s /dev/sdb1 
/dev/sdb1: x86 boot sector; GRand Unified Bootloader, stage1 version 0x3, 1st
sector stage2 0x44ae, code offset 0x48, sectors/cluster 8, Media descriptor
0xf8, heads 4, sectors 3901408 (volumes > 32 MB) , physical drive 0xdb, physical
drive 0x5b, reserved 0xe, dos < 4.0 BootSector (0x0)

It's actually a vfat partition.

# sh -x /usr/bin/livecd-iso-to-disk ~hadess/Desktop/Fedora-7.91-Live-i686.iso
/dev/sdb1 
+ export PATH=/sbin:/usr/sbin:/usr/bin:/bin
+ PATH=/sbin:/usr/sbin:/usr/bin:/bin
++ id -u
+ '[' 0 '!=' 0 ']'
+ '[' 2 -ne 2 ']'
+ ISO=/home/hadess/Desktop/Fedora-7.91-Live-i686.iso
+ USBDEV=/dev/sdb1
+ '[' '!' -e /home/hadess/Desktop/Fedora-7.91-Live-i686.iso ']'
+ '[' '!' -b /dev/sdb1 ']'
++ mktemp -d /media/cdtmp.XXXXXX
+ CDMNT=/media/cdtmp.B10271
+ mount -o loop /home/hadess/Desktop/Fedora-7.91-Live-i686.iso /media/cdtmp.B10271
++ mktemp -d /media/usbdev.XXXXXX
+ USBMNT=/media/usbdev.r10275
+ mount /dev/sdb1 /media/usbdev.r10275
mount: you must specify the filesystem type
+ exitclean
+ echo 'Cleaning up to exit...'
Cleaning up to exit...
+ cleanup
+ '[' -d /media/cdtmp.B10271 ']'
+ umount /media/cdtmp.B10271
+ rmdir /media/cdtmp.B10271
+ '[' -d /media/usbdev.r10275 ']'
+ umount /media/usbdev.r10275
umount: /media/usbdev.r10275: not mounted
+ exit 1

After changing the mount to:
mount -t vfat...

I get:
+ syslinux -d syslinux /dev/sdb1
syslinux: this doesn't look like a valid FAT filesystem

Maybe it should give a better error that the filesystem doesn't seem appropriate
for the LiveCD from the start instead.

Comment 1 Matthias Clasen 2007-09-14 19:59:02 UTC
David, should we arrange for you to not own livecd-tools anymore ?

Comment 2 Jeremy Katz 2007-09-17 20:25:34 UTC
We do check the filesystem type...  I bet '/lib/udev/vol_id -t /dev/sdb1'
returns vfat?  If so, this is probably a mount (and syslinux) bug.

Comment 3 Bastien Nocera 2007-09-17 20:39:20 UTC
I had to completely wipe the key (including MBR) to be able to use it. It was
the Mandriva/GUADEC 2007 USB key, if one of the guys in the Desktop team hasn't
erased it yet...

Comment 4 Jeremy Katz 2007-09-17 21:23:57 UTC
Okay, got one from ajax that hasn't been wiped and can reproduce.  mount isn't
recognizing it, probably because of libblkid.  But to util-linux for the moment.  

Comment 5 Bastien Nocera 2007-09-17 22:36:16 UTC
Thanks for hunting this down Jeremy. I think it might also be a good idea for
the script to optionally "reset" the MBR properly, as this is what caused me to
have to wipe out the complete key. I'll file another bug about it.

Comment 6 Karel Zak 2007-09-17 23:42:49 UTC
Please, Bastien, try:

   # blkid -c /dev/null /dev/sdb1
   # rpm -q util-linux-ng


Comment 7 Jeremy Katz 2007-09-18 00:02:02 UTC
Karel -- Bastien's disk is hosed.  I've got one plugged in at the box at my
desk.    Email coming separately with access info.

Comment 8 Karel Zak 2007-09-18 13:39:17 UTC
Created attachment 198361 [details]
bug fix patch

The patch is against actual Ted's e2fsprogs repo. I'm going to send this patch
to upstream.

Comment 9 Eric Sandeen 2007-09-18 15:40:16 UTC
Karel, thanks.  Is this one urgent, or can I wait 'til I see it go upstream?  I
assume it should be in before test3, eh.

Comment 10 Jeremy Katz 2007-09-18 16:38:41 UTC
Definitely would be nice to have in test3

Comment 11 Eric Sandeen 2007-09-18 16:41:22 UTC
Ok, I'll toss it in now.  Will keep my eye out for that upstream submission... :)

Comment 12 Eric Sandeen 2007-09-18 17:51:32 UTC
Ok, e2fsprogs-1.40.2-7.fc8 building now.

Thanks,
-Eric

Comment 13 Eric Sandeen 2007-11-27 04:53:36 UTC
Could anyone with the aforementioned Mandriva USB key dd of the first few K of
it, and attach, so I could re-test something?  Looks like this fix broke
something else.

Thanks,

-Eric