TCP sequences bytes. A lot of people assume that TCP sequences packets or 
segments, but that's not true.

The sequence number in a TCP header is the sequence number of the first 
byte in the payload. It's not a segment number. The ACK is the number of 
the next byte of payload expected. It's not a segment number. The sliding 
window keeps track of how many bytes have been sent and acknowledged.

The 3-way handshake kind of breaks this rule, which is probably why people 
get confused. They never go past the 3-way handshake. With the 3-way 
handshake, there are no payload bytes. The recipient's ACK number is 
nonetheless one more than the other side's SEQ number.

Follow the sequence number and ACKs in the following trace, after you get 
past the 3-way handshake in packets 1-3:

1       MyPC    Server  TCP HTTP        S=   2821020, L=    0, A=         0
2       Server  MyPC    TCP HTTP        S=2134278484, L=    0, A=   2821021
3       MyPC    Server  TCP HTTP        S=   2821021, L=    0, A=2134278485
4       MyPC    Server  TCP HTTP        S=   2821021, L=  384, A=2134278485
5       Server  MyPC    TCP HTTP        S=2134278485, L=    0, A=   2821405
6       Server  MyPC    TCP HTTP        S=2134278485, L=  156, A=   2821405
7       MyPC    Server  TCP HTTP        S=   2821405, L=    0, A=2134278641
8       MyPC    Server  TCP HTTP        S=   2821405, L=  304, A=2134278641
9       Server  MyPC    TCP HTTP        S=2134278641, L=    0, A=   2821709
10      Server  MyPC    TCP HTTP        S=2134278641, L=  156, A=   2821709
11      MyPC    Server  TCP HTTP        S=   2821709, L=    0, A=2134278797

Priscilla


At 02:10 PM 6/2/01, Chuck Larrieu wrote:
>I am reading Doug Comer's excellent book Internetworking with TCP/IP vol 1.
>Highly recommended, and I wish I had followed the good advice of several
>other people on this list, and read the book a year ago.
>
>I have a question on sliding windows as Comer describes it: "The TCP sliding
>window mechanism operates at the octet level, not at the segment or packet
>level"  Comer goes on to describe the operation of the mechanism, and
>indicates that acknowledgements occur octet for octet.
>
>This strikes me as highly inefficient, and something that would render TCP
>unusable in networks of any size. Because acknowledgements are based on
>sequence numbers, there would have to be a TCP header for every octet. Not
>good at all.
>
>I am no doubt missing something fundamental here. Perhaps TCP stack
>implementations are written in such a way that the "octets" being sent and
>acknowledge via the sliding window mechanism are really segments / packets?
>I.e. hundreds of octets at a time?
>
>Can someone enlighten me?
>
>Chuck
>
>One IOS to forward them all.
>One IOS to find them.
>One IOS to summarize them all
>And in the routing table bind them.
>
>-JRR Chambers-
________________________

Priscilla Oppenheimer
http://www.priscilla.com




Message Posted at:
http://www.groupstudy.com/form/read.php?f=7&i=6904&t=6899
--------------------------------------------------
FAQ, list archives, and subscription info: http://www.groupstudy.com/list/cisco.html
Report misconduct and Nondisclosure violations to [EMAIL PROTECTED]

Reply via email to