tcp

16
1 TCP • Transport Control Protocol • Reliable In-order delivery • Flow control • Responds to congestion • “Nice” Protocol

Upload: lane-levy

Post on 31-Dec-2015

14 views

Category:

Documents


0 download

DESCRIPTION

TCP. Transport Control Protocol Reliable In-order delivery Flow control Responds to congestion “Nice” Protocol. TCP Header. TCP flow control. Window based Sender cannot send more data than a window without acknowledgements. - PowerPoint PPT Presentation

TRANSCRIPT

1

TCP

• Transport Control Protocol

• Reliable In-order delivery

• Flow control

• Responds to congestion

• “Nice” Protocol

2

TCP Header

3

TCP flow control

• Window based

• Sender cannot send more data than a window without acknowledgements.

• Window is a minimum of receiver’s buffer and ‘congestion window’.

• After a window of data is transmitted, in steady state, acks control sending rate.

4

Flow control

5

Flow control

• Congestion window is increased gradually

• At the beginning, set cwnd = 1

• For each ack, double the cwnd until a threshold

• Increase by 1 for a window of acks after that.

6

Slow Start

7

Additive Increase

8

Reliable delivery

• Sender, Receiver keep track of bytes sent and bytes received.

• Acks have an indication of next byte expected.

• Three duplicate acks considered a packet loss - sender retransmits

9

Reliable Delivery

10

Congestion Control

• Traffic on the network is constantly changing.

• Packets may be lost due to transmission errors, switch buffer overflows, receiver buffer overflows.

• Packet loss is taken as an indication of congestion.

11

Congestion Response

• TCP reduces sending rate on packet loss

• cwnd is halved on a packet loss

• cwnd is set to 1 on a timeout

• TCP follows -- Multiplicative Decrease and Additive Increase policy for window adjustments

12

Congestion Response

• Queue length reduction takes qudratic time

• Multiplicative decrease allows sufficient time to reduce queue lengths -- Jacobson

• Jain -- Multiplicative decrease and additive increase allows ‘fair’ sharing of bandwidth.

• TCP -- ‘good’ citizen - allows fair sharing, avoids congestion collapse.

13

Congestion Response

14

TCP Congestion Response

• TCP responds to congestion.

• Increases window size until a packet loss

• This allows maximization of utilization.

• No Congestion avoidance mechanism

• Number of Proposals - TCP Vegas -- includes a rate adjustment mechanism based on observed delay.

15

DECbit

• Indicate congestion by setting a bit in the packet.

• Receiver echoes the bit to the sender.

• Sender adjusts sending rate based on percentage of marked packets.

• Avoids congestion before it happens

• Reduces the stair-case affect of TCP.

16

TCP and multimedia

• Reliable delivery not needed for multimedia

• Timely delivery more important than in-order delivery.

• Late packet can be thrown away

• TCP’s reliability gets in the way.