Re: runit SIGPWR support

From: Guillermo <>
Date: Mon, 24 Feb 2020 18:13:19 -0300

The keyboard signal can actually be set to any signal less than or
equal to NSIG with the KDSIGACCEPT ioctl. sysvinit just happened to
pick SIGWINCH for that, and so did systemd and nosh, presumably for

El dom., 23 feb. 2020 a las 20:53, Laurent Bercot escribió:
> Both SIGPWR and SIGWINCH are caught in the latest s6 git head.
> Release coming whenever real life stop throwing things at me and I
> can actually find a week-end to polish things and cut it.

I noticed that you modified s6-svscan to divert SIGPWR and SIGWINCH,
but s6-linux-init-maker only creates a handler for SIGPWR (that just
does 's6-inux-init-shutdown -a -p -- now', like the SIGUSR1 handler).
If you bothered making SIGWINCH 'divertable', you could also add the
KDSIGACCEPT ioctl() call to the stage1 init (s6-linux-init), just like
you did with the reboot(RB_DISABLE_CAD) call, and have
s6-linux-init-maker create a run-image/service/.s6-svscan/SIGWINCH

My suggested action for SIGWINCH would be to execute a file in the
'scripts' subdirectory of the basedir. The skeldir counterpart of this
file could be a shell script with only explanatory comments, just like
the skeldir's (so, by default, unless the
administrator configures something, the keyboard signal would do

Since the inittab action field for the keyboard signal is "kbrequest",
the target unit that systemd starts in response to the keyboard signal
is named "", and the target bundle that nosh's
system-manager starts in response to the keyboard signal is named
"kbrequest", my extremely original suggestion for the script's name
would be... "kbrequest" :)

(Actually, for sysvinit, systemd and nosh, the action in response to
SIGPWR is also configurable, and by default SIGPWR does nothing, so I
don't know what LXC containers do if they include an init system… they
must have some extra configuration I guess).

Received on Mon Feb 24 2020 - 21:13:19 UTC

This archive was generated by hypermail 2.3.0 : Sun May 09 2021 - 19:44:19 UTC