Buffer Bloat, a minis to the TCP protocol

Today I would like to take a minute of your time and talk about Bandwidth usage and a little known  phenomenon called Buffer Bloat.

 

What is Buffer bloat and what does it effect?

 

Buffer bloat is the product whereby excess buffering of packets inside the network causes high latency and jitter, as well as reducing the overall network throughput. Buffer bloat occurs when a network link becomes congested, causing packets to become queued in the buffer of a router or switch. As traffic passes from one router to another this buffering can become amplified. Amplification of Buffer bloat happens as each router segment buffers the netflows, the more router segments between the endpoints the larger the bloat can grow. The problem is caused mainly by router and switch manufacturers making incorrect assumptions and buffering packets for too long in cases where they should be dropped. Dropping packets is not always a bad thing. TCP is built so that when packets are dropped the protocol slows the transmission down. Transmission speeds up and slows down until it finds an equilibrium equal to the speed of the link. However, for this to work the packet drops must occur in a timely manner and buffering packets negates this process.

 

In a network buffer (router memory), packets are queued before being transmitted and in the problematic situation packets are only dropped if the buffer is full. With the advent of cheap RAM router manufactures have been adding more and more RAM to their systems allowing for larger and larger buffers. On older routers, buffers were fairly small so they filled quickly and therefore packets began to drop shortly after the link became saturated, the TCP protocol could adjust, and the issue wouldn’t become apparent. On newer routers buffers have become large enough to hold several megabytes of data, which translates to 10 seconds or more at a 1 Mbit/s line rate.

 

The problem is not limited to just TCP, these problems also affects other protocols. All packets passing through a simple buffer implemented as a single queue will experience the same delay, so the latency of any connection that passes through a filled buffer will be affected, this includes protocols like ICMP and UDP.  If you have read this please send me a email back, I would like to see how many of us out there read this far.

 

Want to learn more about Buffer bloat and how it effect endpoints and company networks? Please visit this article on Buffer bloat at http://gettys.wordpress.com/2010/12/03/introducing-the-criminal-mastermind-bufferbloat/

 

 

Howto : Remove Windows Server 2008 / Windows 7 multiple default gateways with the first being 0.0.0.0

Windows has 2 default gateways set and the first is 0.0.0.0 which is causing network failures

You may have installed a new Windows 2008 server or Windows 7 workstation with a static IP address but networing outside your localnet fails. After you investigate you find by running “ipconfig” that there is 2 default routes listed. You see first 0.0.0.0 and then you see your real default router IP address below the 0.0.0.0 address.

This is preventing you from accessing the Internet as it believes the first route to the internet is your local IP address and it goes nowhere. You need to get the first route out but if you use “route delete” on the next reboot it will right back and you will be left without Internet access so what do you do?

You need to edit the registery and remove the entry listed in the default route key. To do this go to:

HKLM\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters\Interfaces\your interface #\DefaultGateway

You will most likely find if you edit this key 2 IP addresses listed and the one you want being listed as the second IP in the list. Just remove all IP addresses but the real gateway address.

Close and reboot then try to ping out and it should now work.

Enjoy.

Cubert