Releases: finit-project/finit
Finit v3.0
Major release, support for conditions/dependencies between services, optional built-in watchdog daemon, optional built-in getty, optional built-in standard inetd services like echo server, rdate, etc.
Also, native support for Debian/BusyBox /etc/network/interfaces, overhauled new configure based build system, logging to /dev/kmsg before syslogd has started, massively improved support for Linux distributions.
Changes
-
Added basic code of conduct covenant to project
-
Added contribution guidelines document
-
Removed
finit.confoptioncheck DEV, replaced entirely by automated call tofsckfor each device listed in/etc/fstab -
Removed deprecated and confusing
startxandusersettings. It is strongly recommended to instead use xdm/gdb/lightdm etc. -
Add support for
initctl log <SVC>, shows last 10 lines from syslog -
Add
initctl cond dumpfor debugging conditions -
Ensure plugins always have a default name, file name
-
Reorganization, move all source files to a
src/sub-directory -
Add support for
initctl <list|enable|disable> <SVC>, much needed by distributions. See doc/distro.md for details -
Remove
UNUSED()macro, mentioned here because it may have been used by external plugin developers. Set-Wno-unused-parameterinstead -
New table headings in
initctl, usingtopstyle inverted text -
Allow
initctl showto use full screen width for service descriptions -
New
HOOK_BANNERfor plugins to override the defaultbanner() -
Allow loading TTYs from
/etc/finit.d -
Improvements to built-in getty, ignore signals like
SIGINT,SIGHUP, support Ctrl-U to erase to beginning of line -
Add TTY
nowaitandnoclearoptions -
Allow using both built-in getty and external getty:
tty [12345] /dev/ttyAMA0 115200 noclear vt220 tty [12345] /sbin/getty -L 115200 /dev/ttyAMA0 vt100 tty [12345] /sbin/agetty -L ttyAMA0 115200 vt100 nowait -
Silent boot is now the default, use
--enable-progressto get the old
Finit style process progress. I.e.,--enable-silentis no more -
Support for
configure --enable-emergency-shell, debug-only mode -
Support for a fallback shell on console if none of the configured TTYs can be started,
configure --enable-fallback-shell -
All debug messages to console when Finit
--debugis enabled -
Prevent login, by touching
/etc/nologin, during runlevel changes -
A more orderly shutdown. On reboot/halt/poweroff Finit now properly goes to runlevel 0/6 to first stop all processes.
-
Perform sync before remounting as read-only, at shutdown
-
Clean up
/tmp,/var/run, and/var/lockat boot on systems which have these directories on persistent storage -
Call udev triggers at boot, on systems with udev
-
Add missing
/var/lock/subsysdirectory for dbus -
Add support for
poweroff -
Add support for a built-in miniature watchdog daemon
-
Remove GLIBC:isms like
__progname -
Manage service states based on user defined conditions
-
Manage dependencies between services, w/ conditions (pidfile plugin)
-
Manage service dependencies on network events (netlink plugin)
-
Support for dynamically reloading Finit configuration at runtime
-
Refactor to use GNU configure and build system
-
New hooks for for detecting lost and started services (lost plugin)
-
External libraries, libuEv and libite, now build requirements
-
Early logging support to
/dev/kmsginstead of console -
Support for redirecting stdout/stderr of services to syslog
-
Support for managing resource limits for Finit and its processes
-
Add optional built-in inetd services: echo server, chargen, etc.
-
Add simple built-in getty
-
Greatly improved accounting support, both UTMP and WTMP fixes+features
-
Improved udev support, on non-embedded systems
-
Improved shutdown and file-system unmount support (Debian)
-
Support SysV init
/etc/rc.local -
Inetd protection against UDP looping attacks
-
Support systems with
/runinstead of/var/run(bootmisc plugin) -
Adopted BusyBox init signals for halt/reboot/poweroff
-
SysV init compat support for reboot (setenv)
-
Compat support for musl libc
-
Add OpenRC-like support for sysctl.d/*.conf
-
Add support for Debian/BusyBox
/etc/network/interfaces -
Add support for running fsck on file systems in
/etc/fstab -
Added example configs + HowTos for Debian and Alpine Linux
to support latest releases of both distributions -
Lots of documentation updates
Fixes
- Fix race-condition at configuration reload due to too low resolution. Thanks to Mattias Walström, Westermo
- Fix to handle long process (PID) dependency chains, re-run reconf callback until no more applications are in flux. Thanks to Mattias Walström, Westermo
- Clear
reconfcondition wheninitctl reloadhas finished - Skip automatic reload of
/etc/finit.d/*.conffiles when changing runlevel to halt or reboot - Fix issue #54: Allow halt and poweroff commands even if watchdog is enabled
- Fix issue #56: Check existence of device before trying to start getty
- Fix issue #60:
initctlshould display error and return error code for non-existing services should the operator try to start/stop them. - Fix issue #61: Reassert
net/*conditions afterinitctl reload - Fix issue #64: Skip
fsckon already mounted devices - Fix issue #66: Log rotate and gzip
/var/log/wtmp, created by Finit - Fix issue #72: Check
ifupexists before trying to bring up networking, also set$PATHearlier to simplifyrun()et al -- no longer any need to use absolute paths for system tools called from Finit. Thanks to crazy - Fix issue #73: Remove double
ntohl()in inetd handling, prevents matches. Thanks to Petrus Hellgren, Westermo - Fix issue #76: Reap zombie processes in emergency shell mode
- Fix issue #80: FTBFS on Arch Linux, missing
stdarg.hinhelpers.h, thanks to Jörg Krause - Fix issue #81: Workaround for systems w/o SYSV shm IPC support in kernel
- Always collect bootstrap-only tasks when done, we will never re-run them. Also, make sure to never reload bootstrap-only tasks at runtime
- Remove two second block (!) of Finit when stopping TTYs
Finit v3.0-rc2
Second pre-release,
- Support for a fallback shell on console if none of the configured TTYs
can be started - All debug messages to console when Finit
--debugis enabled - Prevent login, by touching
/etc/nologin, during runlevel changes - A more orderly shutdown. On reboot/halt/poweroff Finit now properly
goes to runlevel 0/6 to first stop all processes. - Perform sync before remounting as read-only, at shutdown
- Clean up
/tmp,/var/run, and/var/lockat boot on systems which
have these directories on persistent storage - Call udev triggers at boot, on systems with udev
- Add missing
/var/lock/subsysdirectory for dbus - Add support for
poweroff - Add support for a built-in miniature watchdog daemon
- Remove GLIBC:isms like
__progname
Finit v3.0-rc1
- Manage service states based on user defined conditions
- Manage dependencies between services, w/ conditions (pidfile plugin)
- Manage service dependencies on network events (netlink plugin)
- Support for dynamically reloading Finit configuration at runtime
- Refactor to use GNU configure and build system
- New hooks for for detecting lost and started services (lost plugin)
- External libraries, libuEv and libite, now build requirements
- Early logging support to
/dev/kmsginstead of console - Support for redirecting stdout/stderr of services to syslog
- Support for managing resource limits for Finit and its processes
- Add optional built-in inetd services: echo server, chargen, etc.
- Add simple built-in getty
- Greatly improved accounting support, both UTMP and WTMP fixes+features
- Improved udev support, on non-embedded systems
- Improvide shutdown and file-system unmount support (Debian)
- Added
--enable-emergency-shell(configure) fallback debug mode - Support SysV init
/etc/rc.local - Inetd protection against UDP looping attacks
- Support systems with
/runinstead of/var/run(bootmisc plugin) - Adopted BusyBox init signals for halt/reboot/poweroff
- SysV init compat support for reboot (setenv)
- Compat support for musl libc
- Add OpenRC-like support for sysctl.d/*.conf
- Add support for Debian/BusyBox
/etc/network/interfaces - Add support for running fsck on file systems in
/etc/fstab - Added example configs + HowTos for Debian (Jessie) and Alpine Linux
Finit v2.4
Bug fix release.
Changes
- Add support for status/show service by
name:id - Enforce terse mode after boot, if verbose mode is disabled
- Reenable verbose mode at reboot, if disabled at boot
- Update section mentioning BusyBox getty
- Update debugging documentation
- Allow debug to override terse mode
- Revert confusing change in service state introduced in v2.3.
As of v2.4 services are listed as "halted" and "stopped", when
they have been halted due to a runlevel changed or stopped by
the user, respectively.
Fixes
- Fix system freeze at reconfiguration. Changed services that
all supportSIGHUPcaused a freeze due to Finit waiting for
them to stop. - Make sure to start and/or
SIGHUPservices after reconfiguration
when there was no services to stop.
Finit v2.3
Bug fix release.
Changes
- Add support for stop/start/restart/reload service by
name:id - Refactor service status listed in
initctl show, show actual status
Fixes
- Remove bootstrap-only tasks/services when leaving runlevel 'S'
- Fix reference counting issue with already stopped and removed services
when the user performsinitctl reloadto change system configuration - Revert semantic change in behavior of
initctl restart: users expect
service to be stopped/started, not reloaded withSIGHUPeven if the
service supports it - Fix
NULLpointer dereference causing kernel panic when user calls
initctl reloadafter change of system configuration - Fix column alignment in output of
initctl showfor services not in
current runlevel
Finit v2.2
Lots of fixes to handle static builds, but also fixes for dynamic event
handling and reconfiguration at runtime.
Changes
- Upgrade to libuEv v1.2.4, to handle static builds
- Upgrade to libite (LITE) v1.2.0, to handle static builds
- Clarify how to select different plugins with the configure script
- Improve urandom plugin for embedded systems w/o random seed
- Add
--debugflag toinitctl - The runlevels listed for services in
initctl shownow hightlight the
active runlevel. - Clarify in the README and in
initctl helpthat the GW event to
listen for in service declarations isGW:UP
Fixes
- Build fixes for
configure --disable-inetd - Fixed issue #14: Improved support for static Finit builds
- Misc. fixes to silence warnings when building a static Finit
- Default to register services as
SIGHUP'able, regression in v2.0 - Call
HOOK_SVC_RECONFonly when all processes have been stopped - On reload/reconf we must wait for all services to stop first
- Only trigger on events that matches the service's specification,
fix by Tobias Waldekranz
Finit v2.1
Changes
- Add hook point for fstab mount failure
- Set hostname on dynamic reload
- Upgrade to libite v1.1.1
Fixes
- Fix service callback coredump checks and simplify callback exit
- Do not use
-Osuse-O2as default optimization level. Many cross
compiler toolchains are known to have problems with-Os - Do not allow build VERSION to be overloaded by an environment variable
- Fix too small MAX arguments and too few argments in
svc_tfor
reading currently running services withinitctl show - Unblock blocked signals after forking off a child
Finit v2.0
Support for multiple instances and event based services, as well as the
introduction of an initctl tool.
Note: Incompatible change to syntax for custom inetd services, c.f. Finit v1.12.
Changes
-
The most notable change is the support for multiple instances. A must
have when running multiple DHCP clients, OpenVPN tunnels, or anything
that means using the same command only with different arguments. Now
simply add a:IDafter theservicekeyword, whereIDis a unique
instance number for that service.service #1 [2345] /sbin/httpd -f -h /http -p 80 -- Web server service #2 [2345] /sbin/httpd -f -h /http -p 8080 -- Old web server -
Another noteworthy new feature is support for starting/stopping
services on Netlink events:service :1 [2345] <!IFUP:eth0,GW> /sbin/dropbear -R -F -p 22 -- SSH daemonHere the first instance
:1of the SSH daemon is declared to run in
runlevels 2-5, but only if eth0IFUP:eth0is up and a gatewayGW
is set. When the configuration changes, a new gateway is set, or if
somehow a newIFUPevent for eth0 is received, then dropbear is not
SIGHUP'ed, but instead stop-started<!>. The latter trick applies
to all services, even those that do not define any events. -
Support for reloading
*.conffiles in/etc/finit.d/on SIGHUP.
Alltask,serviceandrunstatements can be used in these .conf
files. Use thetelinit qcommand,initctl reloador simply send
SIGHUPto PID 1 to reload them. Finit automatically does reload of
these*.conffiles when changing runlevel. -
Support for a modern
initctltool which can stop/start/reload and
list status of all system services. Also, the old client tool used
to change runlevel is now also available as a symlink:telinit.initctl [-v] <status|stop|start|reload|restart> [JOB] -
Add concept of "jobs". This is a unique identifier, composed of a
service and instance number,SVC:IDinitctl <stop|start|reload|restart> JOB -
Support for deny filters in
inetdservices.inetd service/proto[@iface,!iface,...] </path/to/cmd | internal[.service]>Internal services on a custom port must use the
internal.service
syntax so Finit can properly bind the inetd service to the correct
plugin. Here follows a few examples:inetd time/udp wait [2345] internal -- UNIX rdate service inetd time/tcp nowait [2345] internal -- UNIX rdate service inetd 3737/tcp nowait [2345] internal.time -- UNIX rdate service inetd telnet/tcp@*,!eth1,!eth0, nowait [2345] /sbin/telnetd -i -F -- Telnet service inetd 2323/tcp@eth1,eth2,eth0 nowait [2345] /sbin/telnetd -i -F -- Telnet service inetd 222/tcp@eth0 nowait [2345] /sbin/dropbear -i -R -F -- SSH service inetd ssh/tcp@*,!eth0 nowait [2345] /sbin/dropbear -i -R -F -- SSH serviceAccess to telnet on port
2323is only possible from interfaces
eth0,eth1andeth2. The standard telnet port (23) is
available from all other interfaces, but alsoeth2. The*
notation used in the ssh stanza means any interface, however, here
eth0is not allowed.NOTE: This change breaks syntax compatibility with Finit v1.12.
-
Support for a more user-friendly configure script rather than editing
the top Makefile, or setting environment variables at build time. -
Support for building Finit statically, no external libraries. This
unfortunately means that some plugins cannot be built, at all.
Big thanks goes to James Mills for all help testing this out! -
Support for disabling the built-in inetd server with
configure. -
Support for two new hook points:
HOOK_SVC_RECONFand
HOOK_RUNLEVEL_CHANGE. See the source for the exact location. -
The
include <FILE>option now needs an absolute path toFILE.
Fixes
- Rename
patches/tocontrib/to simplify integration in 3rd party
build systems. - Fix for unwanted zombies ... when receiving SIGCHLD we must reap all
children. We only receive one signal, but multiple processes may have
exited and need to be collected.
Finit v1.12
The inetd release.
Changes
- Add support for built-in inetd super server -- launch services on
demand. Supports filtering per interface and custom Inet ports. - Upgrade to libuEv v1.1.0 to better handle error conditions.
- Allow mixed case config directives in
finit.conf - Add support for RFC 868 (rdate) time plugin, start as inetd service.
- Load plugins before parsing
finit.conf, this makes it possible to
extend finit even with configuration commands. E.g., thetime.so
plugin must be loaded for theinetd time/tcp internalservice to be
accepted when parsingfinit.conf. - Slight change in TTY fallback behavior, if no TTY is listed in the
systemfinit.conffirst inspect theconsolesetting and only if
that too is unset fall back to/bin/sh - When falling back to the
consoleTTY or/bin/sh, finit now marks
this fallback as console. Should improve usability in some use cases.
Fixes
- Revert "Use
vfork()instead offork()before exec()" from v1.11. It
turned out to not work so well after all. For instance, launching
TTYs in a background process completely blocked inetd services from
even starting up listening sockets ... proper fork seems to work fine
though. This is the casue for yanking the [1.11] release, below. - Trap segfaults caused by external plugins/callbacks in a sub-process.
This prevents a single programming mistake in by a 3rd party developer
from taking down the entire system. - Fix Coverity CID 56281:
dlopen()resource leak by storing the pointer.
For the time being we do not support unloading plugins. - Set hostname early, so bootstrap processes like syslog can use it.
- Only restart lost daemons when recovering from a SIGSTOP/norespawn.
Finit v1.11 [YANKED]
The libuEv release.
Note: This release has been yanked from distribution due to a regression in launching background processes and TTY's. Fixed in Finit v1.12.
Changes
- Now using the asynchronous libuEv library for handling all events:
signals, timers and listening to sockets or file descriptors. - Rename NEWS.md --> CHANGELOG.md, with symlinks for
make install - Attempt to align with http://keepachangelog.com for the ChangeLog
- Travis CI now only invokes Coverity Scan from the 'dev' branch. This
means that all development, except documentation updates, must go into
that branch.
Fixes
- Fix bug with finit dying when no
ttyis defined infinit.conf, now
even the fallback shell has control over its TTY, see fix in GIT
commit dea3ae8 for this.