s6-linux-init
Software
skarnet.org
The s6-linux-init-shutdownd internal program
s6-linux-init-shutdownd is the daemon that manages the shutdown
procedure for a s6-linux-init installation. It is not meant to be called
directly by the user.
Interface
s6-linux-init-shutdownd [ -b bindir ] [ -c basedir ] [ -g gracetime ] fifo
- s6-linux-init-shutdownd opens the fifo named pipe
and listens to it. This is where programs such as
s6-linux-init-shutdown send their
commands when they are told to trigger the shutdown procedure.
- When it receives a command to shut down, s6-linux-init-shutdownd
first spawns the stage3 script defined by the last
s6-linux-init-maker invocation.
- When this script exits, s6-linux-init-shutdownd kills all
processes, first with a SIGTERM, then (after the grace time specified by
the shutdown command) with a SIGKILL.
- It then runs the automatically-generated stage 4 script,
which unmounts the file systems and halts, powers off or reboots the
machine.
Exit codes
- 100: wrong usage, or user does not have root privileges.
- 111: system call failed.
Options
- -b bindir : look for the
execlineb
script interpreter in the bindir directory. Default is /bin.
- -c basedir : look for the
stage3 and stage4 scripts in the basedir
directory. Default is /etc/s6-linux-init.
- -g gracetime : if the shutdown command
does not specify a grace time between the SIGTERM and the SIGKILL, use
gracetime milliseconds. Default is 3000.
Notes