Reliable Transport Services ``Lab''
Tom Kelliher, CS 325
Mar. 12, 2008
Assignment due NOW.
Read 3.5-3.6.
Intro to transport-layer protocols; UDP.
- Class design of a reliable transport protocol.
TCP; congestion control principles.
- of class is source host; of
class is destination host; I'm the link.
We'll just do one-way communication; two-way communication is analogous.
We'll do this quietly -- passing sheets of paper back and forth so neither
side has global information.
- Streams will be sentences containing a few words. Segments will be a
single word.
- In all cases, we'll assume the link doesn't reorder messages (How key
is that assumption?), but will degrade the link in other ways as we go
along:
- Perfect link.
- Garbles segments. (First data, then ACK).
- Drops segments.
- We'll start with a stop & wait protocol. Then look at how wasteful
that is and move on to two pipelined protocols:
- Go Back N.
- Selective repeat.
Stop & Wait:
- Perfect link -- no check info needed.
- Link garbles data segments -- checksum, ACK/NACK needed.
- Link garbles ACK/NACK -- resend segment; one bit sequence number
needed.
(An ACK for the ACK? No -- resend segment.)
Drop NACK.
- Link drops segments -- timer needed to timeout and resend segment.
Stop & wait kills performance: consider a 1 Gbps link between the coasts
with a RTT of 30 ms (speed of light) and a segment size of 1 KB. Link
utilization is (transmit time)/(transmit time + RTT):
where transmit time is
, or 8 microseconds.
Pipelined protocol semantics:
- Source can only have as many segments in flight as it has segments in
the window.
- Source slides window past received ACKs.
- Destination slides window past sent ACKs.
- Destination only accepts segments in order. (Simplification.)
Go Back N:
- Sequence number space size vs. window size -- Use two bit sequence
numbers and a three segment window. Drop the first ACK.
Selective repeat.
Discussion question: What are the limitations on window size?
(At most half sequence number space size, buffer space at hosts, congestion
control, total buffer space should be less than bandwidth delay product,
etc.)
What about out of order delivery? Can it even happen? (Yes -- multiple
routes between hosts.)
Thomas P. Kelliher
2008-03-12
Tom Kelliher