[systemd-devel] Need help with a systemd/mdadm interaction.

Zbigniew Jędrzejewski-Szmek zbyszek at in.waw.pl
Tue Nov 12 05:52:43 PST 2013


On Tue, Nov 12, 2013 at 09:17:19PM +1100, NeilBrown wrote:
> On Tue, 12 Nov 2013 18:16:24 +0900 Greg KH <gregkh at linuxfoundation.org> wrote:
> > Not for USB, sorry.
> > 
> > The USB bus just announces devices when it finds them, there is no "all
> > is quiet" type signal or detection.
> > 
> > Same for PCI hotplug, devices can show up at any point in time, you
> > never know when, and you don't know when all devices are "found".
> 
> Hmmm... OK.  USB doesn't bother me a lot, but PCI is important.
> 
> I guess I'll just have to settle for a timeout much like the current
> device-discovery timeout that systemd has.
> Still hoping someone can tell me how to plug into that though...
I think you'll have to replicate the waiting logic internally. udev
will tell you about new devices, but systemd by itself doesn't know
what devices are part of the raid set, so can't help with knowing
when enough physical volumes have been found, either for degraded more
or for normal mode. Just make sure to set your timeout to something
lower than systemd, i.e. have timeout-waiting-for-normal-set <
timeout-waiting-for-degraded-set < systemd-timeout-for-device.

Zbyszek



More information about the systemd-devel mailing list