OpenWrt Forum Archive

Topic: Mount FAT USB Stick in Kami 7.07

The content of this topic has been archived on 6 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

I just upgraded to Kamikaze 7.07 and I'm trying to mount a USB memory stick with FAT16 formatting. With all the required packages installed except cp437 I get this failure to mount:

root@OpenWrt:~# mount -t vfat /dev/sda1 /mnt
mount: mounting /dev/sda1 on /mnt failed
root@OpenWrt:~#

I was able to load all the packages except kmod-nls-cp437. I get the following error:

root@OpenWrt:~# ipkg install kmod-nls-cp437
Installing kmod-nls-cp437 (2.6.19.2-brcm47xx-1) to root...
Downloading http://downloads.x-wrt.org/xwrt/kamikaze/snapshots/brcm47xx-2.6/packages/./kmod-nls-cp437_2.6.19.2-brcm47xx-1_mipsel.ipk
Not downgrading package kernel on root from 2.6.22-brcm47xx-1 to 2.6.19.2-brcm47xx-1.
Nothing to be done
An error ocurred, return value: 1.

I realize the package is for kamikaze 7.06, but is cp437 included under 7.07 as the error message implies?

Is there any work around to get the memory stick mounted?

Thanks for the help,

Rob

Try removing the x-wrt package source and then run the command again. ipkg seems to be mixing up the order

My problem above was caused by Kamikaze 7.07 using repositories for Kami 7.06 and linux 2.6.19.2. After deleting the two old repositories I was able to load the 2.6.22 versions of kmod-nls-base and cp437 but I still can't mount the USB memory stick. Here's what I have:

My installed packages:

root@OpenWrt:~# ipkg list_installed
base-files-brcm47xx-2.6 - 9-8182 -
bridge - 1.0.6-1 -
busybox - 1.4.2-2 -
dnsmasq - 2.38-1 -
dropbear - 0.49-2 -
ez-ipupdate - 3.0.11b8-2 -
fdisk - 2.12r-2 -
haserl - 0.8.0-1 -
hotplug2 - 0.9+r102-1 -
iptables - 1.3.7-1 -
kernel - 2.6.22-brcm47xx-1 -
kmod-diag - 1+2.6.22-brcm47xx-1 -
kmod-fs-vfat - 2.6.22-brcm47xx-1 -
kmod-madwifi - 2.6.22+r2568-20070710-brcm47xx-1 -
kmod-nls-base - 2.6.22-brcm47xx-1 -
kmod-nls-cp437 - 2.6.22-brcm47xx-1 -
kmod-ppp - 2.6.22-brcm47xx-1 -
kmod-pppoe - 2.6.22-brcm47xx-1 -
kmod-scsi-core - 2.6.22-brcm47xx-1 -
kmod-switch - 2.6.22-brcm47xx-1 -
kmod-usb-core - 2.6.22-brcm47xx-1 -
kmod-usb-storage - 2.6.22-brcm47xx-1 -
kmod-usb-uhci - 2.6.22-brcm47xx-1 -
kmod-usb2 - 2.6.22-brcm47xx-1 -
libgcc - 4.1.2-9 -
libpcre - 7.0-1 -
libpthread - 0.9.28-9 -
libsqlite3 - 3.3.3-1 -
libxml2 - 2.6.20-1 -
mtd - 5 -
ppp - 2.4.3-7 -
ppp-mod-pppoe - 2.4.3-7 -
uclibc - 0.9.28-9 -
udevtrigger - 106-1 -
vsftpd - 2.0.5-1 -
webif - 0.3-6 -
wireless-tools - 29-1 -
zlib - 1.2.3-3 -
Done.
root@OpenWrt:~#

fdisk -l

root@OpenWrt:~# fdisk -l

Disk /dev/sda: 125 MB, 125370368 bytes
4 heads, 32 sectors/track, 1913 cylinders
Units = cylinders of 128 * 512 = 65536 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        1913      122382+   6  FAT16
root@OpenWrt:~#

Mount:

root@OpenWrt:~# mount -t vfat /dev/sda1 /mnt
mount: mounting /dev/sda1 on /mnt failed
root@OpenWrt:~#

Anyone see what's causing the mount of a fat16 USB memory stick to fail?

Thanks again for the help.

Rob

I installed kmod-fs-msdos and the USB memory stick would mount as a msdos disk with its 8.3 file name limitations. For some reason kmod-fs-vfat isn't working for me. I reformatted the USB stick as an ext3 disk and now it mounts and automounts properly.

Rob

I still can't mount a fat USB memory stick under Kamikaze 7.07. I had no problems with Kami 7.06 with the same packages installed. Anyone see a problem with my setup above that would allow msdos and ext3 to mount but not vfat? Thanks again for the help.

Rob

ive got the same problem! and no answer for it ^^

(Last edited by darkza on 2 Aug 2007, 21:20)

I gave up and used ext3 as the file system. The USB stick mounts at boot without problem.

It seems that the Broadcom 47xx 2.6 kmod-fs-vfat package is simply broken.

Rob

(Last edited by robrob on 25 Sep 2007, 02:32)

root@OpenWrt:~# fdisk -l

Disk /dev/sda: 125 MB, 125370368 bytes
4 heads, 32 sectors/track, 1913 cylinders
Units = cylinders of 128 * 512 = 65536 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1        1913      122382+   6  FAT16
root@OpenWrt:~#

Maybe the filesystem id is not good for vfat. neutral
Try out with id = "b" (W95 FAT32)

sr

(Last edited by silveraid on 14 Aug 2007, 18:23)

Hi Rob!

How did you get the USB-Drive formatted ext3? I've been trying to get that done for hours.
I can add a partition with fdisk, I can format the system with ext3, but as soon as it gets to mount the drive, I get a failure.
Even stranger, when I plug the USB Drive to my Windows System, it tells me its a FAT32 Filesystem.
Any idea?

root@OpenWrt:~# fdisk -l                                     

Disk /dev/scsi/host0/bus0/target0/lun0/disc: 1040 MB, 1040187392 bytes
32 heads, 62 sectors/track, 1024 cylinders
Units = cylinders of 1984 * 512 = 1015808 bytes

                                 Device Boot      Start         End      Blocks   Id  System
/dev/scsi/host0/bus0/target0/lun0/part1               1        1024     1015777   83  Linux






root@OpenWrt:~# mkfs.ext3 /dev/scsi/host0/bus0/target0/lun0/part1
mke2fs 1.39 (29-May-2006)
Filesystem label=
OS type: Linux
Block size=1024 (log=0)
Fragment size=1024 (log=0)
126976 inodes, 1015776 blocks
50788 blocks (5.00%) reserved for the super user
First data block=1
124 block groups
8192 blocks per group, 8192 fragments per group
1024 inodes per group
Superblock backups stored on blocks:
        8193, 24577, 40961, 57345, 73729, 204801, 221185, 401409, 663553

Writing inode tables: done                           
Creating journal (16384 blocks): done
Writing superblocks and filesystem accounting information: done

This filesystem will be automatically checked every 25 mounts or
180 days, whichever comes first.  Use tune2fs -c or -i to override.

root@OpenWrt:~# fdisk -l

Disk /dev/scsi/host0/bus0/target0/lun0/disc: 1040 MB, 1040187392 bytes
32 heads, 62 sectors/track, 1024 cylinders
Units = cylinders of 1984 * 512 = 1015808 bytes

                                 Device Boot      Start         End      Blocks   Id  System
/dev/scsi/host0/bus0/target0/lun0/part1               1        1024     1015777   83  Linux
root@OpenWrt:~# mount -t ext3 /dev/scsi/host0/bus0/target0/lun0/part1 /mnt/usbstick/
mount: mounting /dev/scsi/host0/bus0/target0/lun0/part1 on /mnt/usbstick/ failed





root@OpenWrt:~# mount -t ext3 /dev/scsi/host0/bus0/target0/lun0/part1 /mnt/usbstick/
mount: mounting /dev/scsi/host0/bus0/target0/lun0/part1 on /mnt/usbstick/ failed





root@OpenWrt:~# ipkg list_installed

base-files-brcm-2.4 - 9-8182 -
bridge - 1.0.6-1 -
busybox - 1.4.2-2 -
cfdisk - 2.12r-2 -
dnsmasq - 2.38-1 -
dropbear - 0.49-2 -
e2fsprogs - 1.39-1 -
fdisk - 2.12r-2 -
iptables - 1.3.7-1 -
kernel - 2.4.34-brcm-1 -
kmod-brcm-wl - 2.4.34+4.80.53.0-1 -
kmod-diag - 1+2.4.34-brcm-1 -
kmod-fs-msdos - 2.4.34-brcm-1 -
kmod-fs-vfat - 2.4.34-brcm-1 -
kmod-ipt-nathelper - 2.4.34-brcm-1 -
kmod-nls-cp437 - 2.4.34-brcm-1 -
kmod-nls-iso8859-1 - 2.4.34-brcm-1 -
kmod-ppp - 2.4.34-brcm-1 -
kmod-pppoe - 2.4.34-brcm-1 -
kmod-scsi-core - 2.4.34-brcm-1 -
kmod-switch - 2.4.34-brcm-1 -
kmod-usb-core - 2.4.34-brcm-1 -
kmod-usb-ohci - 2.4.34-brcm-1 -
kmod-usb-storage - 2.4.34-brcm-1 -
kmod-usb-uhci - 2.4.34-brcm-1 -
kmod-usb2 - 2.4.34-brcm-1 -
kmod-wlcompat - 2.4.34+brcm-5 -
libgcc - 3.4.6-9 -
libncurses - 5.6-1 -
libuuid - 1.39-1 -
mtd - 5 -
nas - 4.80.53.0-1 -
nvram - 1 -
ppp - 2.4.3-7 -
ppp-mod-pppoe - 2.4.3-7 -
uclibc - 0.9.28-9 -
wireless-tools - 29-1 -
wlc - 4.80.53.0-1 -
Done.



brgs, Matt

Little addition to my last post:
When I format the Drive FAT32 under WinXP and insert it to the Router (btw Asus WL-500g Premium) I can mount it, write on it without any issue.
But I'd actually like to get the USB memory stick running under ext3 for adding file admission control for different users.
OS.: Kamikaze 7.07
Need any more information?
brgs, Matt

Kami 7.07, Asus WL-500gP.

kmod-fs-vfat work normally IMHO. I install kmod-nls-437 and kmod-nls-iso*, so can mount FAT stick, and navigate through it.

But is any way to obtain smth. nls-1251, nls-866 ???. And how I can pass information about codepage to "mount"?

Best way IMHO is to install kmod-nls-437 and kmod-nls-utf8, use utf8 ssh (for example PuTTY) and mount drive with:
root@OpenWrt:/mnt# mount -t vfat -o iocharset=utf8 /dev/sda1 /mnt

Ohhh!!! Samba 2.0 cant support utf8 :-((((
So I install kmod-nls-koi8r and change:
root@OpenWrt:/mnt# mount -t vfat -o iocharset=koi8-r /dev/sda1 /mnt

(Last edited by ansov on 22 Sep 2007, 18:51)

The discussion might have continued from here.