Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 2 Oct 2005 23:22:13 +0400
From:      Gleb Smirnoff <glebius@FreeBSD.org>
To:        noname <neon777@gmail.com>, julian@FreeBSD.org
Cc:        freebsd-net@FreeBSD.org
Subject:   Re: why ng_bridge does not like DHCP?
Message-ID:  <20051002192213.GA45345@cell.sick.ru>
In-Reply-To: <46a3a47205081415122806a653@mail.gmail.com>
References:  <46a3a47205081415122806a653@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Aug 15, 2005 at 01:12:31AM +0300, noname wrote:
n>  freebsd 5.4 stable. xl0 is connected via ng_bridge to ngeth0 in this way:
n> 
n> [root@asd:~]# ifconfig xl0 up
n> [root@asd:~]# ngctl mkpeer . eiface hook ether
n> [root@asd:~]# ifconfig ngeth0 up
n> [root@asd:~]# ngctl mkpeer xl0: bridge lower link0
n> [root@asd:~]# ngctl name xl0:lower mybridge
n> [root@asd:~]# ngctl connect ngeth0: mybridge: lower link1
n> [root@asd:~]# ngctl connect ngeth0: mybridge: upper link2
n> [root@asd:~]# ngctl msg xl0: setautosrc 0
n> [root@asd:~]# ngctl msg xl0: setpromisc 1
n> [root@asd:~]# ifconfig ngeth0 ether 00:12:12:12:12:12
n> [root@asd:~]# dhclient ngeth0
n> 
n> using tcpdump I can see dhcp request leaving from ngeth0, passing
n> through xl0, dhcp reply comes back through xl0 but it doesn't reach
n> ngeth0. Why?
n> 
n> If I give ip-address with ifconfig, everything works fine. Also
n> getting ip with dhcp to xl0, without touching netgraph works fine. Any
n> clues?

Do not use ngeth0: node. This is a ng_ether node, attached to Ethernet
interface created by your ng_eiface. After your second command you
have created ng_eiface node, and it is left unnamed. Then you use not
correct node, but its ng_ether fantom.

Probably we should add a protection to avoid ng_ether nodes autocreate
theirselves attached to ng_eiface nodes. This is useless and confuses
people. Julian, what do you think?

-- 
Totus tuus, Glebius.
GLEBIUS-RIPN GLEB-RIPE



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20051002192213.GA45345>