From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.sysutils.supervision.general/2082 Path: news.gmane.org!not-for-mail From: Wayne Marshall Newsgroups: gmane.comp.sysutils.supervision.general Subject: Re: [announce] perp-2.03: persistent process supervision Date: Mon, 14 Mar 2011 16:35:20 +0100 Organization: b0llix.net: un!x for the deranged Message-ID: <20110314163520.689b7ad3@b0llix.net> References: <20110314113933.3544df05@b0llix.net> <20110314131706.GA17316@skarnet.org> <20110314150225.7cf61c3c@b0llix.net> <4D7E24DA.2030404@robinbowes.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1300116956 19547 80.91.229.12 (14 Mar 2011 15:35:56 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 14 Mar 2011 15:35:56 +0000 (UTC) Cc: supervision@list.skarnet.org To: Charlie Brady Original-X-From: supervision-return-2316-gcsg-supervision=m.gmane.org@list.skarnet.org Mon Mar 14 16:35:52 2011 Return-path: Envelope-to: gcsg-supervision@lo.gmane.org Original-Received: from antah.skarnet.org ([212.85.147.14]) by lo.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1Pz9oE-00084Q-2X for gcsg-supervision@lo.gmane.org; Mon, 14 Mar 2011 16:35:50 +0100 Original-Received: (qmail 4038 invoked by uid 76); 14 Mar 2011 15:38:10 -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 4030 invoked from network); 14 Mar 2011 15:38:10 -0000 In-Reply-To: X-Mailer: Claws Mail 3.7.7 (GTK+ 2.22.1; x86_64--netbsd) Xref: news.gmane.org gmane.comp.sysutils.supervision.general:2082 Archived-At: On Mon, 14 Mar 2011 11:03:45 -0400 (EDT) Charlie Brady wrote: > > On Mon, 14 Mar 2011, Robin Bowes wrote: > > > On 14/03/11 14:02, Wayne Marshall wrote: > > > > > Under normal (default) configurations, whenever perpd(8) > > > terminates it is restarted by either perpboot(8), or > > > init(8) with a "respawn" configuration in inittab(5). > > > perpd(8) then restarts all services marked for activation > > > in /etc/perp. > > > > So, if I have a service that is normally running, ie. starts > > at boot, but I have taken it down manually for whatever > > reason, and perpd dies, then my service will also be > > re-started? > > And presumably the converse will apply as well. This is a > problem with runit (and daemontools) - if a service has a > 'down' file, but has been later started, a dying runsv (e.g. > if killed by the OoM killer, or by a service which kills its > process group) will be replaced by runsvdir, but the service > will stay down. > This is not so much a "problem" of design, but rather of adminsistrative clarity. Use "flag.down" only when you don't want a service to start immediately with perpd, but do want it activated and available to perpctl administration. As an example, I use a wpa_supplicant service definition on my laptop. It is defined with "flag.down", because I don't care for a wireless connection in all circumstances. Other network scripts may then call: perpctl up wpa_supplicant or perpctl down wpa_supplicant as necessary. Otherwise -- and generally for any truly persistent process service -- administrators will avoid using the "flag.down" mechanism in favor of the easy, in-place service activation/deactivation mechanism that perpd provides with the service directory sticky bit. Wayne