netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Is 802.3ad mode in bonding useful ?
@ 2011-04-28  7:33 WeipingPan
  2011-04-28 12:21 ` Neil Horman
  0 siblings, 1 reply; 9+ messages in thread
From: WeipingPan @ 2011-04-28  7:33 UTC (permalink / raw)
  To: netdev

Hi, all,

802.3ad mode in bonding implements 802.3ad standard.

I am just wondering  802.3ad mode is useful,
since  bonding has many modes like balance-rr, active-backup, etc.

thanks
Weiping Pan

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

* Re: Is 802.3ad mode in bonding useful ?
  2011-04-28  7:33 Is 802.3ad mode in bonding useful ? WeipingPan
@ 2011-04-28 12:21 ` Neil Horman
       [not found]   ` <0FBC7C9C2640634A8B837C2EFFCFF32F0184732D72@SHEXMB-01.global.atheros.com>
  2011-04-29  3:17   ` WeipingPan
  0 siblings, 2 replies; 9+ messages in thread
From: Neil Horman @ 2011-04-28 12:21 UTC (permalink / raw)
  To: WeipingPan; +Cc: netdev

On Thu, Apr 28, 2011 at 03:33:50PM +0800, WeipingPan wrote:
> Hi, all,
> 
> 802.3ad mode in bonding implements 802.3ad standard.
> 
> I am just wondering  802.3ad mode is useful,
> since  bonding has many modes like balance-rr, active-backup, etc.
> 
Yes, of course its usefull.  For switches which support 802.3ad, this mode
allows for both peers to understand that the links in the bond are acting as an
aggregate, which makes it easier to prevent things like inadvertently looped
back frames, for which the other modes have to have all sorts of hacks to
prevent.
Neil

> thanks
> Weiping Pan
> --
> 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
> 

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

* Re: 答复: Is 802.3ad mode in bonding useful ?
       [not found]   ` <0FBC7C9C2640634A8B837C2EFFCFF32F0184732D72@SHEXMB-01.global.atheros.com>
@ 2011-04-28 13:23     ` Neil Horman
  0 siblings, 0 replies; 9+ messages in thread
From: Neil Horman @ 2011-04-28 13:23 UTC (permalink / raw)
  To: Xiong Huang; +Cc: WeipingPan, netdev@vger.kernel.org

On Thu, Apr 28, 2011 at 08:31:33PM +0800, Xiong Huang wrote:
> Is there any plan to support cisco FEC/GEC protocol in bonding ?
> 
Not explicitly, no, since roundrobin/xor modes should be compatible already,
and etherchannel can interoperate with 802.3ad bonds if the switches
etherchannel is configured to be in lacp mode:

Neil


> -Xiong
> ________________________________________
> 发件人: netdev-owner@vger.kernel.org [netdev-owner@vger.kernel.org] 代表 Neil Horman [nhorman@tuxdriver.com]
> 发送时间: 2011年4月28日 5:21
> 收件人: WeipingPan
> 抄送: netdev@vger.kernel.org
> 主题: Re: Is 802.3ad mode in bonding useful ?
> 
> On Thu, Apr 28, 2011 at 03:33:50PM +0800, WeipingPan wrote:
> > Hi, all,
> >
> > 802.3ad mode in bonding implements 802.3ad standard.
> >
> > I am just wondering  802.3ad mode is useful,
> > since  bonding has many modes like balance-rr, active-backup, etc.
> >
> Yes, of course its usefull.  For switches which support 802.3ad, this mode
> allows for both peers to understand that the links in the bond are acting as an
> aggregate, which makes it easier to prevent things like inadvertently looped
> back frames, for which the other modes have to have all sorts of hacks to
> prevent.
> Neil
> 
> > thanks
> > Weiping Pan
> > --
> > 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
> >
> --
> 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

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

* Re: Is 802.3ad mode in bonding useful ?
  2011-04-28 12:21 ` Neil Horman
       [not found]   ` <0FBC7C9C2640634A8B837C2EFFCFF32F0184732D72@SHEXMB-01.global.atheros.com>
@ 2011-04-29  3:17   ` WeipingPan
  2011-04-29 10:43     ` Neil Horman
  1 sibling, 1 reply; 9+ messages in thread
From: WeipingPan @ 2011-04-29  3:17 UTC (permalink / raw)
  To: Neil Horman; +Cc: netdev

On 04/28/2011 08:21 PM, Neil Horman wrote:
> On Thu, Apr 28, 2011 at 03:33:50PM +0800, WeipingPan wrote:
>> Hi, all,
>>
>> 802.3ad mode in bonding implements 802.3ad standard.
>>
>> I am just wondering  802.3ad mode is useful,
>> since  bonding has many modes like balance-rr, active-backup, etc.
>>
> Yes, of course its usefull.  For switches which support 802.3ad, this mode
> allows for both peers to understand that the links in the bond are acting as an
> aggregate, which makes it easier to prevent things like inadvertently looped
> back frames, for which the other modes have to have all sorts of hacks to
> prevent.
What is looped back frames here ?
I didn't see any special code to handle looped back frames in other 
modes in bonding,
can you take an example ?

thanks
Weiping Pan

> Neil
>


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

* Re: Is 802.3ad mode in bonding useful ?
  2011-04-29  3:17   ` WeipingPan
@ 2011-04-29 10:43     ` Neil Horman
  2011-04-29 13:59       ` WeipingPan
                         ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Neil Horman @ 2011-04-29 10:43 UTC (permalink / raw)
  To: WeipingPan; +Cc: netdev

On Fri, Apr 29, 2011 at 11:17:48AM +0800, WeipingPan wrote:
> On 04/28/2011 08:21 PM, Neil Horman wrote:
> >On Thu, Apr 28, 2011 at 03:33:50PM +0800, WeipingPan wrote:
> >>Hi, all,
> >>
> >>802.3ad mode in bonding implements 802.3ad standard.
> >>
> >>I am just wondering  802.3ad mode is useful,
> >>since  bonding has many modes like balance-rr, active-backup, etc.
> >>
> >Yes, of course its usefull.  For switches which support 802.3ad, this mode
> >allows for both peers to understand that the links in the bond are acting as an
> >aggregate, which makes it easier to prevent things like inadvertently looped
> >back frames, for which the other modes have to have all sorts of hacks to
> >prevent.
> What is looped back frames here ?
In this case they are frames that get received by the bond, which the bond
itself sent.  In modes where more than one slave is active, and in which the
switch has no additional knoweldge of the aggregate (e.g. round robin mode), the
bond can send a frame on one slave, which the switch may broadcast to all ports,
causing the frame just sent by the bond to then get received on another slave.

> I didn't see any special code to handle looped back frames in other
> modes in bonding,
> can you take an example ?
> 
See bond_handle_frame.

Neil

> thanks
> Weiping Pan
> 
> >Neil
> >
> 
> 

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

* Re: Is 802.3ad mode in bonding useful ?
  2011-04-29 10:43     ` Neil Horman
@ 2011-04-29 13:59       ` WeipingPan
  2011-04-29 14:04       ` John Lumby
  2011-04-29 17:01       ` Jay Vosburgh
  2 siblings, 0 replies; 9+ messages in thread
From: WeipingPan @ 2011-04-29 13:59 UTC (permalink / raw)
  To: Neil Horman; +Cc: netdev

On 04/29/2011 06:43 PM, Neil Horman wrote:
> On Fri, Apr 29, 2011 at 11:17:48AM +0800, WeipingPan wrote:
>> On 04/28/2011 08:21 PM, Neil Horman wrote:
>>> On Thu, Apr 28, 2011 at 03:33:50PM +0800, WeipingPan wrote:
>>>> Hi, all,
>>>>
>>>> 802.3ad mode in bonding implements 802.3ad standard.
>>>>
>>>> I am just wondering  802.3ad mode is useful,
>>>> since  bonding has many modes like balance-rr, active-backup, etc.
>>>>
>>> Yes, of course its usefull.  For switches which support 802.3ad, this mode
>>> allows for both peers to understand that the links in the bond are acting as an
>>> aggregate, which makes it easier to prevent things like inadvertently looped
>>> back frames, for which the other modes have to have all sorts of hacks to
>>> prevent.
>> What is looped back frames here ?
> In this case they are frames that get received by the bond, which the bond
> itself sent.  In modes where more than one slave is active, and in which the
> switch has no additional knoweldge of the aggregate (e.g. round robin mode), the
> bond can send a frame on one slave, which the switch may broadcast to all ports,
> causing the frame just sent by the bond to then get received on another slave.
>
>> I didn't see any special code to handle looped back frames in other
>> modes in bonding,
>> can you take an example ?
>>
> See bond_handle_frame.
>
> Neil
>
Oh, I got it.

Thanks for your clear explanation !
Weiping Pan


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

* Re: Is 802.3ad mode in bonding useful ?
  2011-04-29 10:43     ` Neil Horman
  2011-04-29 13:59       ` WeipingPan
@ 2011-04-29 14:04       ` John Lumby
  2011-04-29 15:21         ` Rick Jones
  2011-04-29 17:01       ` Jay Vosburgh
  2 siblings, 1 reply; 9+ messages in thread
From: John Lumby @ 2011-04-29 14:04 UTC (permalink / raw)
  To: Neil Horman; +Cc: WeipingPan, netdev

On 04/29/11 06:43, Neil Horman wrote:
> On Fri, Apr 29, 2011 at 11:17:48AM +0800, WeipingPan wrote:
>> On 04/28/2011 08:21 PM, Neil Horman wrote:
>>> On Thu, Apr 28, 2011 at 03:33:50PM +0800, WeipingPan wrote:
>>>> Hi, all,
>>>>
>>>> 802.3ad mode in bonding implements 802.3ad standard.
>>>>
>>>> I am just wondering  802.3ad mode is useful,
>>>> since  bonding has many modes like balance-rr, active-backup, etc.
>>>>
>>> Yes, of course its usefull.  For switches which support 802.3ad, this mode
>>> allows for both peers to understand that the links in the bond are acting as an
>>> aggregate, which makes it easier to prevent things like inadvertently looped
>>> back frames, for which the other modes have to have all sorts of hacks to
>>> prevent.


I believe another use for 802.3ad is to monitor the aggregation 
"actively"  (by sending special LACP packets) and to detect any kind of 
failure of the other end of one of the slaves more rapidly (than if 
relying on something like carrier detect).     This may improve 
availability,  although that depends on the specific network topology 
and capabilities in the switch(es).    There is information on this in 
Documentation/networking/bonding.txt.


>> What is looped back frames here ?
> In this case they are frames that get received by the bond, which the bond
> itself sent.  In modes where more than one slave is active, and in which the
> switch has no additional knoweldge of the aggregate (e.g. round robin mode), the
> bond can send a frame on one slave, which the switch may broadcast to all ports,


Isn't this (broadcasting or repeating on all ports other than incoming) 
more associated with simple hubs rather than switches?     I would think 
any switch with layer 2 capability does not do that (does it?)

> causing the frame just sent by the bond to then get received on another slave.
>
>


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

* Re: Is 802.3ad mode in bonding useful ?
  2011-04-29 14:04       ` John Lumby
@ 2011-04-29 15:21         ` Rick Jones
  0 siblings, 0 replies; 9+ messages in thread
From: Rick Jones @ 2011-04-29 15:21 UTC (permalink / raw)
  To: John Lumby; +Cc: Neil Horman, WeipingPan, netdev

> >> What is looped back frames here ?
> > In this case they are frames that get received by the bond, which the bond
> > itself sent.  In modes where more than one slave is active, and in which the
> > switch has no additional knoweldge of the aggregate (e.g. round robin mode), the
> > bond can send a frame on one slave, which the switch may broadcast to all ports,
> 
> 
> Isn't this (broadcasting or repeating on all ports other than incoming) 
> more associated with simple hubs rather than switches?     I would think 
> any switch with layer 2 capability does not do that (does it?)

Perhaps when a frame is sent via the bond to a destination MAC not yet
learned by the switch?  

Until a switch sees a MAC as a src, it does not know to which port the
frame(s) should be forwarded, so it must send the frame out all ports
but the ingress port.

rick jones


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

* Re: Is 802.3ad mode in bonding useful ?
  2011-04-29 10:43     ` Neil Horman
  2011-04-29 13:59       ` WeipingPan
  2011-04-29 14:04       ` John Lumby
@ 2011-04-29 17:01       ` Jay Vosburgh
  2 siblings, 0 replies; 9+ messages in thread
From: Jay Vosburgh @ 2011-04-29 17:01 UTC (permalink / raw)
  To: Neil Horman; +Cc: WeipingPan, netdev

Neil Horman <nhorman@tuxdriver.com> wrote:

>On Fri, Apr 29, 2011 at 11:17:48AM +0800, WeipingPan wrote:
>> On 04/28/2011 08:21 PM, Neil Horman wrote:
>> >On Thu, Apr 28, 2011 at 03:33:50PM +0800, WeipingPan wrote:
>> >>Hi, all,
>> >>
>> >>802.3ad mode in bonding implements 802.3ad standard.
>> >>
>> >>I am just wondering  802.3ad mode is useful,
>> >>since  bonding has many modes like balance-rr, active-backup, etc.
>> >>
>> >Yes, of course its usefull.  For switches which support 802.3ad, this mode
>> >allows for both peers to understand that the links in the bond are acting as an
>> >aggregate, which makes it easier to prevent things like inadvertently looped
>> >back frames, for which the other modes have to have all sorts of hacks to
>> >prevent.
>> What is looped back frames here ?
>In this case they are frames that get received by the bond, which the bond
>itself sent.  In modes where more than one slave is active, and in which the
>switch has no additional knoweldge of the aggregate (e.g. round robin mode), the
>bond can send a frame on one slave, which the switch may broadcast to all ports,
>causing the frame just sent by the bond to then get received on another slave.

	Actually, the round-robin (balance-rr) and balance-xor modes
were originally meant to interoperate with a switch configured for
traditional Etherchannel (old versions of Sun Trunking, etc) the common
term in use now seems to be "static link aggregation" to distinguish it
from 802.3ad dynamic link aggregation.  When the switch is set up that
way, there are no loopback problems, because the switch knows that all
of the ports are really one big aggregate, and it won't send broadcast
or multicast packets to more than one port of the aggregation, and knows
that a bcast/mcast originating from one of those ports should not loop
back to another port of the aggregation.

	What Neil is talking about is running -rr or -xor against,
basically, a hub or unmanaged switch, in which the switch (a) doesn't
have any link aggregation capabilities, and (b) won't complain when it
sees the same MAC address coming in from multiple ports more or less
simultaneously.  Managed switches (that have link aggregation
capabilities) will generally complain about "flapping" if they see the
same source MAC address arrive on multiple switch ports in a short
period of time.

	The special hacks now in bond_handle_frame aren't really about
preventing loopbacks, but rather to suppress duplicates, particularly
for the short periods of time that a switch is flooding traffic to all
ports because its mac table is not up to date.  This is an issue in,
e.g., active-backup mode, in which the switch has no special
configuration.  This code has moved around a lot lately, so older
kernels will have a substantially different layout, although the logic
is still pretty much the same.

	I don't recall that there's anything specifically to suppress
loopbacks for -rr or -xor mode, although there is transmit logic to keep
things like IGMP messages on the same slave all the time to keep the
switches happier.

>> I didn't see any special code to handle looped back frames in other
>> modes in bonding,
>> can you take an example ?
>> 
>See bond_handle_frame.

	The actual testing logic is in bond_should_deliver_exact_match.

	-J

---
	-Jay Vosburgh, IBM Linux Technology Center, fubar@us.ibm.com

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

end of thread, other threads:[~2011-04-29 17:01 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-28  7:33 Is 802.3ad mode in bonding useful ? WeipingPan
2011-04-28 12:21 ` Neil Horman
     [not found]   ` <0FBC7C9C2640634A8B837C2EFFCFF32F0184732D72@SHEXMB-01.global.atheros.com>
2011-04-28 13:23     ` 答复: " Neil Horman
2011-04-29  3:17   ` WeipingPan
2011-04-29 10:43     ` Neil Horman
2011-04-29 13:59       ` WeipingPan
2011-04-29 14:04       ` John Lumby
2011-04-29 15:21         ` Rick Jones
2011-04-29 17:01       ` Jay Vosburgh

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).