[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Advanced Startup/Shutdown with Multilayered Block Devices and Related Issues

Petter Reinholdtsen <pere@hungry.com> writes:
> [Goswin von Brederlow]
>> There is one big problem with an event based startup. Specifically for
>> raid1/4/5/6 devices. Those you can use just fine with missing devices but
>> the boot should really wait for all device to be present.
> This problem is not specific for event based startup.  It also exist with
> the current sequence based boot system.  There are heaps of setups that fail
> to boot because the required are missing when the init.d script using them
> are running during boot.  The only known solution today is to add a long
> delay during boot to try to increase the chance of having all devices
> available when they are needed. :(
>> The big question is how long do you wait?

Please, for the love of everything sane, ask a low priority debconf question
with a default of five minutes[1] — and display a note in the initramfs about
what you are waiting for, and how long.

(Actually, the countdown from the DRBD init script, including the prompt to
 override the configured wait time, would be absolutely wonderful to have
 here, since it gives excellent feedback, a good UI to bypass things, and is
 generally quite informative.)

>> How do you detect that a device is actually broken/missing and its event
>> will never come? You can't even check if there are any pending events
>> (udev-settle) because the device might be slow to start (e.g. a disk on a
>> SATA port multiplier or SCSI with delayed spin up or external enclosures)
>> and no event has yet been initialized for it.
> Yeah.  With the current Linux kernel, I am not aware of any way to
> answer these questions. :(

You can't answer them, ever, for some busses: there is no possible way to
determine that you have completed enumeration of a USB bus.  ATAoE, and iSCSI
present similar problems.  It just can't be done.

So, eventually you have to accept that you either wait, or give up, for as
long as the owner of the machine will accept.

(Especially if what you are waiting for is, oh, the second machine in your
 DRBD pair to boot.  Not that I have an agenda or anything. ;)


[1]  Long enough for most things to boot, short enough that an admin who can't
     read will not go entirely crazy waiting.

✣ Daniel Pittman            ✉ daniel@rimspace.net            ☎ +61 401 155 707
               ♽ made with 100 percent post-consumer electrons

Reply to: