From owner-freebsd-net@FreeBSD.ORG Fri Aug 8 06:04:57 2008 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 546431065676 for ; Fri, 8 Aug 2008 06:04:57 +0000 (UTC) (envelope-from Younger.Wang@packetfront.com) Received: from mail.packetfront.com (mail.packetfront.com [212.247.6.198]) by mx1.freebsd.org (Postfix) with ESMTP id C31928FC13 for ; Fri, 8 Aug 2008 06:04:56 +0000 (UTC) (envelope-from Younger.Wang@packetfront.com) Received: from localhost (localhost [127.0.0.1]) by mail.packetfront.com (Postfix) with ESMTP id E85C2A30C1 for ; Fri, 8 Aug 2008 07:37:02 +0200 (CEST) Received: from mail.packetfront.com ([127.0.0.1]) by localhost (mail.packetfront.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 32672-07 for ; Fri, 8 Aug 2008 07:37:02 +0200 (CEST) Received: from fw.packetfront.com (unknown [192.121.165.1]) by mail.packetfront.com (Postfix) with ESMTP id A671BA30A4 for ; Fri, 8 Aug 2008 07:37:02 +0200 (CEST) X-MimeOLE: Produced By Microsoft Exchange V6.5 Content-class: urn:content-classes:message MIME-Version: 1.0 Date: Fri, 8 Aug 2008 07:39:20 +0200 Message-ID: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: (Netgraph problem) Inner tag and outer tag swapped Thread-Index: Acj5GRsFFO28nHmETJCJcoGu7FyVSA== From: "Younger Wang" To: X-Virus-Scanned: by amavisd-new-20030616-p10 (Debian) at packetfront.com Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: (Netgraph problem) Inner tag and outer tag swapped X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Aug 2008 06:04:57 -0000 Hi, =20 fxp0 is connected to a trunk port. Frames tagged with VID=3D201 arrives = at fxp0 from a switch trunk port, I expect it will be captured at hub_QinQ, with outer tag =3D 4000, and inner tag =3D 201. But in fact, it was = received with the outer and inner tags reversed. =20 But if I inject the same frame on hub_c4000, the frame is received at hub_QinQ as expected (inner tag =3D 201, outer tag =3D 4000). I am = really confused. Has anyone seen the same problem? Big thanks. =20 Here is my netgraph setup: =20 ngctl mkpeer fxp0: hub lower physical ngctl name fxp0:lower hub_c4000 =20 ngctl mkpeer hub_c4000: vlan up vlan4000 ngctl name hub_c4000:up vlan_QinQ =20 ngctl mkpeer vlan_QinQ: hub downstream down0 ngctl name vlan_QinQ:downstream hub_QinQ =20 ngctl msg vlan_QinQ: addfilter { vlan=3D4000 hook=3D"vlan4000" } =20 BR Younger Wang =20 =20