From owner-freebsd-questions@freebsd.org Mon Aug 31 05:29:22 2015 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id F34719C6301 for ; Mon, 31 Aug 2015 05:29:22 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mx01.qsc.de (mx01.qsc.de [213.148.129.14]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B96ED39F for ; Mon, 31 Aug 2015 05:29:22 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r56.edvax.de (port-92-195-125-111.dynamic.qsc.de [92.195.125.111]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx01.qsc.de (Postfix) with ESMTPS id 5B87F3CEF5; Mon, 31 Aug 2015 07:29:14 +0200 (CEST) Received: from r56.edvax.de (localhost [127.0.0.1]) by r56.edvax.de (8.14.5/8.14.5) with SMTP id t7V5TD0Y002026; Mon, 31 Aug 2015 07:29:13 +0200 (CEST) (envelope-from freebsd@edvax.de) Date: Mon, 31 Aug 2015 07:29:13 +0200 From: Polytropon To: perryh@pluto.rain.com (Perry Hutchison) Cc: mueller6724@bellsouth.net, freebsd-questions@freebsd.org Subject: Re: disabling dhclient Message-Id: <20150831072913.0363f0ce.freebsd@edvax.de> In-Reply-To: <55e3deee.rst6YFxS1jQ+SXFE%perryh@pluto.rain.com> References: <55e25852.0Xpg4zY1btmbpx9Z%perryh@pluto.rain.com> <55e282fc.s+OSZJ/KaD3iwr7U%perryh@pluto.rain.com> <15727.94738.bm@smtp116.sbc.mail.ne1.yahoo.com> <55e3deee.rst6YFxS1jQ+SXFE%perryh@pluto.rain.com> Reply-To: Polytropon Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 31 Aug 2015 05:29:23 -0000 On Sun, 30 Aug 2015 21:58:22 -0700, Perry Hutchison wrote: > "Thomas Mueller" wrote: > > > There is a line in /etc/defaults/rc.conf > > > > dhclient_program="/sbin/dhclient" # Path to dhcp client program. > > > > Setting dhclient_program="/usr/bin/true" in /etc/rc.conf would > > avoid the need to hack dhclient itself > > That still seems in the sledgehammer category, since I doubt it's > the intended use of the knob (which is more likely intended to select > a different DHCP client, perhaps from a port). However, it's worth > a try. > > I suspect /bin/sync may be a better choice than /usr/bin/true, > since devd can potentially fire up before /usr has been mounted; > alternatively one could copy /usr/bin/true into /bin or /sbin (but > then we are back to hacking on the system rather than configuring > it). The choice of a "no action substitute" might be a problem when $dhclient_program is called with command line parameters. Such a program (or custom script) should accept possible parameters and ignore them. Of course, "sync" fulfills this requirement. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...