Alternatives to systemd

From Without Systemd
(Difference between revisions)
Jump to: navigation, search
m (updated some latest release dates)
m (update link for distro specific blog article)
 
(58 intermediate revisions by 2 users not shown)
Line 55: Line 55:
 
| OpenWrt init and process/service management daemon with ubus integration
 
| OpenWrt init and process/service management daemon with ubus integration
 
| 2018-07-30
 
| 2018-07-30
  +
|-
  +
| [https://github.com/pygos Pygos] [https://github.com/pygos/init init]
  +
| Small and quite simple init with task/service ordering used in [https://github.com/pygos Pygos GNU/Linux] (config and init script [https://github.com/pygos/init-scripts examples])
  +
| 2018-11-25
 
|-
 
|-
 
| [https://skarnet.org/software/s6-linux-init/ s6-linux-init] ([https://github.com/skarnet/s6-linux-init 2])
 
| [https://skarnet.org/software/s6-linux-init/ s6-linux-init] ([https://github.com/skarnet/s6-linux-init 2])
Line 70: Line 74:
 
| [https://savannah.nongnu.org/projects/sysvinit SysV init] ([http://download.savannah.nongnu.org/releases/sysvinit/ 2])
 
| [https://savannah.nongnu.org/projects/sysvinit SysV init] ([http://download.savannah.nongnu.org/releases/sysvinit/ 2])
 
| the traditional Linux System V init clone
 
| the traditional Linux System V init clone
| 2018-11-24
+
| 2019-02-25
 
|-
 
|-
 
| [http://landley.net/toybox/ ToyBox] init ([https://github.com/landley/toybox 2])
 
| [http://landley.net/toybox/ ToyBox] init ([https://github.com/landley/toybox 2])
Line 104: Line 108:
 
| 2003-11-14
 
| 2003-11-14
 
|-
 
|-
| [https://sourceforge.net/projects/depinit depinit]
+
| [http://depinit.sourceforge.net/ depinit] ([https://sourceforge.net/projects/depinit 2])
 
| supports parallel execution, dependencies, true roll-back, log pipelines, improved signaling, and unmounting of filesystems on shutdown
 
| supports parallel execution, dependencies, true roll-back, log pipelines, improved signaling, and unmounting of filesystems on shutdown
 
| 2003-10-06
 
| 2003-10-06
Line 119: Line 123:
 
| C++ init daemon supporting dependency tracking akin to the "[http://www.safe-mbox.com/~rgooch/linux/boot-scripts/index.html need]" concept
 
| C++ init daemon supporting dependency tracking akin to the "[http://www.safe-mbox.com/~rgooch/linux/boot-scripts/index.html need]" concept
 
| 2003-04-22
 
| 2003-04-22
  +
|-
  +
| [http://www.pell.portland.or.us/~mastodon/ Mastodon] [http://www.pell.portland.or.us/~orc/Code/init/ init]
  +
| init with service ordering/dependency tracking resembling the "[http://www.safe-mbox.com/%7Ergooch/linux/boot-scripts/ need]" concept; was part of [http://www.pell.portland.or.us/~mastodon/ Mastodon Linux]
  +
| 2002-07-29
 
|-
 
|-
 
| [http://www.fefe.de/minit/ minit]
 
| [http://www.fefe.de/minit/ minit]
Line 140: Line 148:
 
| 2002-08-06
 
| 2002-08-06
 
|-
 
|-
| simpleinit(-msb)
+
| [https://mirror.sobukus.de/simpleinit-msb simpleinit(-msb)] ([https://mirror.sobukus.de/files/sourcemage/codex/test/smgl/simpleinit-msb/ 2])
| dependency based (implements the "[http://www.safe-mbox.com/%7Ergooch/linux/boot-scripts/ need]" concept) sequential init without proper supervision (respawn only, no output logging); shipped with util-linux until v2.20; the msb fork is still used in [http://sourcemage.org/Init Source Mage] Linux
+
| dependency based (implements the "[http://www.safe-mbox.com/%7Ergooch/linux/boot-scripts/ need]" concept) sequential init without proper supervision (respawn only, no output logging); shipped with util-linux until v2.20; the [https://mirror.sobukus.de/simpleinit-msb msb fork] is still used in [https://sourcemage.org/Init Source Mage Linux] ([https://mirror.sobukus.de/files/sourcemage/codex/test/smgl/init.d/ 2])
 
| 2007-11-08
 
| 2007-11-08
 
|-
 
|-
Line 171: Line 179:
 
! Latest release
 
! Latest release
 
|-
 
|-
| [http://repo.obarun.org/66/ 66] ([https://framagit.org/Obarun/66/ 2])
+
| [http://web.obarun.org/software/ 66] ([https://framagit.org/Obarun/66 2])
 
| [http://skarnet.org/software/s6-rc/ s6-rc] enhancement utils providing extended service management capabilities
 
| [http://skarnet.org/software/s6-rc/ s6-rc] enhancement utils providing extended service management capabilities
| 2018-11-20
+
| 2019-03-14
 
|-
 
|-
 
| [https://jjacky.com/anopa/ anopa] ([https://github.com/jjk-jacky/anopa 2])
 
| [https://jjacky.com/anopa/ anopa] ([https://github.com/jjk-jacky/anopa 2])
Line 217: Line 225:
 
| [https://github.com/OpenRC/openrc OpenRC] ([https://wiki.gentoo.org/wiki/OpenRC 2])
 
| [https://github.com/OpenRC/openrc OpenRC] ([https://wiki.gentoo.org/wiki/OpenRC 2])
 
| dependency based service management suite; contains a process supervisor and a simple init alternative
 
| dependency based service management suite; contains a process supervisor and a simple init alternative
| 2018-12-05
+
| 2019-02-26
 
|-
 
|-
 
| [http://b0llix.net/perp/ perp]
 
| [http://b0llix.net/perp/ perp]
Line 236: Line 244:
 
|-
 
|-
 
| [http://skarnet.org/software/s6/ s6] ([https://github.com/skarnet/s6 2])
 
| [http://skarnet.org/software/s6/ s6] ([https://github.com/skarnet/s6 2])
| small process supervision suite for UNIX ala daemontools, runit, and perp; can be used as stage 2 of process #1 via [http://skarnet.org/software/s6/s6-svscan-1.html exec chaining]
+
| small process supervision suite for UNIX ala daemontools, runit, and perp; supports service "[http://skarnet.org/software/s6/notifywhenup.html readiness notification]" and "[http://skarnet.org/software/s6/socket-activation.html fd holding]"; can also be used as "stage 2" of process #1 via [http://skarnet.org/software/s6/s6-svscan-1.html exec chaining]
| 2018-11-14
+
| 2019-03-04
 
|-
 
|-
 
| [http://skarnet.org/software/s6-rc/ s6-rc] ([https://github.com/skarnet/s6-rc 2])
 
| [http://skarnet.org/software/s6-rc/ s6-rc] ([https://github.com/skarnet/s6-rc 2])
 
| service management suite for [http://skarnet.org/software/s6/ s6]
 
| service management suite for [http://skarnet.org/software/s6/ s6]
| 2018-08-14
+
| 2019-03-04
 
|-
 
|-
 
| [https://www.gnu.org/software/shepherd/ shepherd]
 
| [https://www.gnu.org/software/shepherd/ shepherd]
Line 268: Line 276:
 
|}
 
|}
   
== SysV init enhancement addons ==
+
== Dependency ordering of interdependent init scripts ==
   
  +
Tools that help with dependency ordering of interdependent init scripts
  +
(e. g. by organizing the ordering of symlinks to the real rc scripts
  +
in SysV runlevel (sub)direcetories (usually stored in /etc/rc.d))
  +
and concurrent execution of (non-interdependent) init scripts
  +
to speed up system startup and thereby reduce boot times.
  +
  +
<!--
  +
preliminary new/renamed section, will be improved soon, so expect further edits
  +
-->
 
{| class="wikitable sortable"
 
{| class="wikitable sortable"
! System
+
! Tool
 
! Description
 
! Description
 
! Latest release
 
! Latest release
 
|-
 
|-
| [https://savannah.nongnu.org/projects/sysvinit insserv]
+
| [https://savannah.nongnu.org/projects/sysvinit insserv] ([http://download.savannah.nongnu.org/releases/sysvinit/ 2])
| can be used with SysV -based init systems; provides dependency-driven system startup (dependencies are specified by LSB headers within init.d scripts)
+
| used when installing new service scripts to update the order of symlinks pointing to them from all SysV runlevel (sub)directories according to [http://refspecs.linuxfoundation.org/LSB_5.0.0/LSB-Core-generic/LSB-Core-generic/tocsysinit.html LSB] dependency specifications within comment lines located at the top of those scripts ([http://refspecs.linuxfoundation.org/LSB_5.0.0/LSB-Core-generic/LSB-Core-generic/initscrcomconv.html LSB headers])
| 2012-11-14
+
| 2019-02-25
 
|-
 
|-
| [https://savannah.nongnu.org/projects/sysvinit startpar]
+
| [https://github.com/OpenRC/openrc OpenRC]
| can be used by the SysV RC boot system executor to allow parallel process system startup
+
| uses the "'''depend'''" shell function to specify dependencies between its rc scripts and also uses (sub)directories (usually of /etc/runlevels) to define runlevels (service groups/bundles) and symlinks therein to the service scripts they use
| 2014-02-09
+
| 2019-02-26
  +
|-
  +
| [http://netbsd.gw.com/cgi-bin/man-cgi?rcorder++NetBSD-current rcorder] ([https://leaf.dragonflybsd.org/cgi/web-man?command=rcorder&section=ANY 2], [https://www.freebsd.org/cgi/man.cgi?query=rcorder&apropos=0&sektion=0&manpath=FreeBSD+12.0-RELEASE+and+Ports&arch=default&format=html 3])
  +
| used in [http://netbsd.org/ NetBSD], [https://www.freebsd.org/ FreeBSD], and [http://www.dragonflybsd.org/ DragonFly BSD] by the /etc/rc shell script to generate a dependency ordered sequence of service scripts in the /etc/rc.d and /usr/local/etc/rc.d directories
  +
| 2018-10-27
  +
|-
  +
| [http://fastboot.org/ serel] ([https://sourceforge.net/projects/serel/ 2])
  +
| works akin to startpar ('''defunct''' project)
  +
| 2002-08-06
  +
|-
  +
| [https://savannah.nongnu.org/projects/sysvinit startpar] ([http://download.savannah.nongnu.org/releases/sysvinit/ 2])
  +
| used within the main SysV runlevel executor rc script (usually /etc/rc.d/rc) to start a SysV runlevel's (non-interdependent) service scripts concurrently
  +
| 2019-02-25
 
|}
 
|}
   
== Safer, supervision-friendly replacements for crond and atd ==
+
== Simple, reliable, supervision-friendly logging ==
  +
  +
Simple, safe, reliable, and supervision-friendly logging tools
  +
are listed below since systemd also provides such features
  +
in its impertinent attempt to oust independent solutions and thereby suck
  +
otherwise unrelated functionality into the init system to
  +
enforce the usage of its own confined straitjacket framework.
  +
  +
With [http://jdebp.info/Softwares/nosh/ nosh] and
  +
[http://skarnet.org/software/s6-rc/s6-rc-compile.html s6-rc]
  +
whole log funnels/pipelines are possible, e. g. multiple log stages
  +
and fan-in. [https://sourceforge.net/projects/depinit/ depinit]
  +
provided similar functionality even directly in process #1.
  +
[http://www.fefe.de/minit/ minit] and ninit also provide service
  +
standard output/error redirection and logger supervision akin to
  +
[http://untroubled.org/daemontools-encore/svscan.8.html svscan]
  +
directly in process #1.
  +
  +
<!-- TODO:
  +
Add usyslog
  +
-->
  +
{| class="wikitable sortable"
  +
! Tool
  +
! Description
  +
! Latest release
  +
|-
  +
| [http://jdebp.info/Softwares/nosh/guide/commands/cyclog.xml cyclog]
  +
| logs its standard input to multiple directories of rotated log files; part of the [http://jdebp.info/Softwares/nosh/ nosh] service and system management suite
  +
| 2019-03-20
  +
|-
  +
| [http://offog.org/code/freedt/ dumblog]
  +
| logs standard input to a file; part of the [http://offog.org/code/freedt/ freedt] [http://cr.yp.to/daemontools.html daemontools] reimplementation
  +
| 2014-09-03
  +
|-
  +
| [http://www.untroubled.org/daemontools-encore/multilog.8.html multilog] ([http://cr.yp.to/daemontools/multilog.html 2])
  +
| logs standard input to a directory of rotated log files; part of [http://cr.yp.to/daemontools.html daemontools](-[http://www.untroubled.org/daemontools-encore/ encore])
  +
| 2018-10-14
  +
|-
  +
| [http://www.untroubled.org/daemontools-encore/multipipe.8.html multipipe]
  +
| pipes standard input to a set of programs; part of [http://www.untroubled.org/daemontools-encore/ daemontools-encore]
  +
| 2018-10-14
  +
|-
  +
| [http://skarnet.org/software/s6/s6-log.html s6-log]
  +
| logs standard input to a directory of rotated log files; part of the [http://skarnet.org/software/s6/ s6] supervision suite
  +
| 2019-03-04
  +
|-
  +
| [http://b0llix.net/perp/site.cgi?page=sissylog.8 sissylog]
  +
| logs standard input to syslog; part of the [http://b0llix.net/perp/ perp] supervision suite
  +
| 2013-01-11
  +
|-
  +
| [http://smarden.org/socklog/ socklog]
  +
| small, simple, reliable, and secure system and kernel logging (syslogd/klogd) services for the [http://smarden.org/runit/ runit] supervision suite
  +
| 2006-03-06
  +
|-
  +
| [http://www.smarden.org/runit/svlogd.8.html svlogd]
  +
| logs standard input to a directory of rotated log files; part of the [http://www.smarden.org/runit/ runit] supervision suite
  +
| 2014-08-10
  +
|-
  +
| [http://b0llix.net/perp/site.cgi?page=tinylog.8 tinylog]
  +
| logs standard input to a directory of rotated log files; part of the [http://b0llix.net/perp/ perp] supervision suite
  +
| 2013-01-11
  +
|-
  +
| [http://skarnet.org/software/s6/ucspilogd.html ucspilogd]
  +
| converts syslog facility numbers and alert levels into names; part of the [http://skarnet.org/software/s6/ s6] supervision suite
  +
| 2019-03-04
  +
|}
  +
  +
Replacements for syslogd and klogd:
  +
  +
* [http://smarden.org/runit/ runit] + [http://smarden.org/runit/svlogd.8.html svlogd] + [http://smarden.org/socklog/ socklog]
  +
* [http://skarnet.org/software/s6/ s6] + [http://skarnet.org/software/s6/s6-log.html s6-log] + [http://skarnet.org/software/s6/s6-ipcserver.html s6-ipcserver] + [http://skarnet.org/software/s6/ucspilogd.html ucspilogd]
  +
  +
== Simple supervision-friendly time-based job schedulers ==
   
Simpler, supervision-friendly crond/atd replacements
+
Simpler, safer, more reliable, supervision-friendly alternatives to
listed below since systemd provides its own job scheduling capabilities
+
crond and atd for time-based periodically job scheduling tasks are
in its weird attempt to oust independent solutions and thereby suck
+
listed below since systemd also provides such capabilities
  +
in its impertinent attempt to oust independent solutions and thereby suck
 
otherwise unrelated functionality into the init system to
 
otherwise unrelated functionality into the init system to
 
enforce the usage of its own confined straitjacket framework
 
enforce the usage of its own confined straitjacket framework
 
(ninit can also spawn services on specified dates or time intervals
 
(ninit can also spawn services on specified dates or time intervals
if one really wants to use process #1 for that purpose).
+
if one really wants to (ab)use process #1 for that purpose).
   
 
{| class="wikitable sortable"
 
{| class="wikitable sortable"
Line 307: Line 324:
 
| 2016-10-30
 
| 2016-10-30
 
|-
 
|-
| [https://www.ohse.de/uwe/uschedule.html uschedule]
+
| [https://www.ohse.de/uwe/uschedule.html uschedule] ([http://jdebp.info/Softwares/uschedule/ 2])
| job scheduling suite that uses separate tools for different tasks
+
| job scheduling suite that uses separate tools for different tasks; an updated/improved package that works well with the [http://jdebp.info/Softwares/nosh/ nosh supervision suite] can be downloaded [http://jdebp.info/Softwares/uschedule/ here]
| 2004-08-??
+
| 2004-08-16
 
|}
 
|}
   
== inetd alternatives ==
+
== inetd super-server alternatives ==
   
 
Simpler, safer, supervision-friendly, and more reliable replacements
 
Simpler, safer, supervision-friendly, and more reliable replacements
Line 323: Line 340:
 
APIs and tools upon every single Linux distro and user
 
APIs and tools upon every single Linux distro and user
 
(finit provides a builtin inetd for those who need such capabilities in process #1).
 
(finit provides a builtin inetd for those who need such capabilities in process #1).
  +
  +
Please also read this [http://cr.yp.to/proto/ucspi.txt UCSPI]
  +
[http://jdebp.info/FGA/UCSPI.html overview]
  +
and the [http://skarnet.org/software/s6/ s6] "fd holding"
  +
[http://skarnet.org/software/s6/socket-activation.html guide]
  +
(versus
  +
"[http://0pointer.de/blog/projects/socket-activation.html socket activation]").
   
 
{| class="wikitable sortable"
 
{| class="wikitable sortable"
! System
+
! Tool
 
! Description
 
! Description
 
! Latest release
 
! Latest release
Line 343: Line 367:
 
| [http://offog.org/code/onenetd/ onenetd]
 
| [http://offog.org/code/onenetd/ onenetd]
 
| TCP-only [http://cr.yp.to/proto/ucspi.txt UCSPI] server supporting concurrency limits and IPv6
 
| TCP-only [http://cr.yp.to/proto/ucspi.txt UCSPI] server supporting concurrency limits and IPv6
| 2017-01-24
+
| 2014-06-21
 
|-
 
|-
 
| [http://skarnet.org/software/s6/s6-ipcserver.html s6-ipcserver]
 
| [http://skarnet.org/software/s6/s6-ipcserver.html s6-ipcserver]
Line 352: Line 376:
 
| small [http://cr.yp.to/proto/ucspi.txt UCSPI] networking suite that provides access controls, concurrency limits, IPv6, and TLS/SSL
 
| small [http://cr.yp.to/proto/ucspi.txt UCSPI] networking suite that provides access controls, concurrency limits, IPv6, and TLS/SSL
 
| 2018-08-15
 
| 2018-08-15
  +
|-
  +
| [http://www.superscript.com/ucspi-ipc/ ucspi-ipc]
  +
| command-line tools for building [http://cr.yp.to/proto/ucspi.txt UCSPI] client-server applications that use local unix-domain sockets and support concurrency limits and access restrictions based on client E(G,U)ID (via [http://www.superscript.com/ucspi-ipc/getpeereid.html getpeereid()])
  +
| 2005-05-27
 
|-
 
|-
 
| [http://cr.yp.to/ucspi-tcp.html ucspi-tcp]
 
| [http://cr.yp.to/ucspi-tcp.html ucspi-tcp]
Line 366: Line 394:
 
|}
 
|}
   
== udev alternatives for automatic Linux device file creation and management ==
+
== Linux device managers ==
   
[[Wikipedia:udev|udev]] (userspace /dev) is a device manager for the Linux kernel.
+
The [[Wikipedia:udev|udev]] daemon is a user space device manager for the Linux kernel.
  +
It is used for automatic device node management
  +
(including creating needed device files and symlinks pointing to them,
  +
loading required kernel modules and firmware)
  +
in the devtmpfs mounted on /dev.
   
In April 2012, udev's source code was merged into the systemd source tree.[http://article.gmane.org/gmane.linux.hotplug.devel/17392]
+
In April 2012, udev's source code was
  +
[http://article.gmane.org/gmane.linux.hotplug.devel/17392 merged]
  +
into the systemd source tree.
   
Although udev can still be compiled for usage without systemd, Lennart Poettering said that they will not polish udevd outside of
+
Although it can still be compiled for usage without systemd, Lennart Poettering
systemd[https://lists.freedesktop.org/archives/systemd-devel/2012-August/006066.html], adding:
+
said that they will not polish udev outside of systemd
  +
[https://lists.freedesktop.org/archives/systemd-devel/2012-August/006066.html], adding:
   
 
:"<i>Yes, udev on non-systemd systems is in our eyes a dead end, in case you haven't noticed it yet. I am looking forward to the day when we can drop that support entirely.</i>"
 
:"<i>Yes, udev on non-systemd systems is in our eyes a dead end, in case you haven't noticed it yet. I am looking forward to the day when we can drop that support entirely.</i>"
Line 414: Line 442:
 
|}
 
|}
   
For more see [https://unix.stackexchange.com/questions/161674/are-there-alternatives-to-using-udev this] StackExchange question.
+
For more read [https://unix.stackexchange.com/questions/161674/are-there-alternatives-to-using-udev this thread] on StackExchange.
   
Related helper tool: [http://ignorantguru.github.io/udevil/ udevil] ([https://github.com/IgnorantGuru/udevil 2]) (un)mounts removable devices without a password, shows device info, and monitors device changes.
+
'''Related helper utility:'''
  +
  +
[http://ignorantguru.github.io/udevil/ udevil] ([https://github.com/IgnorantGuru/udevil 2]) (un)mounts removable devices without a password, shows device info, and monitors device changes.
 
It can also mount ISO files, nfs://, smb://, ftp:, ssh:// and WebDAV URLs, and tmpfs/ramfs filesystems.
 
It can also mount ISO files, nfs://, smb://, ftp:, ssh:// and WebDAV URLs, and tmpfs/ramfs filesystems.
 
Uses Glib and libudev (i. e. requires (e)udev) and can work
 
Uses Glib and libudev (i. e. requires (e)udev) and can work
 
completely without systemd, consolekit, policykit, dbus, udisks, gvfs & fuse (although it can coexist with any of these).
 
completely without systemd, consolekit, policykit, dbus, udisks, gvfs & fuse (although it can coexist with any of these).
   
== See also ==
+
== Hints, intros, instructions, guides, and tutorials ==
  +
  +
* [[NinitInstructions|Hints]] on how to build, install, configure, and use [https://gitlab.com/notklaatu/ninit ninit] as default init
  +
* [https://cromer.cl/2017/01/28/s6-with-openrc/ How] to replace your current init with [http://skarnet.org/software/s6/s6-svscan-1.html s6] ([http://skarnet.org/software/s6-linux-init/ 2]) + [https://github.com/OpenRC/openrc OpenRC] (in place of [http://skarnet.org/software/s6-rc/ s6-rc])
  +
* [http://www.troubleshooters.com/linux/init/manjaro_experiments.htm Hints] on how to replace your current init with [https://universe2.us/epoch.html epoch] and [http://smarden.org/runit/ runit]
  +
<!-- seems to be somewhat outdated, contains dead links, the "minirc" project is not hosted on nongnu.org anymore, too minimal ? ;-)
  +
found a "minirc" repo on github instead.
  +
-->
  +
* [https://bbs.archlinux.org/viewtopic.php?id=162606 How] to replace systemd with BusyBox init and [https://github.com/hut/minirc minirc]
  +
* [http://cr.yp.to/daemontools.html daemontools](-[http://untroubled.org/daemontools-encore/ encore]) [http://troubleshooters.com/linux/djbdns/daemontools_intro.htm intro]
  +
* [http://skarnet.org/software/s6/socket-activation.html How] to perform socket activation with [http://skarnet.org/software/s6/ s6]
  +
* [https://wiki.archlinux.org/index.php/Acpid How] ([https://wiki.gentoo.org/wiki/ACPI 2]) to configure and use the Linux ACPI event handling daemon [https://sourceforge.net/projects/acpid2/ acpid2] for power management instead of systemd
  +
  +
'''Distro-specific guides:'''
  +
  +
* [https://abchk1234.wordpress.com/2014/06/03/using-openrc-on-arch-archbang-manjaro-linux/ Using OpenRC on Arch Linux]
  +
* [https://exherbo.org/docs/without-systemd.html How to remove systemd from an Exherbo GNU/Linux installation]
  +
  +
== Articles in other wikis ==
  +
  +
[https://www.archlinux.org/ Arch Linux] [https://wiki.archlinux.org/ wiki]
  +
  +
* [https://wiki.archlinux.org/index.php/Acpid Arch wiki :: acpid]
  +
* [https://wiki.archlinux.org/index.php/Init Arch wiki :: init]
  +
* [https://wiki.archlinux.org/index.php/OpenRC Arch wiki :: OpenRC]
  +
* [https://wiki.archlinux.org/index.php/SysVinit Arch wiki :: SysV init]
  +
  +
[https://artixlinux.org/ Artix Linux] [https://wiki.artixlinux.org/ wiki]
  +
  +
* [https://wiki.artixlinux.org/Main/OpenRC Artix wiki :: OpenRC]
  +
* [https://wiki.artixlinux.org/Main/Runit Artix wiki :: runit]
  +
  +
[https://gentoo.org/ Gentoo Linux] [https://wiki.gentoo.org/ wiki]
   
 
* [https://wiki.gentoo.org/wiki/Comparison_of_init_systems Gentoo wiki :: init system feature comparison table]
 
* [https://wiki.gentoo.org/wiki/Comparison_of_init_systems Gentoo wiki :: init system feature comparison table]
 
* [https://wiki.gentoo.org/index.php?title=Talk:Comparison_of_init_systems&oldid=166938 Gentoo wiki :: more detailed init system feature comparison table]
 
* [https://wiki.gentoo.org/index.php?title=Talk:Comparison_of_init_systems&oldid=166938 Gentoo wiki :: more detailed init system feature comparison table]
  +
* [https://wiki.gentoo.org/wiki/Init_system Gentoo wiki :: supported init systems]
  +
* [https://wiki.gentoo.org/wiki/Sysvinit Gentoo wiki :: SysV init]
  +
* [https://wiki.gentoo.org/wiki/OpenRC Gentoo wiki :: OpenRC]
  +
* [https://wiki.gentoo.org/wiki/Process-Supervision Gentoo wiki :: process supervision]
  +
* [https://wiki.gentoo.org/wiki/Daemontools-encore Gentoo wiki :: daemontools-encore]
  +
* [https://wiki.gentoo.org/wiki/Runit Gentoo wiki :: runit]
  +
* [https://wiki.gentoo.org/wiki/S6_and_s6-rc-based_init_system Gentoo wiki :: s6(-rc)]
  +
* [https://wiki.gentoo.org/wiki/ACPI Gentoo wiki :: acpid]
  +
  +
[https://manjaro.org/ Manjaro Linux] [https://wiki.manjaro.org/ wiki]
  +
  +
* [https://wiki.manjaro.org/index.php?title=OpenRC,_an_alternative_to_systemd Manjaro wiki :: OpenRC] ([[OpenRC, an alternative to systemd|local copy]])
  +
  +
[https://obarun.org/ Obarun Linux] [https://wiki.obarun.org/ wiki]
  +
  +
* [https://wiki.obarun.org/doku.php?id=s6-boot Obarun wiki :: s6-boot]
  +
* [https://wiki.obarun.org/doku.php?id=s6services Obarun wiki :: s6-services]
  +
  +
[https://voidlinux.org/ Void Linux] [https://wiki.voidlinux.org/ wiki]
  +
  +
* [https://wiki.voidlinux.org/Runit Void wiki :: runit]
  +
  +
== See also ==
  +
  +
'''General information:'''
  +
 
* [http://blog.darknedgy.net/technology/2015/09/05/0/ A history of modern init systems (1992-2015)]
 
* [http://blog.darknedgy.net/technology/2015/09/05/0/ A history of modern init systems (1992-2015)]
 
* [http://cloux.org/init/ init systems overview]
 
* [http://cloux.org/init/ init systems overview]
Line 431: Line 485:
 
* Process supervision: Problem apparently [http://jtimberman.housepub.org/blog/2012/12/29/process-supervision-solved-problem/ solved]
 
* Process supervision: Problem apparently [http://jtimberman.housepub.org/blog/2012/12/29/process-supervision-solved-problem/ solved]
 
* How [http://skarnet.org/software/s6/overview.html process supervision] and [http://skarnet.org/software/s6-rc/why.html service management] differ (according to Laurent Bercot, author of s6(-rc))
 
* How [http://skarnet.org/software/s6/overview.html process supervision] and [http://skarnet.org/software/s6-rc/why.html service management] differ (according to Laurent Bercot, author of s6(-rc))
  +
* [https://jdebp.eu/FGA/unix-daemon-design-mistakes-to-avoid.html Designing] supervision-friendly [[Wikipedia:Daemon_(computing)|Unix daemons]]
   
<b>Init-specific articles:</b>
+
'''More specific articles and resources:'''
   
 
* [http://linuxmafia.com/faq/Admin/init.html Understanding SysV init]
 
* [http://linuxmafia.com/faq/Admin/init.html Understanding SysV init]
* The [http://www.safe-mbox.com/%7Ergooch/linux/boot-scripts/ need] concept (as implemented in simpleinit)
+
* SysV init [[Wikipedia:runlevel|runlevel usage]] in major distros/Unices
* [http://upstart.ubuntu.com/ Upstart] [https://bugs.launchpad.net/upstart/+bug/1756318 leaks] [https://launchpadlibrarian.net/360903157/top.png memory] (reported on 2018-03-16, still no reaction whatsoever)
+
* The "[http://www.safe-mbox.com/%7Ergooch/linux/boot-scripts/ need]" concept (as implemented in simpleinit)
* [[NinitInstructions|Hints]] on how to build, install, configure, and use [https://gitlab.com/notklaatu/ninit ninit] as your default init
+
* An [http://jdebp.eu/FGA/daemontools-family.html overview] of [http://cr.yp.to/daemontools.html daemontools] ([http://untroubled.org/daemontools-encore/ 2]) family supervision suites
* [http://www.troubleshooters.com/linux/init/manjaro_experiments.htm Hints] on how to replace your current init with [https://universe2.us/epoch.html epoch] and [http://smarden.org/runit/ runit]
 
* [https://wiki.manjaro.org/index.php?title=OpenRC,_an_alternative_to_systemd Manjaro wiki :: OpenRC] ([[OpenRC, an alternative to systemd|local copy]])
 
* [https://wiki.gentoo.org/wiki/Init_system Gentoo wiki :: supported init systems]
 
* [https://wiki.gentoo.org/wiki/Sysvinit Gentoo wiki :: SysV init]
 
* [https://wiki.gentoo.org/wiki/OpenRC Gentoo wiki :: OpenRC]
 
* [https://wiki.gentoo.org/wiki/Runit Gentoo wiki :: runit]
 
* [https://wiki.gentoo.org/wiki/S6_and_s6-rc-based_init_system Gentoo wiki :: s6(-rc)]
 
* [https://abchk.in/2014/06/using-openrc-on-arch-archbang-manjaro-linux/ guide: Using OpenRC on Arch Linux]
 
* [https://wiki.voidlinux.org/Runit VoidLinux wiki :: runit]
 
* [https://wiki.obarun.org/doku.php?id=s6-boot Obarun wiki :: s6-boot]
 
* [https://bbs.archlinux.org/viewtopic.php?id=162606 Replace systemd with busybox + minirc]
 
* [https://exherbo.org/docs/without-systemd.html How to remove systemd from an Exherbo GNU/Linux installation]
 
* [http://cr.yp.to/daemontools.html daemontools] [http://troubleshooters.com/linux/djbdns/daemontools_intro.htm intro]
 
* An [http://jdebp.eu/FGA/daemontools-family.html overview] of daemontools family supervision suites
 
* [http://skarnet.org/software/s6/socket-activation.html Hints on how to perform socket activation with s6]
 
 
* [http://skarnet.org/software/s6/s6-svscan-1.html s6 init scheme] ([http://skarnet.org/software/s6-linux-init/ 2]): Exec chaining into different "init stages"
 
* [http://skarnet.org/software/s6/s6-svscan-1.html s6 init scheme] ([http://skarnet.org/software/s6-linux-init/ 2]): Exec chaining into different "init stages"
 
* [http://smarden.org/runit/replaceinit.html runit init scheme] ([http://smarden.org/runit/runit.8.html 2], [http://smarden.org/runit/runit-init.8.html 3]): Process #1 starts (and supervises) 3 subprocesses implementing different "init stages"
 
* [http://smarden.org/runit/replaceinit.html runit init scheme] ([http://smarden.org/runit/runit.8.html 2], [http://smarden.org/runit/runit-init.8.html 3]): Process #1 starts (and supervises) 3 subprocesses implementing different "init stages"
* Simpler, more reliable, supervision-friendly alternatives to syslogd and klogd: [http://skarnet.org/software/s6/ s6] + [http://skarnet.org/software/s6/s6-ipcserver.html s6-ipcserver] + [http://skarnet.org/software/s6/ucspilogd.html ucspilogd] + [http://skarnet.org/software/s6/s6-log.html s6-log] or [http://smarden.org/runit/ runit] + [http://smarden.org/socklog/ socklog]
+
* [[Wikipedia:IBM_AIX|AIX]] [https://www.ibm.com/support/knowledgecenter/ssw_aix_72/com.ibm.aix.genprogc/src.htm SRC (System Resource Controller)] (probably the first (1992) modern daemon supervisor and service management (aka "subsystem controller") framework)
  +
* [[Wikipedia:Solaris_(operating_system)|Solaris]] [https://docs.oracle.com/cd/E53394_01/html/E54799/index.html SMF (Service Management Facility)]
  +
* [[Wikipedia:macos|macOS]] [[Wikipedia:launchd|launchd]] [https://developer.apple.com/library/archive/documentation/MacOSX/Conceptual/BPSystemStartup/ docs]
  +
* [http://upstart.ubuntu.com/ Upstart] [https://bugs.launchpad.net/upstart/+bug/1756318 leaks] [https://launchpadlibrarian.net/360903157/top.png memory] (reported on 2018-03-16, still no reaction whatsoever)

Latest revision as of 18:21, 8 June 2019

This page describes the various init systems which are available as alternatives to systemd
For a more comprehensive explanation of init, and runlevels, see wikipedia.org Page: Init

Init is the first process started during system boot. It is a daemon process that continues running until the system is shut down. Init is the direct or indirect ancestor of all other processes, and automatically adopts all orphaned processes. It is started by the kernel using a hard-coded filename; if the kernel is unable to start it, panic will result. Init is typically assigned process identifier 1.

The init scripts (aka rc runtime configuration scripts) are launched by the init process to guarantee basic functionality on system start and shutdown. This includes (un)mounting of file systems and launching of daemons. A service manager takes this one step further by providing active control over launched processes, or process supervision. An example is to monitor for crashes and restart processes accordingly.

These components combine to the init system. Some init systems incorporate the service manager in the init process or have init scripts in close relation to them. Below, such init systems are referred to as integrated, although entries in different categories may explicitly depend on each other.

A nice (but still non-comprehensive) overview of init systems can be found in this blog entry, titled "A history of modern init systems (1992-2015)"

Contents

[edit] init systems

System Description Latest release
BusyBox init (2) quite small and simple conventional init without runlevels, solely signal driven IPC (no fifos, sockets, SysV IPC); part of BusyBox 2018-12-30
dinit dependency based C++ init with process supervision, roll-back, and socket activation 2018-07-12
epoch (2) sequential, non-parallel init without dependency tracking designed for minimal footprint and unified configuration 2015-06-23
finit fast, event based, modular, extensible (C hooks/plugins) init with SysV runlevels, proper daemon supervision and logging, and optional builtin getty and inetd 2018-01-23
initng (2) modular, extensible, parallel, asynchronous, dependency based init 2007-03-25
myinit parallel init with dependency tracking via reference counting (akin to the "need" concept) lacking proper supervision (respawn only, no output logging) 2011-07-11
nosh exec chaining, dependency based daemontools family C++ init and supervision suite with reliable logging, (console) virtual terminal management, systemd unit file compatibility; can also be used as service manager under a different init 2017-12-11
oneit (2) very simple init launcher (just (re)spawns a single child process and reacts to incoming signals) included in ToyBox 2019-02-09
pies dependency based GNU init daemon and super server with SysV runlevels, daemon supervision and logging, inetd functionality, socket activation, fine grained per service access control, understands SysV inittab, inetd.conf, and MeTA1 config files 2016-10-01
procd OpenWrt init and process/service management daemon with ubus integration 2018-07-30
Pygos init Small and quite simple init with task/service ordering used in Pygos GNU/Linux (config and init script examples) 2018-11-25
s6-linux-init (2) generates an exec-chaining init around s6-svscan 2018-03-26
sinit Simple init initially based on Rich Felker’s minimal init 2015-06-16
sninit Small init implementation with SysV init like (sub)runlevels 2015-12-31
SysV init (2) the traditional Linux System V init clone 2019-02-25
ToyBox init (2) small and simple conventional init without runlevels included in ToyBox; solely signal driven; (almost) compatible with BusyBox init (same config syntax/file) 2019-02-09
ueld simple configuration, solely signal driven (akin to BSD/BusyBox/ToyBox init) 2017-06-24
uinit Smallest init possible 2017-05-16

[edit] abandoned/defunct/discontinued/dormant/halted init projects

Source code is available for download to anyone interested (in reviving them). Some of the projects listed below still compile/work while others may need some tweaking to make them work (again).

System Description Latest release
cinit (2, 3) dependency based parallel init without subprocess output logging ala minit/daemontools 2009-09-29
daemond daemon control and init daemon written in C++ (akin to dinit) 2003-11-14
depinit (2) supports parallel execution, dependencies, true roll-back, log pipelines, improved signaling, and unmounting of filesystems on shutdown 2003-10-06
einit (2, 3, 4) modular, parallel, asynchronous, dependency based init system; XML (service) config files 2007-12-18
ettcl (doc) custom Tcl-7.6 based interpreter to run the ETLinux init, crond, httpd, and telnetd daemons written in Tcl 2005-02-08
jinit C++ init daemon supporting dependency tracking akin to the "need" concept 2003-04-22
Mastodon init init with service ordering/dependency tracking resembling the "need" concept; was part of Mastodon Linux 2002-07-29
minit small dependency ordered, parallel init with proper subprocess supervision and logging 2005-??-??
ninit dependency based parallel init with supervision, logging, and time-based scheduling akin to crond (HOWTO) 2010-01-16
pinit (2) XML configuration, dependency based fast parallel boot, modular design; uses Glib 2.0 and LibXML 2 2003-05-01
qinit (2) Simple and fast exec-chaining init; no config files, services to (re)start are listed in a header file and compiled in. 2010-12-12
serel (2) parallel service launcher with synchronisation and integrity-checking (primarily to speed up SysV init boots, akin to startpar) 2002-08-06
simpleinit(-msb) (2) dependency based (implements the "need" concept) sequential init without proper supervision (respawn only, no output logging); shipped with util-linux until v2.20; the msb fork is still used in Source Mage Linux (2) 2007-11-08
System XVI modular, self-healing, and interface-oriented service manager and init system 2016-05-18
twsinit tiny init largely written in x86 assembler 2003-09-19
upstart "event based" init that reacts eagerly to incoming "events" to emulate dependency tracking; leaks memory 2014-09-04
uselessd (2) forked from systemd v208 2015-01-06

[edit] process supervisors (overview) and service managers

service manager: a suite of programs which start and stop services, both long-running daemons and one-time initialization scripts, in the proper order according to a dependency tree

Program Description Latest release
66 (2) s6-rc enhancement utils providing extended service management capabilities 2019-03-14
anopa (2) service management suite built around s6; can be used as init via exec chaining 2017-06-20
Circus (doc) runs, controls and monitors processes and sockets; written in Python; uses ZeroMQ 2018-06-15
Comar Python configuration/network/service manager with dbus integration used in Pardus Linux 2011-10-24
daemontools collection of tools for managing UNIX services 2001-07-12
daemontools encore (2) an enhanced version of daemontools 2018-10-14
freedt an independent daemontools reimplementation 2014-09-03
god (2) an easily configurable, extensible, monitoring framework written in Ruby 2014-03-06
MiniBase small userspace utilities for Linux; includes a process supervisor that can be used as stage 2 of process #1 via exec chaining akin to s6-svscan 2018-02-10
monit process and system monitoring daemon; system status is viewable directly from commandline, or via a native HTTP(S) web server 2018-05-29
Mudur Python init/rc script used in Pardus Linux 2011-10-06
OpenRC (2) dependency based service management suite; contains a process supervisor and a simple init alternative 2019-02-26
perp persistent process (service) supervisor and managment framework for UNIX 2013-01-11
procer process supervisor developed for mongrel2 2014-03-18
restartd Debian process-restarting daemon 2013-01-11
runit process supervision suite in the line of daemontools; includes a simple init (2) replacement 2014-08-10
s6 (2) small process supervision suite for UNIX ala daemontools, runit, and perp; supports service "readiness notification" and "fd holding"; can also be used as "stage 2" of process #1 via exec chaining 2019-03-04
s6-rc (2) service management suite for s6 2019-03-04
shepherd GNU service manager and init daemon written in Guile (formerly known as GNU dmd) 2018-09-26
slew s6(-rc) based boot and service script framework written in rc, the Plan 9 shell 2018-11-23
ssm simple service management bash scripts for Linux 2016-03-31
Tokiclover's Supervision Framework (2) OpenRC-like service management suite for daemontools(-encore), runit, and s6 2018-09-01
supervisord (doc) process control daemon written in Python 2018-02-15
systemctl-replacement drop-in reading systemd service descriptions, with docker-oriented init function, written in Python 2018-09-10

[edit] Dependency ordering of interdependent init scripts

Tools that help with dependency ordering of interdependent init scripts (e. g. by organizing the ordering of symlinks to the real rc scripts in SysV runlevel (sub)direcetories (usually stored in /etc/rc.d)) and concurrent execution of (non-interdependent) init scripts to speed up system startup and thereby reduce boot times.

Tool Description Latest release
insserv (2) used when installing new service scripts to update the order of symlinks pointing to them from all SysV runlevel (sub)directories according to LSB dependency specifications within comment lines located at the top of those scripts (LSB headers) 2019-02-25
OpenRC uses the "depend" shell function to specify dependencies between its rc scripts and also uses (sub)directories (usually of /etc/runlevels) to define runlevels (service groups/bundles) and symlinks therein to the service scripts they use 2019-02-26
rcorder (2, 3) used in NetBSD, FreeBSD, and DragonFly BSD by the /etc/rc shell script to generate a dependency ordered sequence of service scripts in the /etc/rc.d and /usr/local/etc/rc.d directories 2018-10-27
serel (2) works akin to startpar (defunct project) 2002-08-06
startpar (2) used within the main SysV runlevel executor rc script (usually /etc/rc.d/rc) to start a SysV runlevel's (non-interdependent) service scripts concurrently 2019-02-25

[edit] Simple, reliable, supervision-friendly logging

Simple, safe, reliable, and supervision-friendly logging tools are listed below since systemd also provides such features in its impertinent attempt to oust independent solutions and thereby suck otherwise unrelated functionality into the init system to enforce the usage of its own confined straitjacket framework.

With nosh and s6-rc whole log funnels/pipelines are possible, e. g. multiple log stages and fan-in. depinit provided similar functionality even directly in process #1. minit and ninit also provide service standard output/error redirection and logger supervision akin to svscan directly in process #1.

Tool Description Latest release
cyclog logs its standard input to multiple directories of rotated log files; part of the nosh service and system management suite 2019-03-20
dumblog logs standard input to a file; part of the freedt daemontools reimplementation 2014-09-03
multilog (2) logs standard input to a directory of rotated log files; part of daemontools(-encore) 2018-10-14
multipipe pipes standard input to a set of programs; part of daemontools-encore 2018-10-14
s6-log logs standard input to a directory of rotated log files; part of the s6 supervision suite 2019-03-04
sissylog logs standard input to syslog; part of the perp supervision suite 2013-01-11
socklog small, simple, reliable, and secure system and kernel logging (syslogd/klogd) services for the runit supervision suite 2006-03-06
svlogd logs standard input to a directory of rotated log files; part of the runit supervision suite 2014-08-10
tinylog logs standard input to a directory of rotated log files; part of the perp supervision suite 2013-01-11
ucspilogd converts syslog facility numbers and alert levels into names; part of the s6 supervision suite 2019-03-04

Replacements for syslogd and klogd:

[edit] Simple supervision-friendly time-based job schedulers

Simpler, safer, more reliable, supervision-friendly alternatives to crond and atd for time-based periodically job scheduling tasks are listed below since systemd also provides such capabilities in its impertinent attempt to oust independent solutions and thereby suck otherwise unrelated functionality into the init system to enforce the usage of its own confined straitjacket framework (ninit can also spawn services on specified dates or time intervals if one really wants to (ab)use process #1 for that purpose).

System Description Latest release
bcron (2) separate tools for different tasks with strictly controlled communication between them; crontab compatible 2015-08-12
slicd (2) modular design (separate tools); crontab compatible 2016-10-30
uschedule (2) job scheduling suite that uses separate tools for different tasks; an updated/improved package that works well with the nosh supervision suite can be downloaded here 2004-08-16

[edit] inetd super-server alternatives

Simpler, safer, supervision-friendly, and more reliable replacements for the network super-server daemon inetd.

Listed below since systemd provides similar features to creep into a totally unrelated problem domain and oust the single-purpose daemons specifically designed for that task in order to take over their business and force its own straitjacket APIs and tools upon every single Linux distro and user (finit provides a builtin inetd for those who need such capabilities in process #1).

Please also read this UCSPI overview and the s6 "fd holding" guide (versus "socket activation").

Tool Description Latest release
couriertcpd advanced UCSPI TCP server daemon, part of the Courier MTA; supports IPv6 and per address/domain access restrictions and concurrency limits 2018-11-29
iodp Input/Output Descriptor Protocol (IODP, resembles UCSPI) toolset for IO from/to TCP/UDP/UNIX sockets and fifos 2000-08-13
ipsvd UCSPI TCP/UDP server suite with support for access controls, concurrency limits, and SSLv3 2008-06-15
onenetd TCP-only UCSPI server supporting concurrency limits and IPv6 2014-06-21
s6-ipcserver s6 UCSPI server tool for UNIX local-domain sockets 2018-11-14
s6-networking (2) small UCSPI networking suite that provides access controls, concurrency limits, IPv6, and TLS/SSL 2018-08-15
ucspi-ipc command-line tools for building UCSPI client-server applications that use local unix-domain sockets and support concurrency limits and access restrictions based on client E(G,U)ID (via getpeereid()) 2005-05-27
ucspi-tcp UCSPI toolset for building TCP client-server applications supporting access controls and concurrency limits 2000-03-18
ucspi-unix (2) UNIX local-domain socket UCSPI client/server pair 2015-08-11
xinetd powerful inetd replacement providing access controls, concurrency limits, extensive logging capabilities, time based restrictions, defence mechanisms against port scans, and more 2012-05-09

[edit] Linux device managers

The udev daemon is a user space device manager for the Linux kernel. It is used for automatic device node management (including creating needed device files and symlinks pointing to them, loading required kernel modules and firmware) in the devtmpfs mounted on /dev.

In April 2012, udev's source code was merged into the systemd source tree.

Although it can still be compiled for usage without systemd, Lennart Poettering said that they will not polish udev outside of systemd [1], adding:

"Yes, udev on non-systemd systems is in our eyes a dead end, in case you haven't noticed it yet. I am looking forward to the day when we can drop that support entirely."

This is just another sad example of systemd's annoying habit of sucking otherwise unrelated functionality into the init system and trying to make independent single-purpose daemons obsolete in an impertinent attempt to enforce its sole usage upon every Linux distro and user.

So to be on the safe side, you probably want to use an alternative to udev:

DevMan Description Last release
eudev (2, 3) Gentoo's maintained fork of udev 2018-10-26
mdev (2, 3, 4) the plug-and-play manager built into BusyBox 2018-12-30
mdevd (2) nonforking Linux kernel uevent handler daemon; uses the mdev config file format 2018-08-14
nldev (2) Suckless netlink frontend for mdev; replacements for udevd and udevadm (see also nlmon) 2018-08-03
smdev mostly mdev-compatible Suckless program to manage device nodes 2015-04-12
vdev (2) portable UNIX userspace device-file manager 2016-08-08

For more read this thread on StackExchange.

Related helper utility:

udevil (2) (un)mounts removable devices without a password, shows device info, and monitors device changes. It can also mount ISO files, nfs://, smb://, ftp:, ssh:// and WebDAV URLs, and tmpfs/ramfs filesystems. Uses Glib and libudev (i. e. requires (e)udev) and can work completely without systemd, consolekit, policykit, dbus, udisks, gvfs & fuse (although it can coexist with any of these).

[edit] Hints, intros, instructions, guides, and tutorials

  • Hints on how to build, install, configure, and use ninit as default init
  • How to replace your current init with s6 (2) + OpenRC (in place of s6-rc)
  • Hints on how to replace your current init with epoch and runit
  • How to replace systemd with BusyBox init and minirc
  • daemontools(-encore) intro
  • How to perform socket activation with s6
  • How (2) to configure and use the Linux ACPI event handling daemon acpid2 for power management instead of systemd

Distro-specific guides:

[edit] Articles in other wikis

Arch Linux wiki

Artix Linux wiki

Gentoo Linux wiki

Manjaro Linux wiki

Obarun Linux wiki

Void Linux wiki

[edit] See also

General information:

More specific articles and resources:

Personal tools