netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Can linux kernel bridge forward 802.1q tagged vlan packets?
@ 2013-08-22 20:44 Stephan von Krawczynski
  2013-08-22 21:49 ` Marek Kierdelewicz
  0 siblings, 1 reply; 6+ messages in thread
From: Stephan von Krawczynski @ 2013-08-22 20:44 UTC (permalink / raw)
  To: bridge; +Cc: netdev

Hello all,

first it seemed a trivial question to me, but since I could not find anybody
being neither able to answer this question nor giving a short config example
I'd like to ask here, maybe this is the right place.
My general idea is to bridge tagged vlan packets from a physical interface
(intel) to a virtual interface (virtio in qemu) and not losing the tags, so
the qemu guest can use vconfig and friends to get some vlan interfaces.
Is this possible and are there any additional steps necessary besides the
usual bridge configuration?
What bothers me especially is the vlan filtering done by nics which can
prevent to even receive the packets from the LAN.
And on the other side of course can the bridge code forward packets including
tags so that virtio is able to handle them?

-- 
Regards,
Stephan

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Can linux kernel bridge forward 802.1q tagged vlan packets?
  2013-08-22 20:44 Can linux kernel bridge forward 802.1q tagged vlan packets? Stephan von Krawczynski
@ 2013-08-22 21:49 ` Marek Kierdelewicz
  2013-08-22 22:19   ` Stephen Hemminger
  0 siblings, 1 reply; 6+ messages in thread
From: Marek Kierdelewicz @ 2013-08-22 21:49 UTC (permalink / raw)
  To: Stephan von Krawczynski; +Cc: netdev, bridge

Hi,

>My general idea is to bridge tagged vlan packets from a physical
>interface (intel) to a virtual interface (virtio in qemu) and not
>losing the tags, so the qemu guest can use vconfig and friends to get
>some vlan interfaces. Is this possible and are there any additional
>steps necessary besides the usual bridge configuration?

I'm using this setup with KVM virtualization (Qemu's successor). It
didn't work with default nic type for guest (realtek I think) as 802.1q
tags were not preserved properly in one of the directions. I don't
remember specifics. Anyway using e1000 driver instead of default fixed
it. Works like a charm.

Best regards,
Marek Kierdelewicz

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Can linux kernel bridge forward 802.1q tagged vlan packets?
  2013-08-22 21:49 ` Marek Kierdelewicz
@ 2013-08-22 22:19   ` Stephen Hemminger
  2013-08-23  4:22     ` [Bridge] " Stephan von Krawczynski
  0 siblings, 1 reply; 6+ messages in thread
From: Stephen Hemminger @ 2013-08-22 22:19 UTC (permalink / raw)
  To: Marek Kierdelewicz; +Cc: bridge, Stephan von Krawczynski, netdev

On Thu, 22 Aug 2013 23:49:41 +0200
Marek Kierdelewicz <marek@piasta.pl> wrote:

> Hi,
> 
> >My general idea is to bridge tagged vlan packets from a physical
> >interface (intel) to a virtual interface (virtio in qemu) and not
> >losing the tags, so the qemu guest can use vconfig and friends to get
> >some vlan interfaces. Is this possible and are there any additional
> >steps necessary besides the usual bridge configuration?
> 
> I'm using this setup with KVM virtualization (Qemu's successor). It
> didn't work with default nic type for guest (realtek I think) as 802.1q
> tags were not preserved properly in one of the directions. I don't
> remember specifics. Anyway using e1000 driver instead of default fixed
> it. Works like a charm.

KVM e1000 Vnic doesn't do VLAN offloading at least in my experience.
Virtio works fine.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Bridge] Can linux kernel bridge forward 802.1q tagged vlan packets?
  2013-08-22 22:19   ` Stephen Hemminger
@ 2013-08-23  4:22     ` Stephan von Krawczynski
  2013-08-23  4:58       ` Jeff Kirsher
  0 siblings, 1 reply; 6+ messages in thread
From: Stephan von Krawczynski @ 2013-08-23  4:22 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: Marek Kierdelewicz, bridge, netdev

On Thu, 22 Aug 2013 15:19:41 -0700
Stephen Hemminger <stephen@networkplumber.org> wrote:

> On Thu, 22 Aug 2013 23:49:41 +0200
> Marek Kierdelewicz <marek@piasta.pl> wrote:
> 
> > Hi,
> > 
> > >My general idea is to bridge tagged vlan packets from a physical
> > >interface (intel) to a virtual interface (virtio in qemu) and not
> > >losing the tags, so the qemu guest can use vconfig and friends to get
> > >some vlan interfaces. Is this possible and are there any additional
> > >steps necessary besides the usual bridge configuration?
> > 
> > I'm using this setup with KVM virtualization (Qemu's successor). It
> > didn't work with default nic type for guest (realtek I think) as 802.1q
> > tags were not preserved properly in one of the directions. I don't
> > remember specifics. Anyway using e1000 driver instead of default fixed
> > it. Works like a charm.
> 
> KVM e1000 Vnic doesn't do VLAN offloading at least in my experience.
> Virtio works fine.

Ok guys, here is one of the major questions in this issue:

How did you manage to convince the _host_ interface driver (in my setup "igb"
from intel) to get the vlan tagged packets from the LAN port. igb has a vlan
filter function built in and reads _no_ tagged packets at all if the driver
does not tell it to. And in case of "up-ing" the interface for attachment to a
bridge it does not configure this vlan filter.
How is this expected to work?

-- 
Regards,
Stephan

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [Bridge] Can linux kernel bridge forward 802.1q tagged vlan packets?
  2013-08-23  4:22     ` [Bridge] " Stephan von Krawczynski
@ 2013-08-23  4:58       ` Jeff Kirsher
  2013-08-26 10:21         ` Stephan von Krawczynski
  0 siblings, 1 reply; 6+ messages in thread
From: Jeff Kirsher @ 2013-08-23  4:58 UTC (permalink / raw)
  To: Stephan von Krawczynski, Carolyn Wyborny, mitch.a.williams
  Cc: Stephen Hemminger, Marek Kierdelewicz, bridge, netdev

Adding Carolyn Wyborny (igb maintainer) and Mitch Williams (igbvf maintainer)...

On Thu, Aug 22, 2013 at 9:22 PM, Stephan von Krawczynski
<skraw@ithnet.com> wrote:
> On Thu, 22 Aug 2013 15:19:41 -0700
> Stephen Hemminger <stephen@networkplumber.org> wrote:
>
>> On Thu, 22 Aug 2013 23:49:41 +0200
>> Marek Kierdelewicz <marek@piasta.pl> wrote:
>>
>> > Hi,
>> >
>> > >My general idea is to bridge tagged vlan packets from a physical
>> > >interface (intel) to a virtual interface (virtio in qemu) and not
>> > >losing the tags, so the qemu guest can use vconfig and friends to get
>> > >some vlan interfaces. Is this possible and are there any additional
>> > >steps necessary besides the usual bridge configuration?
>> >
>> > I'm using this setup with KVM virtualization (Qemu's successor). It
>> > didn't work with default nic type for guest (realtek I think) as 802.1q
>> > tags were not preserved properly in one of the directions. I don't
>> > remember specifics. Anyway using e1000 driver instead of default fixed
>> > it. Works like a charm.
>>
>> KVM e1000 Vnic doesn't do VLAN offloading at least in my experience.
>> Virtio works fine.
>
> Ok guys, here is one of the major questions in this issue:
>
> How did you manage to convince the _host_ interface driver (in my setup "igb"
> from intel) to get the vlan tagged packets from the LAN port. igb has a vlan
> filter function built in and reads _no_ tagged packets at all if the driver
> does not tell it to. And in case of "up-ing" the interface for attachment to a
> bridge it does not configure this vlan filter.
> How is this expected to work?
>
> --
> Regards,
> Stephan
>
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html



-- 
Cheers,
Jeff

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Can linux kernel bridge forward 802.1q tagged vlan packets?
  2013-08-23  4:58       ` Jeff Kirsher
@ 2013-08-26 10:21         ` Stephan von Krawczynski
  0 siblings, 0 replies; 6+ messages in thread
From: Stephan von Krawczynski @ 2013-08-26 10:21 UTC (permalink / raw)
  To: Jeff Kirsher
  Cc: bridge, Marek Kierdelewicz, mitch.a.williams, Stephen Hemminger,
	netdev, Carolyn Wyborny

On Thu, 22 Aug 2013 21:58:58 -0700
Jeff Kirsher <jeffrey.t.kirsher@intel.com> wrote:

> Adding Carolyn Wyborny (igb maintainer) and Mitch Williams (igbvf maintainer)...
> 
> On Thu, Aug 22, 2013 at 9:22 PM, Stephan von Krawczynski
> <skraw@ithnet.com> wrote:
> > On Thu, 22 Aug 2013 15:19:41 -0700
> > Stephen Hemminger <stephen@networkplumber.org> wrote:
> >
> >> On Thu, 22 Aug 2013 23:49:41 +0200
> >> Marek Kierdelewicz <marek@piasta.pl> wrote:
> >>
> >> > Hi,
> >> >
> >> > >My general idea is to bridge tagged vlan packets from a physical
> >> > >interface (intel) to a virtual interface (virtio in qemu) and not
> >> > >losing the tags, so the qemu guest can use vconfig and friends to get
> >> > >some vlan interfaces. Is this possible and are there any additional
> >> > >steps necessary besides the usual bridge configuration?
> >> >
> >> > I'm using this setup with KVM virtualization (Qemu's successor). It
> >> > didn't work with default nic type for guest (realtek I think) as 802.1q
> >> > tags were not preserved properly in one of the directions. I don't
> >> > remember specifics. Anyway using e1000 driver instead of default fixed
> >> > it. Works like a charm.
> >>
> >> KVM e1000 Vnic doesn't do VLAN offloading at least in my experience.
> >> Virtio works fine.
> >
> > Ok guys, here is one of the major questions in this issue:
> >
> > How did you manage to convince the _host_ interface driver (in my setup "igb"
> > from intel) to get the vlan tagged packets from the LAN port. igb has a vlan
> > filter function built in and reads _no_ tagged packets at all if the driver
> > does not tell it to. And in case of "up-ing" the interface for attachment to a
> > bridge it does not configure this vlan filter.
> > How is this expected to work?
> >
> > --
> > Regards,
> > Stephan

Thanks Jeff,

so, since we are all here now :-) who can explain how one can tell either the
bridge or the attached network device to include certain VLAN IDs in its
HW filters so that these can be forwarded through the bridge?
>From the current infos it looks like a cheap network card with no HW filters
would just work (if I understood Stephen). But since most servers have either
intel cards or intel onboard chips (and they are brilliant in performance btw)
me and probably lots of others seem to need some solution that isn't currently
available. I would love to see something that really allows the card to still
use the filters and not switch it in complete promiscous mode so that every
packets floats in.
Any ideas?

-- 
Regards,
Stephan

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2013-08-26 10:21 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-22 20:44 Can linux kernel bridge forward 802.1q tagged vlan packets? Stephan von Krawczynski
2013-08-22 21:49 ` Marek Kierdelewicz
2013-08-22 22:19   ` Stephen Hemminger
2013-08-23  4:22     ` [Bridge] " Stephan von Krawczynski
2013-08-23  4:58       ` Jeff Kirsher
2013-08-26 10:21         ` Stephan von Krawczynski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).