Comparison of init systems

From Gentoo Wiki
Jump to: navigation, search

Basic information

sysvinit / BSD init OpenRC upstart systemd SMF launchd Epoch
Supported in Gentoo partially (used by OpenRC) Yes (default init) No Yes No No To be determined
Package / Bug# sys-apps/sysvinit sys-apps/openrc bug #498376 sys-apps/systemd - - sys-apps/epoch
Supported platforms Linux / BSD Linux + BSD Linux Linux Solaris MacOSX Linux
Main coding language C POSIX shell (+ C) C C C C C
Main dependencies - init (sysv or BSD) D-Bus D-Bus init(sysv?) - libc, /bin/sh
Init script/service format single config file shell scripts config files + shell fragments config files (ini) XML (+ shell scripts) plist multiple or single .conf
Per-service configuration No Yes (conf.d) With in-job mechanisms (normal exit, respawn) Yes  ?  ? Yes (v1.1+)
Running as a daemon Yes (PID 1) No Yes (PID 1) Yes (PID 1) Yes (invoked) Yes (PID 1) Yes (PID 1)
Cross-service dependencies/events No Yes Yes Yes Yes No No
Parallel service startup Yes Yes (optional) Yes Yes Yes Yes No
Keeping daemons alive Yes No Yes Yes Yes Yes Yes
Preferred service file supplier n/a Gentoo Ubuntu upstream Solaris MacOSX n/a
License GPL v2+ 2-cl. BSD GPL v2 LGPL v2.1+ ? Apache License 2.0 Public Domain

Supported services (in Gentoo)

OpenRC systemd
Filesystem mounting one script per group (root, local, network, swap...) two units per mountpoint (fsck + mount), runtime-generated with dependencies
getty (terminal prompts) started through inittab one unit per console, instantiated from template on-demand
Networking setup extensive (own framework) external (NetworkManager, networkd, DHCP daemons)
X11 Display Manager setup single service for all (required to auto-restart) separate DM units