[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: VFAT: Very stupid question

Hi Greg,

greg wrote:

I try to mount a VFAT USB key on my Debian/pure64 distro without any success:

root@grodeb:/home/greg\> mount -t vfat /dev/sda1 /media/usb/
mount: wrong fs type, bad option, bad superblock on /dev/sda1,
       or too many mounted file systems

I can mount the key on a ix86 32 bit system.
I don't think this is an USB problem, because I can mount the key when it's ext2 formated, all
modules related to USB are loaded etc etc.
I don't have any VFAT HD partition to make tests.
I tried with FAT (msdos), same problem.

I had a similar problem with my USB stick. The reason
was that the stick was formatted with very unusual

I would suggest to use fdisk on linux (amd64 should do)
to erase the partition table and to create a new partition.
Then format it using mkfs.msdos.

So here is my question: is there someone here, who can mount VFAT or FAT with the
kernel-image-2.6.8-amd64 ?

To verify the FAT filesystem on your machine you could
create a filesystem in an image file, e.g.:

mkfs.msdos -i "${DOS_VOLUME_ID}" -n "${DOS_VOLUME_LABEL}" -C "${FLASH_IMG}" "${FLOPPY_SIZE}"
mcopy -nom -i"${FLASH_IMG}" somefiles ::

modprobe loop
modprobe vfat
mount -o loop ${FLASH_IMG} /mnt
ls -al /mnt
umount /mnt

See the man page of mkfs.msdos for additional options.

FLOPPY_SIZE is chosen for a 256 MByte USB stick. You can
write the image to USB using

cat $FLASH_IMG >/dev/sda

But this is _extremely_ dangerous especially if there
are other SCSI devices in your system. And it will
overwrite the partition table.

Good luck


Reply to: