From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.sysutils.supervision.general/480 Path: main.gmane.org!not-for-mail From: Charlie Brady Newsgroups: gmane.comp.sysutils.supervision.general Subject: Re: Who actually gets the TERM signal in "runsvctrl down"? Date: Fri, 25 Jun 2004 12:17:37 -0400 (EDT) Message-ID: References: <40DC4F1F.1080604@deanpence.com> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: sea.gmane.org 1088180272 21670 80.91.224.253 (25 Jun 2004 16:17:52 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 25 Jun 2004 16:17:52 +0000 (UTC) Cc: supervision@list.skarnet.org Original-X-From: supervision-return-718-gcsg-supervision=m.gmane.org@list.skarnet.org Fri Jun 25 18:17:40 2004 Return-path: Original-Received: from antah.skarnet.org ([212.85.147.14]) by deer.gmane.org with smtp (Exim 3.35 #1 (Debian)) id 1BdtOW-0005wH-00 for ; Fri, 25 Jun 2004 18:17:40 +0200 Original-Received: (qmail 12241 invoked by uid 76); 25 Jun 2004 16:18:01 -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 12235 invoked from network); 25 Jun 2004 16:18:01 -0000 X-X-Sender: charlieb@e-smith.charlieb.ott.istop.com Original-To: Dean Hall In-Reply-To: <40DC4F1F.1080604@deanpence.com> Xref: main.gmane.org gmane.comp.sysutils.supervision.general:480 X-Report-Spam: http://spam.gmane.org/gmane.comp.sysutils.supervision.general:480 On Fri, 25 Jun 2004, Dean Hall wrote: > | For "apachectl stop", just do "runsvctrl down apache". For "apachectl > | graceful", do "runsvctrl 1 apache; raunsvctrl u apache". For "apachectrl > | restart", do "runsvctrl t apache; raunsvctrl u apache". Etc. > > Why are you doing the additional "u"? As I understand it, sending a "u" > to the fifo is really necessary if the service is marked as down. Yes. If the service is down and you do "restart" or "graceful", then to preserve the semantics you'll need to up it. The "1" and "t" will be effective, and the "u" ignored if the service is already up, the "1" and "t" will be NOOPS is the service is down, but "u" will bring it up. > BTW, I recommend running apache2 with pgrphack so it won't kill other > things when you kill it. Is there any reason that runsv shouldn't run each run script as a process group leader? I've had programs bring down runsv and runsvdir (and therefore /etc/runit/2). IMO, runsv should protect itself. I can't think of a downside. Gerrit? --- Charlie