[wellylug] linux usb
Ewen McNeill
wellylug at ewen.mcneill.gen.nz
Tue Sep 16 21:51:29 NZST 2003
In message <MJEJLFGONMIKNBKPBAENCEPGCDAA.uulug at falcons.co.nz>, "Ian Beardslee" w
rites:
>I'm having 'interesting' problems with a USB Flash drive, sometimes it
>works and sometimes it doesn't.
If you're using Linux 2.4 (or IIRC Linux 2.2) the major tricks to making
a USB Flash drive work reliably are:
- plug it in directly, not via an extension lead (I've found that flash
drives plugged in via an extension lead often stop responding,
presumably due to power issues); and
- ideally build the USB support and SCSI support as modules, and if
possible unload sd_mod, usb-storage, etc after removing the device.
(Rescanning the SCSI bus in remove mode works fine for my Firewire
drive enclosure, but doesn't seem to do the trick for USB alas.)
The issue you're seeing with inserting/removing/reinserting is that what
was /dev/sda* the first time around becomes /dev/sdb the second time
around (because you had a /dev/sda when you reinserted it, so you get
the next SCSI device, and so on). By unloading the sd_mod, usb-storage,
etc modules the kernel "forgets" it previously had any SCSI devices,
and you can insert again just fine.
It's a bit frustrating, but tolerable for the occasional use. (If I
were doing it often I'd probably automate it -- there is a USB unplug
even that goes through to hotplug IIRC.)
More information about the wellylug
mailing list