From owner-freebsd-current@FreeBSD.ORG Mon Jul 31 11:26:05 2006 Return-Path: X-Original-To: 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 A476C16A4DA for ; Mon, 31 Jul 2006 11:26:05 +0000 (UTC) (envelope-from ianf@hetzner.co.za) Received: from hetzner.co.za (office.dc2.cpt.your-server.co.za [196.7.147.230]) by mx1.FreeBSD.org (Postfix) with ESMTP id 10E7F43D49 for ; Mon, 31 Jul 2006 11:26:04 +0000 (GMT) (envelope-from ianf@hetzner.co.za) Received: from localhost ([127.0.0.1] helo=ian.hetzner.africa) by hetzner.co.za with esmtp (Exim 4.62 (FreeBSD)) (envelope-from ) id 1G7VuJ-000560-Dh; Mon, 31 Jul 2006 13:25:59 +0200 To: pyunyh@gmail.com From: Ian FREISLICH In-Reply-To: Message from Pyun YongHyeon of "Mon, 31 Jul 2006 14:44:21 +0900." <20060731054421.GB35573@cdnetworks.co.kr> X-Attribution: BOFH Date: Mon, 31 Jul 2006 13:25:59 +0200 Sender: ianf@hetzner.co.za Message-Id: Cc: current@freebsd.org Subject: Re: em promiscuous mode bug? 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: Mon, 31 Jul 2006 11:26:05 -0000 Pyun YongHyeon wrote: > On Mon, Jul 31, 2006 at 07:16:03AM +0200, Ian FREISLICH wrote: > > Pyun YongHyeon wrote: > > > Hardware VLAN tagging was disabled in em(4) when it operates > > > in promiscuous mode and em(4) will insert a VLAN tag in the > > > driver. > > > > Um, no. When an em interface with hardware VLAN tagging enabled > > is placed in promiscuous mode, it just _stops_ tagging. Entirely. > > The 802.1Q vlan just breaks. > > > > Would you try latest em(4) in CURRENT?(if_em.c, rev. 1.122) No change with r1.122 (used to be r1.116). Note that with VLAN_HWTAGGING enabled, both hosts bring up their carp interface as master. This is because none of the frames are tagged when the carp driver puts the vlan interface which in turn puts the em interface into promiscuous mode. You stated that in an earlier email that VLAN_HWTAGGING is disabled when the interface is placed in promiscuous mode. Is there any reason for this appart from not being to view the VLAN header with tcpdump? My site runs a lot of VLANS (500+) and it would be nice to offload this work to the card. With vlanhwtag enabled: Host1 em1: flags=8943 mtu 1500 options=db ether 00:04:23:ce:cc:cd media: Ethernet autoselect (1000baseTX ) status: active vlan1: flags=8943 mtu 1500 options=3 inet 10.0.0.1 netmask 0xffffff00 broadcast 10.0.0.255 ether 00:04:23:ce:cc:cd media: Ethernet autoselect (1000baseTX ) status: active vlan: 1 parent interface: em1 carp2: flags=49 mtu 1500 inet 10.0.0.3 netmask 0xffffff00 carp: MASTER vhid 2 advbase 1 advskew 0 Host2 em1: flags=8943 mtu 1500 options=cb ether 00:04:23:ce:ca:a1 media: Ethernet autoselect (1000baseTX ) status: active vlan1: flags=8943 mtu 1500 inet 10.0.0.2 netmask 0xffffff00 broadcast 10.0.0.255 ether 00:04:23:ce:ca:a1 media: Ethernet autoselect (1000baseTX ) status: active vlan: 1 parent interface: em1 carp2: flags=49 mtu 1500 inet 10.0.0.3 netmask 0xffffff00 carp: MASTER vhid 2 advbase 1 advskew 0 With vlanhwtag disabled: Host1 em1: flags=8943 mtu 1500 options=cb ether 00:04:23:ce:cc:cd media: Ethernet autoselect (1000baseTX ) status: active vlan1: flags=8943 mtu 1500 inet 10.0.0.1 netmask 0xffffff00 broadcast 10.0.0.255 ether 00:04:23:ce:cc:cd media: Ethernet autoselect (1000baseTX ) status: active vlan: 1 parent interface: em1 carp2: flags=49 mtu 1500 inet 10.0.0.3 netmask 0xffffff00 carp: MASTER vhid 2 advbase 1 advskew 0 Host2 em1: flags=8943 mtu 1500 options=cb ether 00:04:23:ce:ca:a1 media: Ethernet autoselect (1000baseTX ) status: active vlan1: flags=8943 mtu 1500 inet 10.0.0.2 netmask 0xffffff00 broadcast 10.0.0.255 ether 00:04:23:ce:ca:a1 media: Ethernet autoselect (1000baseTX ) status: active vlan: 1 parent interface: em1 carp2: flags=49 mtu 1500 inet 10.0.0.3 netmask 0xffffff00 carp: BACKUP vhid 2 advbase 1 advskew 0 Ian -- Ian Freislich