From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.sysutils.supervision.general/2855 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Colin Booth Newsgroups: gmane.comp.sysutils.supervision.general Subject: Re: runit SIGPWR support Date: Wed, 12 Feb 2020 21:54:27 +0000 Message-ID: <20200212215427.GG12551@cathexis.xen.prgmr.com> References: <1beb6e35-d4be-60b8-fc52-af666c4fffe3@gmx.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="30326"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mutt/1.10.1 (2018-07-13) To: supervision@list.skarnet.org Original-X-From: supervision-return-2444-gcsg-supervision=m.gmane-mx.org@list.skarnet.org Wed Feb 12 22:54:31 2020 Return-path: Envelope-to: gcsg-supervision@m.gmane-mx.org Original-Received: from alyss.skarnet.org ([95.142.172.232]) by ciao.gmane.io with smtp (Exim 4.92) (envelope-from ) id 1j1zxm-0007kp-S3 for gcsg-supervision@m.gmane-mx.org; Wed, 12 Feb 2020 22:54:30 +0100 Original-Received: (qmail 15087 invoked by uid 89); 12 Feb 2020 21:54:57 -0000 Mailing-List: contact supervision-help@list.skarnet.org; run by ezmlm Original-Sender: Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Original-Received: (qmail 15080 invoked from network); 12 Feb 2020 21:54:56 -0000 Content-Disposition: inline In-Reply-To: Xref: news.gmane.io gmane.comp.sysutils.supervision.general:2855 Archived-At: On Wed, Feb 12, 2020 at 05:25:56PM +0300, innerspacepilot wrote: > > Why not just make runit systems run inside containers out of the box? > We are talking about one/two lines of code. > > Why can't we be just a little bit more friendly to each other? > > Thanks. > I wasn't trying to be hostile, apologies if it came across that way. As far as I know SIGPWR is a Linux-specific signal so services that are aiming for portability will either need to have special handling for that in the linux case or need to ignore it. Ergo, runit (and all other POSIX-compliant inits) currently have no special handling around SIGPWR as they don't understand what it is. Is this the right behavior? I don't know. Something like SIGPWR as an alerting mechanism when you're switched to UPS battery is pretty nice in a general case but using that as your container shutdown solution isolates you into a very SysV-specific world. Overriding the default via lxc.signal.halt will allow you to modify what you send to something that is within the POSIX spec and allow you to trigger shutdowns the "right" way. It's a little lame but it is portable, and LXC using a non-portable signal is a little bit of a bummer. -- Colin Booth