From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.sysutils.supervision.general/1292 Path: news.gmane.org!not-for-mail From: Laurent Bercot Newsgroups: gmane.comp.sysutils.supervision.general Subject: Re: Option for runsv/runsvdir to specify how many times to restart a service in a certain time period before giving up? Date: Mon, 30 Oct 2006 14:58:34 +0100 Message-ID: <20061030135834.GA26907@skarnet.org> References: <4543AEE3.50200@alex-smith.me.uk> <20061030104923.GC32166@home.power> <20061030121321.GA27602@fly.srk.fer.hr> <20061030123019.GA30814@home.power> <20061030133847.GA25085@skarnet.org> <20061030134227.GA23323@home.power> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1162216721 14682 80.91.229.2 (30 Oct 2006 13:58:41 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 30 Oct 2006 13:58:41 +0000 (UTC) Original-X-From: supervision-return-1528-gcsg-supervision=m.gmane.org@list.skarnet.org Mon Oct 30 14:58:40 2006 Return-path: Envelope-to: gcsg-supervision@gmane.org Original-Received: from antah.skarnet.org ([212.85.147.14]) by ciao.gmane.org with smtp (Exim 4.43) id 1GeXeX-0001eY-Qw for gcsg-supervision@gmane.org; Mon, 30 Oct 2006 14:58:14 +0100 Original-Received: (qmail 27509 invoked by uid 76); 30 Oct 2006 13:58:35 -0000 Mailing-List: contact supervision-help@list.skarnet.org; run by ezmlm List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Archive: Original-Received: (qmail 27503 invoked by uid 1000); 30 Oct 2006 13:58:34 -0000 Mail-Followup-To: supervision@list.skarnet.org Original-To: supervision@list.skarnet.org Content-Disposition: inline In-Reply-To: <20061030134227.GA23323@home.power> User-Agent: Mutt/1.4i Xref: news.gmane.org gmane.comp.sysutils.supervision.general:1292 Archived-At: > Of course there no need to polling anything - each ./finish execution > equal to 'restart event' (or, more precisely, 'shutdown event', but in > this case there no significant difference). Hmmm. Of course it can be done with the finish script, but my point was: if I'm going to implement the throttle feature as an external program, can I do it without changing anything in my runit configuration whatsoever ? Users shouldn't have to patch their finish scripts in order to use the throttle feature. So the "./run is down, ./finish is executing" information has to be available somewhere outside for it to work. This is a notification problem; we have extensively discussed notification on this list, and I have written a piece of software to do just that, except that it's so ugly I retired it ^^" Another approach to the throttle feature that doesn't require notification from runit would be to have a short-lived program, designed to be called in the finish script, that stores its information (last calling time ans such) in the filesystem. Maybe it's what you were thinking about. But I'm not sure how to make it reliable; storing short-lived information in the filesystem is very error-prone, that's the .pid way, which is precisely what supervision tools were designed to avoid. -- Laurent