From owner-freebsd-current@FreeBSD.ORG Thu Jul 17 02:08:11 2008 Return-Path: Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6170D1065681; Thu, 17 Jul 2008 02:08:11 +0000 (UTC) (envelope-from das@FreeBSD.ORG) Received: from zim.MIT.EDU (ZIM.MIT.EDU [18.95.3.101]) by mx1.freebsd.org (Postfix) with ESMTP id 18D698FC13; Thu, 17 Jul 2008 02:08:10 +0000 (UTC) (envelope-from das@FreeBSD.ORG) Received: from zim.MIT.EDU (localhost [127.0.0.1]) by zim.MIT.EDU (8.14.2/8.14.2) with ESMTP id m6H28Jau022174; Wed, 16 Jul 2008 22:08:19 -0400 (EDT) (envelope-from das@FreeBSD.ORG) Received: (from das@localhost) by zim.MIT.EDU (8.14.2/8.14.2/Submit) id m6H28Jmn022173; Wed, 16 Jul 2008 22:08:19 -0400 (EDT) (envelope-from das@FreeBSD.ORG) Date: Wed, 16 Jul 2008 22:08:19 -0400 From: David Schultz To: Dimitry Andric Message-ID: <20080717020819.GA22145@zim.MIT.EDU> Mail-Followup-To: Dimitry Andric , Doug Barton , Dan Nelson , freebsd-current@FreeBSD.ORG References: <487E533F.7050303@FreeBSD.org> <20080716201819.GB19044@dan.emsphone.com> <487E5DCD.3010206@FreeBSD.org> <20080716210306.GA20758@zim.MIT.EDU> <487E71B4.305@andric.com> <487E7364.2040909@andric.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <487E7364.2040909@andric.com> Cc: Doug Barton , Dan Nelson , freebsd-current@FreeBSD.ORG Subject: Re: Heads Up: shutdown keyword added to 34 rc.d scripts. X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Jul 2008 02:08:11 -0000 On Thu, Jul 17, 2008, Dimitry Andric wrote: > On 2008-07-17 00:09, Dimitry Andric wrote: > > Possibly just the "reverse" of the startup deps? > > Ah, I just see this in rc(8): > > Operation of rc.shutdown > ... > 3. Invoke rcorder(8) to order the files in /etc/rc.d/ and the > $local_startup directories that have a ``shutdown'' KEYWORD (refer > to rcorder(8)'s -k flag), reverse that order, and assign the result > to a variable. > > e.g. it's already taken care of, apparently. :) This just reverses the startup deps, as you suggested earlier. I seem to recall that there was at least one example from Solaris where that was the wrong thing to do. (Clearly it's also overly conservative in some cases.) But they were trying to do more sophistocated things as well, such as automatically restart failed services. (This isn't trivial because when services depend on each other, it's hard to tell which one failed, and it may even take some trial and error.) Maybe we just haven't run into any situations where it matters.