The following is a short overview of TCP buffers. A complete explanation
is available in the PSC TCP Tuning Guide.
The following TCP Buffer settings are important:
Maximum TCP Buffer (Memory) space: All OSes have some global mechanism to limit the amount of
system memory that can be used by any one TCP connection.
Unfortunately most systems (except MS Windows Vista and Linux 2.6.17 and higher) are shipped with
Maximum Buffer Space limits that are far too small for any host connected at 100 Mbps or higher.
Increasing the Maximum TCP buffer size requires 'superuser' privileges.
Socket Buffer Sizes: Most operating systems also support separate per connection send and receive buffer
limits that can be adjusted by the user, application or other mechanism as long as they stay within
the maximum memory limits above. These buffer sizes correspond to the SO_SNDBUF and SO_RCVBUF options of
the BSD setsockopt() call.
The socket buffers must be large enough to hold a full BDP (bandwidth delay product) of data for a given end-to-end path.
Fortunately Linux 2.6, Windows Vista, OSX 10.5 (Leopard), and FreeBSD 7.0
all provide 'TCP Autotuning' to automatically adjust
socket buffer sizes as needed to optimally balance TCP performance and memory usage.
We expect other OSes will follow.
For other operating systems is it necessary to either change the default
buffer size, as described at http://dsd.lbl.gov/TCP-tuning/.
Otherwise it is necessary to use an application, such as those described on the
file transfer tools page,
where the programmer provided a
way to set the TCP send and/or receive buffer size. This approach forces the user to manually compute the BDP
for the path and supply the proper command or option to the application.