From owner-freebsd-rc@FreeBSD.ORG Wed May 30 06:17:33 2007 Return-Path: X-Original-To: freebsd-rc@freebsd.org Delivered-To: freebsd-rc@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9ED7916A400; Wed, 30 May 2007 06:17:33 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from cs1.cs.huji.ac.il (cs1.cs.huji.ac.il [132.65.16.10]) by mx1.freebsd.org (Postfix) with ESMTP id 5A5E013C468; Wed, 30 May 2007 06:17:33 +0000 (UTC) (envelope-from danny@cs.huji.ac.il) Received: from pampa.cs.huji.ac.il ([132.65.80.32]) by cs1.cs.huji.ac.il with esmtp id 1HtH7y-000Jlw-PE; Wed, 30 May 2007 08:53:46 +0300 X-Mailer: exmh version 2.7.2 01/07/2005 with nmh-1.2 To: Doug Barton In-reply-to: Your message of Tue, 29 May 2007 16:39:22 -0700 . Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Wed, 30 May 2007 08:53:46 +0300 From: Danny Braniss Message-ID: Cc: freebsd-rc@freebsd.org Subject: Re: rcorder blues 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: Wed, 30 May 2007 06:17:33 -0000 > > hi all, > > Under 6.2 I set early_late_divider to amd, and since local_rc > > points to an 'automounted directory', rcorder will include the rc-files > > from my shared-local/etc/rc.d. > > In theory there should be nothing wrong with doing this, however amd > happens pretty late in the default rcorder, so it is pretty likely > that something is going to get rearranged when you start including > your local files. > by removing some dependencies in amd, i managed to get it to run earlier - but was not easy, it does depend on many things. > > Since 7.0 this 'trick' no longer works, some rc-files, that > > in the first run appeared after amd/early_late_divider, in the second > > run appear before amd, and so never get executed. > > Voila. > > > The quick and dirty solution, was for rc.initdiskless to copy > > the 'shared/local_rc/' to /etc/rc.d (thanks to unionfs:-), and so all > > was 'almost' ok. > > Yeah, that's not a good idea. :) > > > Is there some tool to 'debug' rcorder? ie. list the reason > > for the order? > > Those are two different questions. :) To debug the issue you are > describing I use the patch at > http://people.freebsd.org/~dougb/rc-debug.diff. To understand why > rcorder does things the way it does, read the man page ... then you > pretty much have to go through the PROVIDE, REQUIRE, and BEFORE lines > in the rc.d scripts you have to figure out how you can make things > more deterministic. I don't think it's realistic to expect that by setting/modifying the PROVIDE, REQUIRE, and BEFORE list, one can forsee the result :-) it's more a wish, and rcoder decides :-) > > Please note that (at least on my system) there is a "mostly harmless" > bug in our current ordering that causes the resolv script to be > ordered very late without including /usr/local stuff, and first after > it is included, which means it is never run on my system. If you see > that issue, don't worry about it, it's on the list of things that > should be fixed someday, but isn't a priority. it's not harmless for me, since amd needs hostname :-( I added resolv to NETWORK's REQUIRE:. BTW, I also added to abi PROVIDE: linux, this way i can have some linux depend on it. danny