Re: How to supervise an early process [s6-svscan root pivot]

From: Steve Litt <>
Date: Tue, 21 Jun 2016 13:36:38 -0400

On Tue, 21 Jun 2016 14:45:59 +0200
Laurent Bercot <> wrote:

> Generally speaking, you shouldn't run any long-lived process before
> pivot_rooting or switch_rooting. The structure of the filesystem is
> too important an assumption to be modified behind people's (or
> daemon's) backs. Fortunately, there's really no need to do that: the
> early initialization that happens in an initramfs is oneshot-only,
> and your real "init" is always run after the pivot_root happens;
> that's the moment when you can spawn long-lived processes.

I agree. I bet everyone on this list agrees. Trouble is, a certain
bunch are busy cramming more and more, into initramfs, that has nothing
to do with mounting the root partition and getting to /etc. From my
limited experience, modifying the initramfs is VERY difficult to get
right, so removing the "extraneous stuff" might be difficult.

> There's obviously one exception: udevd. Some systems need it to
> coldplug devices, in order to find the correct device to pivot_root
> on.

In my last email I kidded around with you about this subject, but on a
more serious note, doesn't the bootloader config already contain the
info to know which device, and isn't that device mounted before the
initramfs does the switch_root or pivot_root? What do they need udevd
for? They have the UUID, for gosh sakes.

Steve Litt
June 2016 featured book: Troubleshooting: Why Bother?
Received on Tue Jun 21 2016 - 17:36:38 UTC

This archive was generated by hypermail 2.3.0 : Sun May 09 2021 - 19:44:19 UTC