USB thumb drive questio

Michael H. Warfield mhw at WittsEnd.com
Mon Apr 24 15:09:40 UTC 2006


On Mon, 2006-04-24 at 08:15 +0800, Stephen Liu wrote:
> Hi Mikkel,
> 
> > I find it strange that any drive of that size can not be formatted
> > FAT32. 

> I'm equally unresolved.  These 2 USB thumb drives can't be formatted as
> FAT 32.  I tried many times in past on FC3 box running;

> - fdisk to set the FS as FAT32 and then formatted it with vfat
> - mkfs -t FAT32

	I don't know what you've got on your system but I don't have a
mkfs.FAT32 (mkfs -t is merely a front end to mkfs.{type}).  I use
mkfs.vfat to creat vfat file systems.

	Note the following note from "man mkfs.vfat":

       -F FAT-size
              Specifies  the type of file allocation tables used (12, 16 or 32
              bit).  If  nothing  is  specified,  mkdosfs  will  automatically
              select  between  12  and  16  bit,  whatever fits better for the
              filesystem size.  32 bit FAT  (FAT32  format)  must  (still)  be
              selected explicitly if you want it.

	So, if you want FAT32, the correct command would be:

	"mkfs.vfat -F 32 /dev/sd{whatever}"

	What happens when you try that?

> "fdisk -l" only showed them as FAT16.  Would fdisk can't recognize
> FAT32?

	Fdisk is merely reporting the partition type.  Type 6 is FAT16.  That's
not the same thing as the file system time.  You can make an ext3/ext3
file system on a FAT16 partition type and Linux will probably be
perfectly happy about it (it doesn't care about the partition type)
while you will probably confuse the shit out of the BIOS or Windows
systems.

	It would not surprise me if some of the file systems utilities might
squawk about a partition type vs fs type mismatch.  Why don't you try
resetting that partition type to FAT32 LBA (code 0c) and see if that
then helps you get FAT32 to work?

	Just fdisk the drive and then use "t" to toggle a partition flag.  Just
follow the prompts and enter 0c for the type code.

	Then try making your file system and using it.

> > I could see where the BIOS might have a problem if it is
> > looking for a specific signature at the start of the drive. I would
> > think you could get around it for Grub by installing to the boot
> > record of the active partition instead of the MBR. 

> Could you pleae explain in more detail how to make it?  Tks.

	The BIOS could be fussy about the partition type.  I don't know what a
BIOS is going to do if the partition type says "FAT16" but it's a FAT32
file system.  Some may not care and may work fine.  I wouldn't bet good
money on all of them working, though.

> > I have no idea
> > why they wouldn't format as FAT32 though. That seems really strange
> > to me. But I have not used that brand, so maybe there is something
> > strange about them.
> 
> 
> They worked on FC3 without problem either for storage or for running
> "Linux on pendrive".  They booted on FC3 and the OS running on them
> worked similar to the OS running on HD or Live CD

	Linux really doesn't care much about the partition type.  It's going to
look for the file system signatures and, pretty much, ignore the
partition type codes in the partition tables.

	That being said, I have run into problems in creating bootable usb
drives.  Sometimes, you get a conflict between the CHS values the kernel
uses (and stores in the partition table) and the values the BIOS thinks
it sees and wants to use.  If those are not consistent, you won't be
able to create a bootable drive.  There's some funky parameters with
some boot utilities for dealing with that problem.  I found that while
googling for information on setting up bootable USB drives.  It doesn't
seem to affect all USB drives.  Only certain drives end up with this
strange dicotomy between what the BIOS things and what Linux thinks is
the drive geometry.  If you've got one of those drives, you've got to
get it configured right for what the BIOS thinks it wants or you'll
never get it to boot.

> B.R.
> SL

	Mike
-- 
Michael H. Warfield (AI4NB) | (770) 985-6132 |  mhw at WittsEnd.com
   /\/\|=mhw=|\/\/          | (678) 463-0932 |  http://www.wittsend.com/mhw/
   NIC whois: MHW9          | An optimist believes we live in the best of all
 PGP Key: 0xDF1DD471        | possible worlds.  A pessimist is sure of it!

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 307 bytes
Desc: This is a digitally signed message part
URL: <http://listman.redhat.com/archives/fedora-list/attachments/20060424/fb8b6570/attachment-0001.sig>


More information about the fedora-list mailing list