NetBSD Problem Report #40139

From riastradh@slate.localdomain  Tue Dec  9 08:55:02 2008
Return-Path: <riastradh@slate.localdomain>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
	by narn.NetBSD.org (Postfix) with ESMTP id 1670363B8C6
	for <gnats-bugs@gnats.NetBSD.org>; Tue,  9 Dec 2008 08:55:02 +0000 (UTC)
Message-Id: <20081209083227.9DEC576CC0@slate.localdomain>
Date: Tue,  9 Dec 2008 08:32:27 +0000 (UTC)
From: Taylor R Campbell <campbell@mumble.net>
Reply-To: Taylor R Campbell <campbell@mumble.net>
To: gnats-bugs@gnats.NetBSD.org
Subject: bridge(4) does not transmit DHCP replies to tap(4)
X-Send-Pr-Version: 3.95

>Number:         40139
>Category:       kern
>Synopsis:       bridge(4) does not transmit DHCP replies to tap(4)
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Dec 09 09:00:00 +0000 2008
>Last-Modified:  Sat Mar 21 21:00:03 +0000 2009
>Originator:     Taylor R Campbell <campbell@mumble.net>
>Release:        NetBSD 4.0_STABLE
>Organization:
>Environment:
System: NetBSD slate.localdomain 4.0_STABLE NetBSD 4.0_STABLE (RIABWI) #35: Sun Nov 16 12:42:48 EST 2008 riastradh@Oberon.local:/Users/riastradh/os/netbsd/4/obj/sys/arch/macppc/compile/RIABWI macppc
Architecture: powerpc
Machine: macppc
>Description:

	When a tap(4) interface is on a bridge(4), and a DHCP client
	such as dhclient(8) tries to configure the interface, DHCP
	requests make it over the bridge onto a physical ethernet
	network, but none of the replies on the physical network make
	it back over the bridge to the tap(4) interface.

>How-To-Repeat:

	If <if> is the name of an ethernet interface attached to a
	network with a DHCP server, run

	# ifconfig tap0 create
	# ifconfig bridge0 create
	# brconfig bridge0 add tap0 add <if> up
	# dhclient tap0

	Also run tcpdump(8) on <if>, and watch the outgoing DHCP
	requests and incoming DHCP replies, the latter of which don't
	make it to dhclient(8).

	(Make sure that no DHCP client is running to configure <if>, to
	avoid its interfering with the DHCP client configuring tap0.) 

>Fix:

	Currently the best I can manage is to browse the output of
	tcpdump(8) on the physical interface for DHCP replies, and to
	manually configure the interface from the information I thereby
	glean.  This is a pain.

>Audit-Trail:
From: Quentin Garnier <cube@cubidou.net>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/40139: bridge(4) does not transmit DHCP replies to tap(4)
Date: Sat, 21 Mar 2009 20:09:51 +0100

 --wayzTnRSUXKNfBqd
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: inline
 Content-Transfer-Encoding: quoted-printable

 On Tue, Dec 09, 2008 at 09:00:01AM +0000, Taylor R Campbell wrote:
 > >Number:         40139
 > >Category:       kern
 > >Synopsis:       bridge(4) does not transmit DHCP replies to tap(4)

 It's not an issue with tap(4) (the same happens if you replace it with
 any other Ethernet interface).  If you run ktrace on dhclient, you'll
 see that it receives the packet on its udp socket for port 68.  I don't
 know why it rejects it though.

 --=20
 Quentin Garnier - cube@cubidou.net - cube@NetBSD.org
 "See the look on my face from staying too long in one place
 [...] every time the morning breaks I know I'm closer to falling"
 KT Tunstall, Saving My Face, Drastic Fantastic, 2007.

 --wayzTnRSUXKNfBqd
 Content-Type: application/pgp-signature
 Content-Disposition: inline

 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.9 (NetBSD)

 iQEcBAEBAgAGBQJJxTt/AAoJENgoQloHrPno94wH/RCpQBsD5XWolFC001FDUwJv
 DttTSmddwgegTKf9iMsl+/TLg49kNCjwUrEfKt4MTyGi0rL/DH+6fFR9fhU4klDu
 IZnxCd087gsIe4Lln4e5SjyoZlr6MYTXn72lIOehKT9kuzGhFgulATxUR+Ehya+P
 Vtmtp20uL/1plkUA7chhRbcoeuP/FkZ1u4caNf5eAVUOjK1IPfcJckTx64urfnXd
 pR1jUlQ35fgOCVGw/D8VYjlKpphFSDl9J1ywCyU8wUJy0njGzM4NicmhQ5Bbv9pN
 LHeNZOEVgweV0X8hembwVV1giV8OoEKQZ+U3QNgRnZ9iaU2G7GPafiQIVCJu3HQ=
 =H5u6
 -----END PGP SIGNATURE-----

 --wayzTnRSUXKNfBqd--

From: David Young <dyoung@pobox.com>
To: gnats-bugs@NetBSD.org
Cc: kern-bug-people@netbsd.org, gnats-admin@netbsd.org,
	netbsd-bugs@netbsd.org, Taylor R Campbell <campbell@mumble.net>
Subject: Re: kern/40139: bridge(4) does not transmit DHCP replies to tap(4)
Date: Sat, 21 Mar 2009 15:50:54 -0500

 On Sat, Mar 21, 2009 at 07:10:06PM +0000, Quentin Garnier wrote:
 > The following reply was made to PR kern/40139; it has been noted by GNATS.
 > 
 > From: Quentin Garnier <cube@cubidou.net>
 > To: gnats-bugs@NetBSD.org
 > Cc: 
 > Subject: Re: kern/40139: bridge(4) does not transmit DHCP replies to tap(4)
 > Date: Sat, 21 Mar 2009 20:09:51 +0100
 > 
 >  On Tue, Dec 09, 2008 at 09:00:01AM +0000, Taylor R Campbell wrote:
 >  > >Number:         40139
 >  > >Category:       kern
 >  > >Synopsis:       bridge(4) does not transmit DHCP replies to tap(4)
 >  
 >  It's not an issue with tap(4) (the same happens if you replace it with
 >  any other Ethernet interface).  If you run ktrace on dhclient, you'll
 >  see that it receives the packet on its udp socket for port 68.  I don't
 >  know why it rejects it though.

 dhclient does not log any complaints about those packets?

 Some NICs pass the FCS to the host in promiscuous mode, but not
 otherwise.  Their drivers neither apply M_HASFCS nor trim the ethernet
 checksum from the input mbufs when the NIC is in promiscuous. bridge(4)
 may conceal or compound the defect in those input mbufs.

 Dave

 -- 
 David Young             OJC Technologies
 dyoung@ojctech.com      Urbana, IL * (217) 278-3933

From: Quentin Garnier <cube@cubidou.net>
To: David Young <dyoung@pobox.com>, gnats-bugs@NetBSD.org,
	Taylor R Campbell <campbell@mumble.net>
Cc: 
Subject: Re: kern/40139: bridge(4) does not transmit DHCP replies to tap(4)
Date: Sat, 21 Mar 2009 21:59:54 +0100

 --byLs0wutDcxFdwtm
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: inline
 Content-Transfer-Encoding: quoted-printable

 On Sat, Mar 21, 2009 at 03:50:54PM -0500, David Young wrote:
 > On Sat, Mar 21, 2009 at 07:10:06PM +0000, Quentin Garnier wrote:
 > > The following reply was made to PR kern/40139; it has been noted by GNA=
 TS.
 > >=20
 > > From: Quentin Garnier <cube@cubidou.net>
 > > To: gnats-bugs@NetBSD.org
 > > Cc:=20
 > > Subject: Re: kern/40139: bridge(4) does not transmit DHCP replies to ta=
 p(4)
 > > Date: Sat, 21 Mar 2009 20:09:51 +0100
 > >=20
 > >  On Tue, Dec 09, 2008 at 09:00:01AM +0000, Taylor R Campbell wrote:
 > >  > >Number:         40139
 > >  > >Category:       kern
 > >  > >Synopsis:       bridge(4) does not transmit DHCP replies to tap(4)
 > > =20
 > >  It's not an issue with tap(4) (the same happens if you replace it with
 > >  any other Ethernet interface).  If you run ktrace on dhclient, you'll
 > >  see that it receives the packet on its udp socket for port 68.  I don't
 > >  know why it rejects it though.
 >=20
 > dhclient does not log any complaints about those packets?

 No.  ktrace shows it going almost directly back to select(2) after the
 recvfrom(2).

 > Some NICs pass the FCS to the host in promiscuous mode, but not
 > otherwise.  Their drivers neither apply M_HASFCS nor trim the ethernet
 > checksum from the input mbufs when the NIC is in promiscuous. bridge(4)
 > may conceal or compound the defect in those input mbufs.

 Yeah, I have machines on which dhclient complain about getting 4 extra
 bytes.  It's not fatal though.

 --=20
 Quentin Garnier - cube@cubidou.net - cube@NetBSD.org
 "See the look on my face from staying too long in one place
 [...] every time the morning breaks I know I'm closer to falling"
 KT Tunstall, Saving My Face, Drastic Fantastic, 2007.

 --byLs0wutDcxFdwtm
 Content-Type: application/pgp-signature
 Content-Disposition: inline

 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.9 (NetBSD)

 iQEcBAEBAgAGBQJJxVVKAAoJENgoQloHrPnohYAH/Row4mlsryulLAh5WBojmWZ5
 No8iAMGANhklJaR/FsTMTcXd/ZzM7I8+Jl0wDey5gVlYl8dFWiW8WQcUef9Q8/60
 hCYkZN+RXCKV+IWkRoYIEm/NVSXgZxT2W76NS5NLsVhH6YfjfoxmIqeInMpLy40R
 MqkelByp07EsjqaRGVLrSOGbk+f0oyuGjTTR88Ioyc4cLquXTikbrA9eOcdIhQtC
 2gCGmMrHZuHm6Q93KKEelnrp2ghTofoMOiSjXkhnCI0BCzkAdeAUmo32Dj7dKRCq
 1Ae0HwxQiWEoKDcGgOl1+kmnMoN24o0E0yAlH+B9G+JasucCSyMUWr0t7L3Wq/o=
 =1+oc
 -----END PGP SIGNATURE-----

 --byLs0wutDcxFdwtm--

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.