I am looking at the sample Wireshark capture from http-google101.pcapng ( available from http://wiresharkbook.com/wireshark101.html )
From frame 11 to frame 25, it appears to be a transfer of data from the server to client via TCP. There is an ACK for every few TCP segments. Is there a rule stating that the receiver must send an ACK after receiving a maximum of xxx TCP segments ? I did some research and got confused.. Window size, Selective Repeat protocol etc appeared in my searches =/ asked 17 Jun '14, 08:29 Dinged edited 17 Jun '14, 08:32 |
2 Answers:
Since the question is on what the written rule is, and specifically what the written rule is for the receiver, the answer is yes there is a written rule (ACK after two segments), but it is a "SHOULD" rule and it wasn't clearly defined even at that level until after the original RFC. RFC 2581 section 4.2 has it. It's kind of funny because they're adding ambiguity between implementations through their 'unambiguous' statement. They are clear about how unclear we can be:
The original TCP RFC 793 says they should be ACKed “without undue delay” and suggests piggybacking if possible (page 73). Any RFC 2581-compliant TCP stack is mandated to ACK inside of 500 ms though. Also, as a general comment it is almost always best to go to the RFC or white paper if you have a question on a firm rule for a protocol. Especially in multi-vendor scenarios it’s a universal language between them, and suppliers/vendors will usually agree to be bound by them in a negotiation as well. answered 18 Jun ‘14, 20:43 Quadratic edited 18 Jun ‘14, 20:45 |
Disclaimer: I'll try to keep the answer simple - that's why I dont mentioned the cases where my rule of thumb is not applicable... So yes and no -> there is just one rule stating that after a maximum of data send (which is the value defined through window size) the sender has to wait for an ACK before sending more data. Usually when looking at windows systems, you'll see that there is one ACK after two TCP segments in most cases. With *nix systems its heavily dependend on the exact system, but in most cases you will also be able to see a "pattern" within an ongoing data transfer. So every stack has its own behaviour about when and how to ACK incoming data, but all have in common that they try to ACK regularly and early so that the transmission keeps flowing. answered 18 Jun '14, 11:22 Landi |