From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.sysutils.supervision.general/495 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: Sat, 26 Jun 2004 11:45:24 -0400 (EDT) Message-ID: References: NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: sea.gmane.org 1088264739 31972 80.91.224.253 (26 Jun 2004 15:45:39 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 26 Jun 2004 15:45:39 +0000 (UTC) Cc: supervision@list.skarnet.org Original-X-From: supervision-return-733-gcsg-supervision=m.gmane.org@list.skarnet.org Sat Jun 26 17:45:28 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 1BeFMu-0002dU-00 for ; Sat, 26 Jun 2004 17:45:28 +0200 Original-Received: (qmail 22471 invoked by uid 76); 26 Jun 2004 15:45:49 -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 22465 invoked from network); 26 Jun 2004 15:45:49 -0000 X-X-Sender: charlieb@e-smith.charlieb.ott.istop.com Original-To: Lloyd Zusman In-Reply-To: Xref: main.gmane.org gmane.comp.sysutils.supervision.general:495 X-Report-Spam: http://spam.gmane.org/gmane.comp.sysutils.supervision.general:495 On Sat, 26 Jun 2004, Lloyd Zusman wrote: > Lloyd Zusman writes: > > > [ ... ] > > > > restart: runscvtrl t apache; runsvctrl u apache > > (causes cleanup stuff to run during the second command) > > We both suggested this one, but I have a question: > > Why do we need the second "u" command? Won't the "run" script restart > on its own after the "t" command, thereby obviating the need for the "u" > command? In this case, the cleanup stuff in the script will get > re-invoked on restart, correct? Please re-read previous messages (carefully) if something isn't clear. This was answered earlier. To answer your questions - yes to both. But .. "apachectl restart" will start apache if it is not already running. One of the "runsvctrl t" and "runsvctl u" will have no effect during restart - but you need to know whether apache is already running to know which one. The order of "t" and "u" is significant (as is "1" and "u" for "graceful"). If you do them in the opposite order, you may hit apache with signals during startup, which might result in unexpected behaviour. --- Charlie