From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.sysutils.supervision.general/2857 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: Jeff Newsgroups: gmane.comp.sysutils.supervision.general Subject: Re: runit SIGPWR support Date: Fri, 14 Feb 2020 10:38:38 +0100 Message-ID: <6843181581673118@sas1-ffdbcd5f1d77.qloud-c.yandex.net> References: <1beb6e35-d4be-60b8-fc52-af666c4fffe3@gmx.com> <20200212215427.GG12551@cathexis.xen.prgmr.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="118332"; mail-complaints-to="usenet@ciao.gmane.io" To: supervision Original-X-From: supervision-return-2446-gcsg-supervision=m.gmane-mx.org@list.skarnet.org Fri Feb 14 10:38:54 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 1j2XR0-000UdC-0P for gcsg-supervision@m.gmane-mx.org; Fri, 14 Feb 2020 10:38:54 +0100 Original-Received: (qmail 8171 invoked by uid 89); 14 Feb 2020 09:39:11 -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 8164 invoked from network); 14 Feb 2020 09:39:10 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yandex.com; s=mail; t=1581673119; bh=4hh2C3Ah2nA/9ZudQg/8c5p1s7/c1DRFFHJfcc5tq18=; h=References:Date:Message-Id:Subject:In-Reply-To:To:From; b=RsmMXI4uCMg3hr3n9PocR8h/Ipe8a7CFyW2QyzCB9WUCPlJelSYY5HfUTKgk3K9oh 42lh+BtxnyuL1rnPJujDmqziUmXhm35Pa7ywSYsOEwn7iLtoXKjwdQQk+DG7S+XIut oVA1RfBs+0W07g5r5+szbIgaIV0A42cv9kh4YZzo= Authentication-Results: mxback19g.mail.yandex.net; dkim=pass header.i=@yandex.com In-Reply-To: <20200212215427.GG12551@cathexis.xen.prgmr.com> X-Mailer: Yamail [ http://yandex.ru ] 5.0 Xref: news.gmane.io gmane.comp.sysutils.supervision.general:2857 Archived-At: 12.02.2020, 22:54, "Colin Booth" : > 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. you should patch the code, runit is dead anyway. try something along this lines in the source: #ifdef SIGPWR /* handle that one */ ... #endif i can't see the problem, you have to patch the runit sources to fulfil your requirements since that project is dead and the code is not maintained anymore. >>  Why can't we be just a little bit more friendly to each other? that would be indeed helpful. > 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. just BS. adding a bit of handler code for SIGPWR is no big deal, please stop your lamento, it's so boring.