From owner-freebsd-questions@FreeBSD.ORG Mon Jul 27 21:48:48 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 951AD10656C4 for ; Mon, 27 Jul 2009 21:48:48 +0000 (UTC) (envelope-from dan@dan.emsphone.com) Received: from email2.allantgroup.com (email2.emsphone.com [199.67.51.116]) by mx1.freebsd.org (Postfix) with ESMTP id 4F1098FC13 for ; Mon, 27 Jul 2009 21:48:48 +0000 (UTC) (envelope-from dan@dan.emsphone.com) Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by email2.allantgroup.com (8.14.0/8.14.0) with ESMTP id n6RLmlV1069906 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Mon, 27 Jul 2009 16:48:47 -0500 (CDT) (envelope-from dan@dan.emsphone.com) Received: from dan.emsphone.com (smmsp@localhost [127.0.0.1]) by dan.emsphone.com (8.14.3/8.14.3) with ESMTP id n6RLmlo5028894 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Mon, 27 Jul 2009 16:48:47 -0500 (CDT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.14.3/8.14.3/Submit) id n6RLmlTY028892; Mon, 27 Jul 2009 16:48:47 -0500 (CDT) (envelope-from dan) Date: Mon, 27 Jul 2009 16:48:46 -0500 From: Dan Nelson To: Peter Steele Message-ID: <20090727214846.GX63413@dan.emsphone.com> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-OS: FreeBSD 7.2-STABLE User-Agent: Mutt/1.5.19 (2009-01-05) X-Virus-Scanned: ClamAV version 0.94.2, clamav-milter version 0.94.2 on email2.allantgroup.com X-Virus-Status: Clean X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0.2 (email2.allantgroup.com [199.67.51.78]); Mon, 27 Jul 2009 16:48:47 -0500 (CDT) X-Scanned-By: MIMEDefang 2.45 Cc: freebsd-questions@freebsd.org Subject: Re: What order are options in rc.conf processed? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 27 Jul 2009 21:48:48 -0000 In the last episode (Jul 27), Peter Steele said: > We have an rc.conf file that looks something like this: [...] > In a recent reboot test, when "ourapp" started, it checked to see if an IP > was assigned to the system and there was not, causing it to take an > unexpected logic path. Our understanding though was that since we had an > entry in rc.conf defining the IP then our app should have started after > that IP was assigned. Is this true or is there potentially a timing issue > here? rc.conf is just a script that sets a bunch of environment variables for the /etc/rc.d/* scripts to use. The order the variables are set in that file does not matter. If you want your script to run after network interfaces are set up, you'll want to add a "REQUIRE: NETWORKING" line. See the rc and rcorder manpages for more info, and take a look at the files in /etc/rc.d/ for examples. -- Dan Nelson dnelson@allantgroup.com