Maximum segment size: Difference between revisions
m r2.6.4) (robot Adding: ru:MSS |
Changed bytes to octets, as the RFCs talk about octets and Added IPv6 info. |
||
Line 1: | Line 1: | ||
The '''maximum segment size''' ('''MSS''') is a parameter of the [[Transmission Control Protocol|TCP protocol]] that specifies the largest amount of data, specified in [[ |
The '''maximum segment size''' ('''MSS''') is a parameter of the [[Transmission Control Protocol|TCP protocol]] that specifies the largest amount of data, specified in [[Octet_(computing)|octets]], that a computer or communications device can receive in a single TCP segment, and therefore in a single IP datagram. It does not count the TCP header or the [[Internet Protocol|IP]] header.<ref>[http://tools.ietf.org/html/rfc879#section-3 RFC 879], page 2, Section 3, "The MSS counts only data octets in the segment, it does not count the TCP header or the IP header."</ref> The IP datagram containing a TCP segment may be self-contained within a single packet, or it may be reconstructed from several [[IP fragmentation|fragmented]] pieces; either way, the MSS limit applies to the total amount of data contained within the final reconstructed TCP segment. |
||
Therefore: |
Therefore: Headers + MSS ≤ [[Maximum transmission unit|MTU]] |
||
The Minimum MSS = Maximum datagram size - IP header size - TCP header size<br /> |
|||
So every IPv4 host is required to be able to handle an MSS of at least 536 octets (= 576 - 20 - 20)<br /> |
|||
and every IPv6 host is required to be able to handle an MSS of at least 1220 octets (= 1280 - 40 - 20).<ref>[http://tools.ietf.org/html/rfc2460#section-8.3 RFC 2460], page 28, Section 8.3</ref> |
|||
For most computer users, the MSS option is established by [[operating system]] on the [[SYN (TCP)|SYN]] packet during the [[TCP handshake]]. Each direction of data flow can use a different MSS. |
For most computer users, the MSS option is established by [[operating system]] on the [[SYN (TCP)|SYN]] packet during the [[TCP handshake]]. Each direction of data flow can use a different MSS. |
Revision as of 08:48, 8 September 2011
The maximum segment size (MSS) is a parameter of the TCP protocol that specifies the largest amount of data, specified in octets, that a computer or communications device can receive in a single TCP segment, and therefore in a single IP datagram. It does not count the TCP header or the IP header.[1] The IP datagram containing a TCP segment may be self-contained within a single packet, or it may be reconstructed from several fragmented pieces; either way, the MSS limit applies to the total amount of data contained within the final reconstructed TCP segment.
Therefore: Headers + MSS ≤ MTU
The Minimum MSS = Maximum datagram size - IP header size - TCP header size
So every IPv4 host is required to be able to handle an MSS of at least 536 octets (= 576 - 20 - 20)
and every IPv6 host is required to be able to handle an MSS of at least 1220 octets (= 1280 - 40 - 20).[2]
For most computer users, the MSS option is established by operating system on the SYN packet during the TCP handshake. Each direction of data flow can use a different MSS.
Further reading
- Comer, Douglas E. (2006). Internetworking with TCP/IP (5E ed.). Upper Saddle River, NJ, USA: Prentice Hall.
- Kozierok, Charles M. (2005-09-20). The TCP/IP Guide (3E ed.). Retrieved 2007-11-28.