root@OpenWrt:~# opkg install kmod-usb-storage - to get mass storage capability for our router
root@OpenWrt:~# opkg install kmod-fs-ext4 - to get our filesystem type supported. BTW, I recommend use ext4. You can also use FAT, FAT32, even NTFS (however linux drivers for NTFS are, let say... ok... NTFS is not open source and all Linux drivers are hacks and reverse engeniering, so better not use NTFS, especially if you want to keep precious data).
We can now test with mount command, if we are able to mount our USB disc somewhere. Alternatively I recommend to use blkid to list all what is avaiable: root@OpenWrt:~# blkid
/dev/sda4: UUID="e3e38a66-7d58-4ffc-b7c3-e75e4ed0d71e"
/dev/sda3: UUID="6cfe70bf-fc7a-4e1c-9f6b-e2dbcfd09cff"
/dev/sda2: UUID="043b3612-2c10-4ae5-b69f-1a9dfccf5a59"
/dev/sda1: UUID="7ddcca2b-31ec-4ce3-9f55-3c4c7776a123"
To be able to mount our disc automatically, we need some scripts:
root@OpenWrt:/etc# opkg install b-mount
root@OpenWrt:/etc# opkg install b-hotplug
root@OpenWrt:/etc/init.d# ./fstab enable
Now we can tweak the file /etc/config/fstab to make things work:
config global automount
option from_fstab 1
option anon_mount 0
config global autoswap
option from_fstab 1
option anon_swap 0
config mount
option target /mnt/sda4
option device /dev/sda4
option fstype ext4
option options rw,sync
option enabled 1
option enabled_fsck 0
config swap
option device /dev/sda2
option enabled 0