:: Re: [DNG] New goodies from systemd
Top Pagina
Delete this message
Reply to this message
Auteur: Steve Litt
Datum:  
Aan: dng
Onderwerp: Re: [DNG] New goodies from systemd
wirelessduck--- via Dng said on Tue, 8 Aug 2023 13:56:18 +1000

>> On 8 Aug 2023, at 01:38, al3xu5 via Dng <dng@???> wrote:
>>
>> What I would like to understand more deeply are the reasons why
>> currently a "pure" runit setup /under Devuan or other Debian-based
>> derivatives/ could be problematic.
>>
>> Is this just because the management of some system services is
>> missing with runit (missing service scripts)?
>> Or there are other reasons which made the hybrid mechanism necessary
>> for/during system initialization?
>> Or what else?
>>
>> Regards
>> alexus
>
>I think runit lacks the features to handle "oneshot" services. ie.
>something that runs once on startup and then exits, unlike regular
>daemons where runit will start it up and restart it if it
>crashes/stops.


Yes and no.

With runit, you can run oneshots to your heart's content, but they must
all be run before the first respawned daemon.

Wellll, the intermixing can actually be done, although it's a little
bit of a kludge. Many years ago I made LittKit, to enable Daemontools,
runit or s6 to intermix them and start them in a specific order. This
was before s6 had facilities to do what LittKit did.

LittKit:
http://troubleshooters.com/linux/diy/suckless_init_on_plop.htm#littkit_introduction

>
>This is something that s6 does support and I’m wondering if it would
>be reasonable to change focus from runit to s6 after the development
>of s6-frontend [1] is completed?


The preceding is a good question. I could argue either side of it.

One thing I *can* tell you is in the eight years I've used runit on
Void, I've never once needed to mix oneshots with respawns, and I've
never encountered a problem I could attribute to runit's obvious

>It is planned to support declarative
>service files a la systemd and a more simplified interface than the
>current collection of various individual s6-related tools.


Personally, I see no need for declarative syntax. Please remember, the
average runit or s6 run file is about 6 lines, and very few consume
more than 10 lines. It's hard to get simpler than that. And also keep
in mind that with runit or s6, you can design a test to see whether a
dependant service is not only up but doing its job. Declarative syntax
limits one, but shellscripts (or execline scripts or even compiled C
run scripts) enable one to do absolutely anything.

>
>There’s no definitive timeline on it yet so I guess we need to stay
>with runit+sysvinit for now.


Yes, and none of this means we can't later switch to s6. runit and s6
are **very** close cousins, with run scripts and commands that are
different from each other but have a one to one correspondence with
their corresponding commands.

>
>[1] https://skarnet.com/projects/s6/frontend/



SteveT

Steve Litt
Autumn 2022 featured book: Thriving in Tough Times
http://www.troubleshooters.com/bookstore/thrive.htm