From owner-freebsd-current@FreeBSD.ORG Wed Jun 15 09:09:31 2005 Return-Path: X-Original-To: freebsd-current@FreeBSD.ORG Delivered-To: freebsd-current@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2474316A41C for ; Wed, 15 Jun 2005 09:09:31 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from harmony.village.org (vc4-2-0-66.dsl.netrack.net [199.45.160.85]) by mx1.FreeBSD.org (Postfix) with ESMTP id 74A7F43D49 for ; Wed, 15 Jun 2005 09:09:27 +0000 (GMT) (envelope-from imp@bsdimp.com) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.13.3/8.13.1) with ESMTP id j5F6TCLQ017466; Wed, 15 Jun 2005 00:29:13 -0600 (MDT) (envelope-from imp@bsdimp.com) Date: Wed, 15 Jun 2005 00:30:20 -0600 (MDT) Message-Id: <20050615.003020.99022728.imp@bsdimp.com> To: brooks@one-eyed-alien.net From: "M. Warner Losh" In-Reply-To: <20050615061009.GA11914@odin.ac.hmc.edu> References: <20050614205537.D62878@gabby.gsicomp.on.ca> <1118806968.1003.9.camel@localhost> <20050615061009.GA11914@odin.ac.hmc.edu> X-Mailer: Mew version 3.3 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Cc: vova@fbsd.ru, freebsd-current@FreeBSD.ORG, matt@gsicomp.on.ca Subject: Re: HEADSUP: OpenBSD dhclient incoming 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: Wed, 15 Jun 2005 09:09:31 -0000 In message: <20050615061009.GA11914@odin.ac.hmc.edu> Brooks Davis writes: : On Wed, Jun 15, 2005 at 07:42:48AM +0400, Vladimir Grebenschikov wrote: : > ? ??, 14/06/2005 ? 20:57 -0400, Matthew Emmerton ?????: : > > On Tue, 14 Jun 2005, Brooks Davis wrote: : > > : > > > On Tue, Jun 14, 2005 at 10:01:45AM +0400, Vladimir Grebenschikov wrote: : > > >> ? ??, 06/06/2005 ? 20:46 -0700, Brooks Davis ?????: : > > >>> I'm about to start importing the OpenBSD dhclient and required : > > >>> support in /etc. I will unhook dhclient from the build while I work so : > > >>> there shouldn't be much breakage for most people : > > >> : > > >> I have strange behavior of new dhclient + devd: : > > >> : > > >> just after boot (with ethernet plugged) I have no devd events about : > > >> state of media and have interface down, but after first ifconfig (even : > > >> without parameters, even executed by any user) "link state chages to UP" : > > >> event appears and devd starts dhclient on interface. : > > >> : > > >> I do not think that it is desired behavior. : > > >> : > > >> my rc.conf, related to this: : > > >> : > > >> ifconfig_fxp0="dhcp" : > > >> network_interfaces="lo0" : > > >> devd_enable="YES" : > > >> : > > >> Probably I need to comment network_interfaces line, but anyway, now it : > > >> works strange. : > > : > > Shouldn't you have network_interfaces="lo0 fxp0" in order for the rc : > > scripts to run the appropriate ifconfig or dhclient command for each : > > interface? : > : > Probably yes (it works), but why first /sbin/ifconfig, issued by uid!=0 : > triggers dhclient ? : > : > I think behavior should be consistent, either rc.d/netif relay only on : > devd events and does not depends on network_interfaces= or rc.d/netif : > should relay on network_interfaces= and ignore not mentioned interfaces. : > : > Also devd's IFUP event should not depend on user's /bin/ifconfig issued : > (or not issued) by hands. : : There are two issues here. First, if we're going to keep : network_interfaces around, /etc/rc.d/dhclient should honor it and : not start dhclient on interfaces not in either network_interfaces or : removable interfaces. Second, running ifconfig should not be triggering : link events. That makes no sense. I'll have to see if can replicate : that, I'm a bit dubious. ifconfig fxp0 1.2.3.4/24 will kill dhclient every time for me. I've also been seeing weirdness with the new dhclient when i move from network to network on boot when I have the 'old' lease around but no cable connected. I'll see if I can replicate this enough to submit a report. Warner