1 Useful concepts 1.1 System initialisation 1.1.1 Chainloading 1.1.2 Properties of PID 1 1.1.2.1 Signal handling 1.1.2.2 exit() and exec() 1.1.3 Aside: history of init [init-hist] 1.2 Process supervision 1.2.1 Requirements [s6-ov] 1.2.1.1 Auto restart 1.2.1.2 Be itself supervised # The need to be rooted in PID 1 1.2.2 Main choices 1.2.2.1 No supervision, or with PID files, or with /etc/inittab and /etc/ttys 1.2.2.2 monit and supervisord; upstart and systemd 1.2.2.3 daemontools(-encore), runit, perp, s6 and nosh 1.2.3 Aside: the supervision mail list [sv-ml] 1.3 Notification without running a service [ftrig] 2 Anatomy of s6 / s6-rc 2.1 Supervision: s6-supervise and s6-svscan 2.1.1 Configuration and runtime control [s6-ov] 2.1.2 Readiness notification 2.2 RC: s6-rc 2.2.1 Chainloading and execline 2.2.2 Service directory deployment 2.2.3 Why no OR dependencies for now [or-dep] 2.3 Service logging 2.3.1 s6-svscan as init: the fd-holding black magic 2.3.2 s6-fdholder # Restart of s6-fdholder [fh-restart] 2.3.3 s6-log and ucspilogd # /dev/log: SOCK_STREAM and SOCK_DGRAM [log-dgram] 2.3.4 The good parts of "socket activation" [s6-sa] 2.4 The DJB legacy and the Plan 9 spirit 2.4.1 File system as the channel 2.4.2 library organisation, eg. buffer.h <-> bio.h 2.4.3 A glance at the source code 3 A simplified example of s6 / s6-rc deployment 3.1 "Refined" phases of init; "runlevel" emulation with s6-rc 3.2 emptyenv -p with setproctitle; dcron with nosetsid 3.4 Shuffling of fd in ucspilogd's ./run 3.3 Instanced supervision # A hybrid of execline and shell? [el-hybrid] 3.5 Aside: comparison of init scripts [run-comp] -- [el-hybrid] [ftrig] [fh-restart] [init-hist] [log-dgram] [run-comp] [or-dep] [s6-sa] [s6-ov] [sv-ml]