Re: What's the difference between s6 and s6-rc?

From: Jan Bramkamp <crest_at_rlwinm.de>
Date: Thu, 25 Feb 2016 16:01:15 +0100

On 25/02/16 15:47, Steve Litt wrote:
> Hi all,
>
> Could somebody, in one or two sentences, tell me the difference between
> s6 vs s6-init?

For the subject i infer that you're asking for the difference between s6
and s6-rc because there is no project or binary named s6-init.

> I'm not looking for references to big old documents: I'm looking for
> one or two sentences telling me the difference.

s6 is a collection of tools. Together these tools implement service
supervision. One of those tools is s6-svscan. It scans a service
directory and starts one s6-supervise process per service. It can also
serve as pid 1 (aka init) of a unix system.

While s6 is a good service supervisor on its own it lacks service
management. s6 can only track running processes and offers no ordering
between them. You can block in a ./run script until all your
dependencies are fulfilled or just exit and retry until it works.
Writing this logic in every ./run script is a burden on the user but
manageable.

On its own s6 can't track state not represented by a running process
e.g. a mounted file system. This forces a system booting with just s6 to
run a (possibly very small) script before s6-svscan can take over.
Dependencies can only be modeled between running processes. This is good
enough for small embedded devices or (most) systems run by a very
experienced user willing to tinker with his boot process.

s6-rc builds on top of s6 to provide support for state tracking and
changing on top of s6. It does this in a surprisingly safe, clean and
simple way. This in turn makes it hard to understand because s6-rc is
just an empty hull. You still have to write your own start code fitting
into its structure. The s6 linux init repo contains an example of how it
could look like.
Received on Thu Feb 25 2016 - 15:01:15 UTC

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