From owner-freebsd-rc@FreeBSD.ORG Fri Jan 23 08:15:52 2009 Return-Path: Delivered-To: freebsd-rc@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D9BD1106573C for ; Fri, 23 Jan 2009 08:15:52 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from mail2.fluidhosting.com (mx22.fluidhosting.com [204.14.89.5]) by mx1.freebsd.org (Postfix) with ESMTP id 82C8F8FC19 for ; Fri, 23 Jan 2009 08:15:52 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: (qmail 26232 invoked by uid 399); 23 Jan 2009 07:49:11 -0000 Received: from localhost (HELO ?192.168.0.19?) (dougb@dougbarton.us@127.0.0.1) by localhost with ESMTPAM; 23 Jan 2009 07:49:11 -0000 X-Originating-IP: 127.0.0.1 X-Sender: dougb@dougbarton.us Message-ID: <49797693.70102@FreeBSD.org> Date: Thu, 22 Jan 2009 23:49:39 -0800 From: Doug Barton Organization: http://www.FreeBSD.org/ User-Agent: Thunderbird 2.0.0.19 (Windows/20081209) MIME-Version: 1.0 To: Thomas Quinot References: <200901212315.n0LNFPOZ099152@freefall.freebsd.org> <20090122130513.GA70426@melamine.cuivre.fr.eu.org> In-Reply-To: <20090122130513.GA70426@melamine.cuivre.fr.eu.org> X-Enigmail-Version: 0.95.7 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: freebsd-rc@FreeBSD.org Subject: Re: conf/130782: rc(8) makes undesirable assumptions on local startup scripts X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Discussion related to /etc/rc.d design and implementation." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 23 Jan 2009 08:15:54 -0000 Thomas Quinot wrote: > * dougb@FreeBSD.org, 2009-01-22 : > >> State-Changed-From-To: open->closed >> State-Changed-By: dougb >> State-Changed-When: Wed Jan 21 23:13:37 UTC 2009 >> State-Changed-Why: >> >> I think that you misunderstand what fast* and quiet* do. >> Short version is that they are handled internally by rc.d >> so that the script itself needs no knowledge of them. > > Doug, > > At first I was a bit surprised by your response, since the behaviour we > had observed here clearly isn't consistent with your description, so I > investigated a bit further, and I think I now understand what is going > on. > > Startup scripts actually *do* need to handle fast* and quiet* themselves > *if* they are recognized by /etc/rc as "new style" scripts; everything > is indeed handled transparently by /etc/rc.d/local for local scripts > that are *not* "new style" scripts. I've read that sentence several times now, and I'm pretty sure at least one of us is confused. :) > The problem we had was an inconsistent script that *had* a "# PROVIDES:" > comment (and so was deemed "new style" by /etc/rc), Actually it's a routine in rc.subr that handles this, but basically, yes. > BUT failed to > handle faststart & co (or use run_rc_command to handle them > automatically). Well that just doesn't make sense. :) When I chose what to look for in a script to determine "new" vs. "old" I thought PROVIDE was a logical choice since it will be close to the top (and this is the key bit), and I couldn't see any reason why an old style script would include that line. > So, in the end I agree that the system scripts' behaviour is just fine > (contrary to what I initially reported), but I still think we should > clarify our documentation regarding the distinction between "new" and > "old" startup scripts. If you have suggestions on where and how to do that I'll be glad to take a look. Doug -- This .signature sanitized for your protection