From owner-freebsd-net@FreeBSD.ORG Mon Mar 19 18:19:20 2012 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CD1EA106566C for ; Mon, 19 Mar 2012 18:19:20 +0000 (UTC) (envelope-from rozhuk.im@gmail.com) Received: from mail-bk0-f54.google.com (mail-bk0-f54.google.com [209.85.214.54]) by mx1.freebsd.org (Postfix) with ESMTP id 4CC9F8FC15 for ; Mon, 19 Mar 2012 18:19:19 +0000 (UTC) Received: by bkcjc3 with SMTP id jc3so6319869bkc.13 for ; Mon, 19 Mar 2012 11:19:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=reply-to:from:to:references:in-reply-to:subject:date:message-id :mime-version:content-type:content-transfer-encoding:x-mailer :content-language:thread-index; bh=USiorudL7mJQWKOo1SubF9zveqPIa/gvu2LW7hZ7MkE=; b=b6WZWkQKXJ52ucJZ65D8hUSG1tms4Yq7QgIeMSnJhxUR8oawVR+bbBSz2zdtgZSKX6 v9F/GaBpWA/4cDZ/H/Oiyrfcb8pmdR3AqVmYuk8LOippTcBThUpuUEv9z3MIE2dn+zjL mfw1ysHz/pMFyA23/yyXZZ7xHg5XBr+Llm2RBM73EoYkyMvtvwGptdVgXHyvfKcoLFEr M87NYi95Ms6LfNCBrK1+SZyWxngqhIt/d7TFA31LCvbOwPN/TxmI19JUas2DlJj3wzku 9OtAJv1xePVSm5ffBOtSfZ6G/Uz1yn7ENM5rNzNCmNsmEVkBE6/6KQHtOZF0tZbzcl3H UGVQ== Received: by 10.204.154.209 with SMTP id p17mr5263068bkw.6.1332181159086; Mon, 19 Mar 2012 11:19:19 -0700 (PDT) Received: from rimwks1w7x64 ([164.215.85.206]) by mx.google.com with ESMTPS id u5sm27310495bka.5.2012.03.19.11.19.16 (version=SSLv3 cipher=OTHER); Mon, 19 Mar 2012 11:19:18 -0700 (PDT) From: rozhuk.im@gmail.com To: , References: <51f939ac5fb636ae90ba1b0fd628e40b@mail.mikej.com> <4f6765b4.0e70cc0a.351f.3bfb@mx.google.com> <2ef74c561a597ebd6508625698a9563f@mail.mikej.com> In-Reply-To: <2ef74c561a597ebd6508625698a9563f@mail.mikej.com> Date: Tue, 20 Mar 2012 03:19:14 +0900 Message-ID: <4f6778a6.0512cc0a.2ef6.545f@mx.google.com> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 12.0 Content-Language: ru Thread-Index: Ac0F85w8LInQTGVBQBKs2H7rOS1XIgACRtPg Cc: Subject: RE: Cloning VLAN interfaces X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Rozhuk.IM@gmail.com List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Mar 2012 18:19:20 -0000 Remove space: name re0-hub:downstream re0-vlan > -----Original Message----- > From: owner-freebsd-net@freebsd.org [mailto:owner-freebsd- > net@freebsd.org] On Behalf Of jammin2night > Sent: Tuesday, March 20, 2012 2:12 AM > To: freebsd-net@freebsd.org > Subject: RE: Cloning VLAN interfaces > > Thanks for you reply! All goes well until: > > (root@charon) ~# ngctl name re0-hub: downstream re0-vlan > ngctl: usage: name > (root@charon) ~# > > > (root@charon) ~# ngctl list > There are 6 total nodes: > Name: Type: vlan ID: 0000001c Num > hooks: > 1 > Name: em0 Type: ether ID: 00000002 Num > hooks: > 0 > Name: re0 Type: ether ID: 00000001 Num > hooks: > 2 > Name: vlan10 Type: ether ID: 00000003 Num > hooks: > 0 > Name: ngctl4248 Type: socket ID: 00000027 Num > hooks: > 0 > Name: re0-hub Type: hub ID: 00000017 Num > hooks: > 3 > (root@charon) ~# > > > > On 19.03.2012 12:58, rozhuk.im@gmail.com wrote: > > #!/bin/sh > > > > ngctl shutdown re0:lower > > ngctl shutdown re0:upper > > > > ngctl mkpeer re0: hub lower lower > > ngctl name re0:lower re0-hub > > ngctl connect re0: re0-hub: upper upper > > > > ngctl mkpeer re0-hub: vlan downstream downstream ngctl name re0-hub: > > downstream re0-vlan ngctl mkpeer re0-vlan: eiface vlan10 ether ngctl > > msg re0-vlan: addfilter '{ vlan=10 hook="vlan10" }' > > > > > >> -----Original Message----- > >> From: owner-freebsd-net@freebsd.org [mailto:owner-freebsd- > >> net@freebsd.org] On Behalf Of jammin2night > >> Sent: Tuesday, March 20, 2012 1:11 AM > >> To: freebsd-net@freebsd.org > >> Subject: Cloning VLAN interfaces > >> > >> FreeBSD charon 9.0-STABLE FreeBSD 9.0-STABLE #14 r233107: Sun Mar 18 > >> 05:26:58 EDT 2012 root@charon:/usr/obj/usr/src/sys/CHARON amd64 > >> > >> Hello: > >> > >> I have a machine that has a 802.1q trunk attached which works fine. > >> I > >> can create VLAN interfaces, apply an IP address to them and all is > >> good. > >> > >> I have VirtualBox running on this machine and need to present an > >> interface to a VM that does not support trunking natively. I've > >> googled and searched the archive trying to figure out how to create > >> an interface that VirtualBox will use where the 802.1Q tags are > >> removed but have not had any success. > >> > >> I attempted to create a netgraph interface like: > >> > >> #!/bin/sh > >> > >> ngctl shutdown re0: > >> ngctl mkpeer re0: vlan lower downstream ngctl name re0:lower vlan > >> ngctl connect re0: vlan: upper upstream ngctl mkpeer vlan: eiface > >> vlan10 ether ngctl msg vlan: addfilter '{ vlan=10 hook="vlan10" }' > >> > >> but this nuked my VLAN10 interface. Using tcpdump I saw no traffic > >> on interface VLAN10 or interface ngeth0. I probably going about this > >> all wrong or just don't get the netgraph hooks. > >> > >> If there is an example as to how to this this I just missed it. > >> > >> Any pointers on how to accomplish this? > >> > >> Thanks. > >> > >> > >> > >> > >> _______________________________________________ > >> freebsd-net@freebsd.org mailing list > >> http://lists.freebsd.org/mailman/listinfo/freebsd-net > >> To unsubscribe, send any mail to > >> "freebsd-net-unsubscribe@freebsd.org" > > > > _______________________________________________ > > freebsd-net@freebsd.org mailing list > > http://lists.freebsd.org/mailman/listinfo/freebsd-net > > To unsubscribe, send any mail to > > "freebsd-net-unsubscribe@freebsd.org" > > _______________________________________________ > freebsd-net@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-net > To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"