:: Re: [DNG] Various init systems and …
Top Page
Delete this message
Reply to this message
Author: Steve Litt
Date:  
To: dng
Subject: Re: [DNG] Various init systems and process supervision: openrc, runit, ...
Hendrik Boom said on Sat, 13 Dec 2025 11:58:59 -0500

>What are the reasons for choosig operc vs runit?


I'm biased, so please take that into account. I'm so in love with runit
my wife is jealous.

AFAIK, openrc uses ginormous init scripts similar to those of sysvinit.
Runit's run scripts are usually less than 10 lines: Often less than 5.

If I remember correctly, Openrc requires the daemon to background
itself. This makes it much more difficult to write your own daemon than
if it's initted with runit. With runit, you just make your daemon a
regular program like you'd run on the command line, and runit's runsv
program supervises it. I understand that Openrc now has socket
activation, and I'm pretty sure runit doesn't. That's not a big deal
though: We've had xinetd forever to do that job. And runit is much,
much simpler.

>
>I gather runit uses djb's process supervision.


Runit's "stage 2", which is the process supervisor, works pretty much
the same as djb's daemontools program.

>What does openrc use?


I don't know. Perhaps ask ChatGPT "how does openrc work?"

>Or better, where can I find documentation outlining the
>strategies used by these various init systems?


I'd join the Supervision mailing list. supervision@???

>And are there others I should look into?


You bet. Runit and Epoch are the simplest. Epoch doesn't start
processes in parallel, which I don't care about. It requires daemons to
background themselves, which I do care about.

Runit has the theoretical disadvantage of not guaranteeing the order in
which daemons start up, except when you code for dependencies. This
sounds like it would be a problem, but fact is that in my 10 years of
using runit every day this has never once caused a problem.

The Cadillac of the industry is s6, which is another daemontools
inspired init system, but with a lot more features. And you can set up
s6 to start daemons in a specific order.

There's another daemontools inspired init system called Perp. I've
never tried it. Another one called nosh, which is written in C++ (ugh).
I gave up on it when I couldn't get it to build.

I hear there's one called systemd that takes over your whole computer,
but other than the fact that it has an April Fools architecture I know
little about it.

The Supervision mailing list is your friend in these things.

SteveT

Steve Litt

http://444domains.com