[p2p-hackers] UDP file transfer link speed identification

David Barrett dbarrett at quinthar.com
Fri Jul 22 20:51:24 UTC 2005


Daniel Stutzbach wrote:
> On Thu, Jul 21, 2005 at 04:19:30PM -0700, David Barrett wrote:
> 
>>Assuming TCP is a very simplified finite state machine (FSM) that starts 
>>in "slow start" state and transitions to "congestion avoidance" state 
>>when a packet loss is detected, does it likewise transition from 
>>"congestion avoidance" to "hold steady" once a second packet loss is 
>>detected?  If so, under what circumstances does it transition from "hold 
>>steady" back to "collision avoidance" or "slow start"?  Furthermore, 
>>does the cwnd get adjusted at all in "hold steady"?
> 
> There is no "hold steady" mode.  
> 
> If a loss is detected by timeout, cwnd is set to 1, ssthresh is cut in
> half, and it goes back to Slow Start.
> 
> If a loss is detected via 3 duplicate ACKs, cwnd and ssthresh are both
> cut in half, then it goes into Fast Retransmit mode to recover the
> loss.  Once the loss is recovered, it returns to congestion avoidance
> mode.
> 
> Basically, in congestion avoidance mode you still oscillate, but you
> oscillate slower and closer to the goal.
> 
> Also, this oscillation is from the sender's perspective.  Ideally,
> the receiver sees a steady stream of packets.  When the sender is
> sending too fast, their building up in a router's queue, until the
> router drops one.  The sender cuts it window in half, but there's
> still a bunch of packets in the queue.  The (ideal) net effect is a
> steady stream of packets arriving at the receiver.

Ah, thanks for that overview.  That makes perfect sense.

-david



More information about the P2p-hackers mailing list