runit is an init and service management scheme for Unix-like operating system that initializes, supervises, and ends processes throughout the operating system. Runit is a reimplementation of the daemontools process supervision toolkit that runs on many Linux-based operating systems, as well as BSD, and Oracle Solaris operating systems. Runit features parallelization of the start up of system services, which can speed up the boot time of the operating system.
When running as an init daemon, Runit is the direct or indirect child process of all other processes. It is the first process started during booting, and continues running until the system is shut down. It is often used with other init systems as a separate service manager. In the service manager role, it can be used by unprivileged users to orchestrate personal services, as well as by Superuser to manage services not otherwise managed by the init system currently in use. ]]
Stage 2 usually invokes a binary named runsvdir, which is the process responsible for global daemon management: for every daemon it finds in a folder passed to it by argument, it then spawns an individual Watchdog timer, each of those starts a daemon (and a logger service eventually associated to it) and restarts it if it dies. In case a daemon is added or removed, it kills the watchdog or starts a new one. Executable files with specific names are used to describe the various phases of the daemon's life (run, check, finish, ...), it can intercept signals sent and run by specific scripts if they exist, and Named pipe are created to expose interfaces to control the daemon.
Runit is an "officially" available init system for:
|
|