TCP: Difference between revisions

No edit summary
No edit summary
 
Line 6: Line 6:
== Portable APIs ==
== Portable APIs ==
* TCP_NODELAY: Disable [[Nagle's algorithm]] (coalescing of small packets until an ACK is received or a retransmission triggered). See the [[Linux APIs#IPPROTO_TCP|Linux APIs]] page for interactions with TCP_CORK on that platform.
* TCP_NODELAY: Disable [[Nagle's algorithm]] (coalescing of small packets until an ACK is received or a retransmission triggered). See the [[Linux APIs#IPPROTO_TCP|Linux APIs]] page for interactions with TCP_CORK on that platform.
 
==Offloading/Coalescing==
LRO/TSO are safe to use on routers and bridges so long as all interfaces involved support the technique.
===LRO===
Large receive offload. Cannot guarantee refragmentation, and thus ought not generally be used on bridges or routers.
===GRO===
Generic receive offload. Generalizes LRO to guarantee possibility of refragmentation, but coalesces a proper subset of packets suitable for LRO.
===TSO===
TCP segmentation offload, also known as TCP Large Send.
===GSO===
Generic segmentation offload, introduced in Linux 2.6.18. Generalizes TSO to guarantee possibility of refragmentation.
==Tuning==
==Tuning==
===TCP auto-tuning on Linux===
===TCP auto-tuning on Linux===
Line 18: Line 27:
* [[FreeBSD APIs#IPPROTO_TCP|FreeBSD's]] TCP socket options
* [[FreeBSD APIs#IPPROTO_TCP|FreeBSD's]] TCP socket options
* [http://linuxgazette.net/135/pfeiffer.html TCP and Linux' Pluggable Congestion Control Algorithms], a 2007 Linux Gazette article by René Pfeiffer
* [http://linuxgazette.net/135/pfeiffer.html TCP and Linux' Pluggable Congestion Control Algorithms], a 2007 Linux Gazette article by René Pfeiffer
* [http://thread.gmane.org/gmane.linux.network/114003 'net: Generic Receive Offload], Herbert Xu 2008-12-12 linux-net post
* [http://www.linuxfoundation.org/collaborate/workgroups/networking/gso GSO], The Linux Foundation
* [http://kerneltrap.org/node/397 Linux: TCP Segmentation Offload], KernelTrap 2002-09-03
[[CATEGORY: Networking]]
[[CATEGORY: Networking]]