From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.sysutils.supervision.general/2718 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Colin Booth Newsgroups: gmane.comp.sysutils.supervision.general Subject: Re: runit patches to fix compiler warnings on RHEL 7 Date: Sat, 30 Nov 2019 01:22:02 +0000 Message-ID: <20191130012202.GD17083@cathexis.xen.prgmr.com> References: <20191125214342.y7lx5mixrljr6s27@gromit.local> <20191127203307.ohaameqfgncm52h5@gromit.local> <20191129140901.klifpegc74iv4zul@klumpi.ignorelist.com> <53c68b5e-715f-25ab-3c59-da6b8a07d8a9@heuristicsystems.com.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="25536"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Mutt/1.10.1 (2018-07-13) To: supervision@list.skarnet.org Original-X-From: supervision-return-2307-gcsg-supervision=m.gmane.org@list.skarnet.org Sat Nov 30 02:22:06 2019 Return-path: Envelope-to: gcsg-supervision@m.gmane.org Original-Received: from alyss.skarnet.org ([95.142.172.232]) by blaine.gmane.org with smtp (Exim 4.89) (envelope-from ) id 1iarSY-0006W6-18 for gcsg-supervision@m.gmane.org; Sat, 30 Nov 2019 02:22:06 +0100 Original-Received: (qmail 31877 invoked by uid 89); 30 Nov 2019 01:22:30 -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 31870 invoked from network); 30 Nov 2019 01:22:30 -0000 Content-Disposition: inline In-Reply-To: <53c68b5e-715f-25ab-3c59-da6b8a07d8a9@heuristicsystems.com.au> Xref: news.gmane.org gmane.comp.sysutils.supervision.general:2718 Archived-At: On Sat, Nov 30, 2019 at 08:46:28AM +1100, Dewayne Geraghty wrote: > Jan, > > I'm also a virgin to process/service management software, learning s6-rc, > s6, execlineb is not for the faint-hearted nor the time-poor. Getting a > handle on the concepts, and the naming conventions - its really hard work. If you want to ease yourself into process supervision I suggest starting just with s6 and a smattering of execline when you are trying to describe things that are really annoying to express in shell. Usually you only need to do this when your run scripts are turning into a mess of line continuations because of the chain load utilities but there are other reasons to do it as well. s6-rc is absolutely not necessary for basic service management. It's a very nice helper utility when you're mixing non-idempotent oneshots with long-running services or handling deep dependency tries that are fairly touchy (like system bootstrap stuff), but if you don't need deep levels of dependency ordering and any initial environmental setup for a service can be handled in an idempotent way, s6-rc is intense overkill. If you need to synchronize between two services, you can hard-code startup and shutdown dependencies with s6-svwait and/or s6-svc calls reaching into the other service directory. It's a pretty low-rent but it's very easy to think about and manage. > > Execline enforces a discipline, a rigor demanding anticipatory planning (to > get right). I ran some performance tests and execlineb is marginally > better. So why persist? Largely because an execline script is immediately > obvious and explicit. Seriously, at a glance you know what the script will > achieve. Could I write a sh script to do the same task? Yes, and probably > do it a lot quicker. But. I would loose the elegance and readability - > where sh has an equivalence with assembler, execline is akin to BASIC, it > makes you think differently :) I personally like execline for run scripts because there's very little magic and it takes a lot of work to fail to get the service that you want supervised correctly parented at the end of the day. Also, since it execs into each program you end up not having to do shenanigans like execing into nested shells if you need to modify state after dropping privileges (like you do with chpst). > > I'm developing solutions for PROTECTED level security (its an Australian > Govt thing), and skarnet's service management provides assurance, and s6-log > provides near-certainty of logging completeness. I'm very happy with the > toolset, worth the time investment. -- Colin Booth