Re: PAUSE support for Ethernet interfaces ?

2008-03-03 Thread Zaphod Beeblebrox
On Mon, Mar 3, 2008 at 12:18 PM, Bruce M. Simpson <[EMAIL PROTECTED]> wrote:


> There are switch ASICs out there which implement upstream bandwidth
> limiting on ports by sending the PAUSE frame.
>
> I believe thompsa@ recently committed a fix to if_bridge to allow it to
> ignore PAUSE frames for the purposes of forwarding (they should never be
> forwarded, they are link scope only).
>
> It would be interesting to see a patch which implemented rate limiting
> in the same way as these ASICs do, but in if_bridge.


Being able to react to pause frames could give us the ability to react to
different speed ethernet-like devices like DSL modems and cable modems.
Right now, we can blast away at whatever the link speed is and only the TCP
semantics are keeping this under control.  One can use rate limiting a-la pf
and/or dummynet, but this has a very bad failure mode --- when the speed of
the link changes you end up choking the packets twice (once with the rate
limiting, once with the physical device) and for large numbers of tcp
streams (100's of users, say... or 10 bittorrent users) you can easily get
really bad failure modes when the available bandwidth changes.  I have
several links for which the bandwidth changes when the weather is very wet,
for instance.
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: PAUSE support for Ethernet interfaces ?

2008-03-03 Thread Bruce M. Simpson

Tom Samplonius wrote:

  FreeBSD does not send PAUSE frames, but most of the NICs out there will 
process received PAUSE frames.

  However ethernet flow control is mainly useful on the switches anyways.  
Switches these day (*) have small buffers (sometimes just a shared 3MB buffer 
for 24 ports).  If several ports send too much to a single port at the same 
time, the switch could run out of buffer space in milliseconds and start 
dropping frames, so the switch will use flow control to get the transmitting 
ports to slow down, and let the buffer drain.  Slowing down the senders with 
ethernet flow control results in better performance than letting some frames 
drop, and force a timeout and retransmit.  Of course, deeper buffers would be 
even better.

  


There are switch ASICs out there which implement upstream bandwidth 
limiting on ports by sending the PAUSE frame.


I believe thompsa@ recently committed a fix to if_bridge to allow it to 
ignore PAUSE frames for the purposes of forwarding (they should never be 
forwarded, they are link scope only).


It would be interesting to see a patch which implemented rate limiting 
in the same way as these ASICs do, but in if_bridge.


cheers
BMS
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: PAUSE support for Ethernet interfaces ?

2008-03-03 Thread Tom Samplonius
- "Kurt Jaeger" <[EMAIL PROTECTED]> wrote:
> Hi!
> 
> I'm researching the topic of PAUSE counters (receiving side) for
> FreeBSD systems.
> 
> That's a sort of flow control with ethernet, see e.g.:
> 
> http://www.techfest.com/networking/lan/ethernet3.htm#3.2.1
> 
> Cisco switches seem to receive and count them, which helps
> to find short-term (seconds) overloaded links.
> Can FreeBSD 6.x or 7.x handle PAUSE frames, at least receiving them ?


  FreeBSD does not send PAUSE frames, but most of the NICs out there will 
process received PAUSE frames.

  However ethernet flow control is mainly useful on the switches anyways.  
Switches these day (*) have small buffers (sometimes just a shared 3MB buffer 
for 24 ports).  If several ports send too much to a single port at the same 
time, the switch could run out of buffer space in milliseconds and start 
dropping frames, so the switch will use flow control to get the transmitting 
ports to slow down, and let the buffer drain.  Slowing down the senders with 
ethernet flow control results in better performance than letting some frames 
drop, and force a timeout and retransmit.  Of course, deeper buffers would be 
even better.

  Servers have large buffers, and mostly use TCP, which also implements flow 
control.  So not much of a problem usually.

  I don't know if you could tell much by counting PAUSE frames though.  You 
won't know the destination port that was congested, just the port(s) that were 
generating the traffic, that the switch told to slow down.


Tom

(*) I remember when some 10/100 switches had 1MB of buffer space per port.  
They don't make them anymore.
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: PAUSE support for Ethernet interfaces ?

2008-03-02 Thread Pyun YongHyeon
On Fri, Feb 29, 2008 at 11:41:07AM +0100, Kurt Jaeger wrote:
 > Hi!
 > 
 > I'm researching the topic of PAUSE counters (receiving side) for
 > FreeBSD systems.
 > 
 > That's a sort of flow control with ethernet, see e.g.:
 > 
 > http://www.techfest.com/networking/lan/ethernet3.htm#3.2.1
 > 
 > Cisco switches seem to receive and count them, which helps
 > to find short-term (seconds) overloaded links.

FreeBSD has no such framework in mii layer yet so it's completely
up to driver. em(4) handles flow-control in driver so it can handle
flow-control.

 > Can FreeBSD 6.x or 7.x handle PAUSE frames, at least receiving them ?
 > 

Receiving pause frames have no problem on any driver but most
drivers does not respond with the pause frames. AFAIK marius@ has
a flow-control patch so I guess FreeBSD will have generic
flow-control capability which will make it available on all ethernet
drivers with minor modification.

 > Thanks for any pointer!
 > 

-- 
Regards,
Pyun YongHyeon
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


PAUSE support for Ethernet interfaces ?

2008-02-29 Thread Kurt Jaeger
Hi!

I'm researching the topic of PAUSE counters (receiving side) for
FreeBSD systems.

That's a sort of flow control with ethernet, see e.g.:

http://www.techfest.com/networking/lan/ethernet3.htm#3.2.1

Cisco switches seem to receive and count them, which helps
to find short-term (seconds) overloaded links.
Can FreeBSD 6.x or 7.x handle PAUSE frames, at least receiving them ?

Thanks for any pointer!

-- 
[EMAIL PROTECTED]+49 171 310137212 years to 
go !
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"