Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 May 2008 19:44:42 +0200
From:      Max Laier <max@love2party.net>
To:        freebsd-net@freebsd.org
Subject:   Re: lagg0.2 style vlans on lagg(4) interface
Message-ID:  <200805211944.42418.max@love2party.net>
In-Reply-To: <2e77fc10805211031n6c42ffd2u3dee28164094b83b@mail.gmail.com>
References:  <2e77fc10805211031n6c42ffd2u3dee28164094b83b@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wednesday 21 May 2008 19:31:46 Niki Denev wrote:
> If one tries to use lagg0.2 style vlans on lagg0 interface configured
> from rc.conf it does't work.
> The problem is that all of the cloned interfaces (lagg0 , lagg0.2, etc)
> are created before any other interface configuration is done,
> and in this case lagg0 is created, then lagg0.2 is created.
> But because lagg0 does not have any members yet, it's MAC address
> is all zeroes, and this is inherited by the vlan interfaces.
> At the next step the members are added to the lagg0 interface and it's
> mac address gets set,
> but the vlan interfaces never see this change and remain with mac
> address 00:00:00:00:00:00 and in unusable state.
>
> Does it sound reasonable for the vlan(4) interfaces to update their
> mac address when their parent changes it.
> (this should probably look more like the parent telling the vlans
> attached to it that it's mac has changed, but
> i'm not sure if the parent knows about children interfaces)

It doesn't (and shouldn't have to).  I'd simply add an 
EVENTHANDLER_INVOKE(ifaddr_event, ifp) to if_setlladdr() - we do that for 
INET[6] address already.  Then vlan (and any other device interested in 
LLaddress changes) can simply register to that eventhandler and resync.

-- 
/"\  Best regards,                      | mlaier@freebsd.org
\ /  Max Laier                          | ICQ #67774661
 X   http://pf4freebsd.love2party.net/  | mlaier@EFnet
/ \  ASCII Ribbon Campaign              | Against HTML Mail and News



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