s6-linux-init
Software
skarnet.org
The s6-halt program
s6-halt sends a signal to process 1 in order to halt the machine;
or, with the -f option, it performs an immediate hard shutdown.
Interface
s6-halt [ -h | -p | -r ] [ -f ]
- s6-halt sends a signal to process 1.
- It then exits 0.
Options
- -h : halt. The command will order a halt (i.e. the system will
be shut down, but the power will remain up), which means
sending a SIGUSR2 to process 1. This is the default.
- -p : poweroff. The command will order a power off, which means
sending a SIGUSR1 to process 1.
- -r : reboot. The command will order a reboot, which means
sending a SIGINT to process 1.
- -f : force. The command will not send any signal to process 1;
it will just sync the filesystems then tell the kernel to halt, poweroff or reboot.
s6-reboot -f or s6-poweroff -f should be the last program
executed in the lifetime of a machine, at the end of the shutdown script called
by process 1 when it receives a signal telling it to shut down.