Subject: RE: initialization order & permanently mounting USB drives?
To: James Hartley <email@example.com>
From: De Zeurkous <firstname.lastname@example.org>
Date: 09/10/2007 22:36:28
On Mon, September 10, 2007 21:44, James Hartley wrote:
> On 9/10/07, Steven M. Bellovin <email@example.com> wrote:
> As a result, I have three more questions -- two related & the other not:
> 0. Should USB device initialization be more deterministic/serial? Or
> does the addition of this delay to fsck(8) merely mask a deeper
The generic problem with automagic discovery is the coerced relationship
between a device and its connection path -- even replacing a trivial (say,
a switch) node in said path can (and often will) cause the path to change,
and thus affect discovery order. What we need is a way to map a device
according to it's hardware address to an interface, and have the kernel
wait (and possibly timeout waiting) for a device to be discovered before
giving the go-ahead for the fsck and subsequent mount(s). It's the only
way to fix this in the long run.
Unfortunately, this also means that when a device is replaced (say, a
faulty disk with a working one), the mapping needs to be adjusted manually
(although some magic may detect live replacement, it's not very reliable
and won't work dead). This is not fixable without fixing the applicable
protocols to enable the assignment of some luser-set ID. The mapping
described above is the best we can do in that regard.