Chapter 3 Transport Layer

Similar documents
Chapter 3 outline. 3.5 Connection-oriented transport: TCP. 3.6 Principles of congestion control 3.7 TCP congestion control

Chapter 3 Transport Layer

Chapter III: Transport Layer

Chapter 3 Transport Layer

CMPE 150/L : Introduction to Computer Networks. Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 10

CSC 4900 Computer Networks: TCP

Computer Networking Introduction

Chapter 3 Transport Layer

Mid Term Exam Results

CSCI Topics: Internet Programming Fall 2008

TCP reliable data transfer. Chapter 3 outline. TCP sender events: TCP sender (simplified) TCP: retransmission scenarios. TCP: retransmission scenarios

CNT 6885 Network Review on Transport Layer

CSC 8560 Computer Networks: TCP

Chapter 3 outline. 3.5 Connection-oriented transport: TCP. 3.6 Principles of congestion control 3.7 TCP congestion control

Lecture 15: Transport Layer Congestion Control

Lecture 11. Transport Layer (cont d) Transport Layer 1

CC451 Computer Networks

Principles of congestion control

Chapter 3- parte B outline

Lecture 8. TCP/IP Transport Layer (2)

TCP: Overview RFCs: 793,1122,1323, 2018, 2581

Chapter III: Transport Layer

CSCI Topics: Internet Programming Fall 2008

Chapter 3 Transport Layer

Chapter 3 outline. 3.5 Connection-oriented transport: TCP. 3.6 Principles of congestion control 3.7 TCP congestion control

Outline. TCP: Overview RFCs: 793, 1122, 1323, 2018, Development of reliable protocol Sliding window protocols

Application. Transport. Network. Link. Physical

Detecting half-open connections. Observed TCP problems

CS 43: Computer Networks. 19: TCP Flow and Congestion Control October 31, Nov 2, 2018

TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581

Go-Back-N. Pipelining: increased utilization. Pipelined protocols. GBN: sender extended FSM

CS321: Computer Networks Congestion Control in TCP

LECTURE 3 - TRANSPORT LAYER

CSC 401 Data and Computer Communications Networks

Congestion Control. Principles of Congestion Control. Network-assisted Congestion Control: ATM. Congestion Control. Computer Networks 10/21/2009

The Transport Layer Congestion control in TCP

Congestion Control. Daniel Zappala. CS 460 Computer Networking Brigham Young University

Outline. TCP: Overview RFCs: 793, 1122, 1323, 2018, steam: r Development of reliable protocol r Sliding window protocols

Correcting mistakes. TCP: Overview RFCs: 793, 1122, 1323, 2018, TCP seq. # s and ACKs. GBN in action. TCP segment structure

rdt3.0: channels with errors and loss

Computer Networking: A Top Down Approach

Congestion Control. Principles of Congestion Control. Network assisted congestion. Asynchronous Transfer Mode. Computer Networks 10/23/2013

TCP congestion control:

Transport Layer PREPARED BY AHMED ABDEL-RAOUF

Flow and Congestion Control (Hosts)

Master Course Computer Networks IN2097

CSCD 330 Network Programming Winter 2015

Good Ideas So Far Computer Networking. Outline. Sequence Numbers (reminder) TCP flow control. Congestion sources and collapse

Transmission Control Protocol. ITS 413 Internet Technologies and Applications

Transport Layer Congestion Control

Transport protocols. Transport Layer 3-1

Master Course Computer Networks IN2097

By Ossi Mokryn, Based also on slides from: the Computer Networking: A Top Down Approach Featuring the Internet by Kurose and Ross

Data Communications & Networks. Session 9 Main Theme Network Congestion Causes, Effects, Controls, and TCP Applications. Dr. Jean-Claude Franchitti

User Datagram Protocol (UDP) Transmission Control Protocol (TCP)

TCP conges+on control

Part1: Lecture 2! TCP congestion control!

What is Congestion? Congestion: Moral of the Story. TCP Approach. Transport Layer: TCP Congestion Control & Buffer Management

Transport layer. UDP: User Datagram Protocol [RFC 768] Review principles: Instantiation in the Internet UDP TCP

T Computer Networks

Transport layer. Review principles: Instantiation in the Internet UDP TCP. Reliable data transfer Flow control Congestion control

CS3600 SYSTEMS AND NETWORKS

Congestion Control in TCP

CS4700/CS5700 Fundamentals of Computer Networks

Master Course Computer Networks IN2097

Bandwidth Allocation & TCP

CSC358 Week 5. Adapted from slides by J.F. Kurose and K. W. Ross. All material copyright J.F Kurose and K.W. Ross, All Rights Reserved

Congestion Control in TCP

The Transport Layer: TCP & Congestion Control

CSCE 463/612 Networks and Distributed Processing Spring 2017

15-744: Computer Networking TCP

Course on Computer Communication and Networks. Lecture 5 Chapter 3; Transport Layer, Part B

Outline Computer Networking. TCP slow start. TCP modeling. TCP details AIMD. Congestion Avoidance. Lecture 18 TCP Performance Peter Steenkiste

Fall 2012: FCM 708 Bridge Foundation I

Computer Network Fundamentals Spring Week 10 Congestion Control Andreas Terzis

image 3.8 KB Figure 1.6: Example Web Page

Department of Computer and IT Engineering University of Kurdistan. Transport Layer. By: Dr. Alireza Abdollahpouri

Flow and Congestion Control Marcos Vieira

CMSC 417. Computer Networks Prof. Ashok K Agrawala Ashok Agrawala. October 30, 2018

3.7 TCP congestion. reliable data transfer. sliding window. Lecture 4: Transport layer III: flow control and congestion control & Network layer I: IP

CS519: Computer Networks. Lecture 5, Part 4: Mar 29, 2004 Transport: TCP congestion control

Page 1. Review: Internet Protocol Stack. Transport Layer Services. Design Issue EEC173B/ECS152C. Review: TCP

Chapter 3 Transport Layer

NWEN 243. Networked Applications. Transport layer and application layer

CSCD 330 Network Programming Spring 2018 Lecture 11a Transport Layer

COMP/ELEC 429/556 Introduction to Computer Networks

Page 1. Review: Internet Protocol Stack. Transport Layer Services EEC173B/ECS152C. Review: TCP. Transport Layer: Connectionless Service

TCP Congestion Control

Computer Communication Networks Midterm Review

CS Transport. Outline. Window Flow Control. Window Flow Control

ECE 610: Homework 4 Problems are taken from Kurose and Ross.

TCP Congestion Control

TCP Congestion Control

Chapter 3: Transport Layer

Chapter 3 Transport Layer

Chapter 3 Transport Layer

Chapter 6 Transport Layer

Chapter 3 Transport Layer. Chapter 3: Transport Layer. Chapter 3 outline. Our goals: understand principles behind transport layer services:

Congestion Control in TCP

Congestion Control In The Internet Part 2: How it is implemented in TCP. JY Le Boudec 2014

Transcription:

Chapter 3 Transport Layer 1

Chapter 3 outline 3.1 Transport-layer services 3.2 Multiplexing and demultiplexing 3.3 Connectionless transport: UDP 3.4 Principles of reliable data transfer 3.5 Connection-oriented transport: TCP segment structure reliable data transfer flow control connection management 3.6 Principles of congestion control 3.7 TCP congestion control 2

Principles of Congestion Control Congestion: informally: too many sources sending too much data too fast for network to handle different from flow control! manifestations: lost packets (buffer overflow at routers) long delays (queueing in router buffers) a top-10 problem! 3

Causes/costs of congestion: scenario 1 Two senders, two receivers One router, infinite buffers no retransmission Host B Host A λ in : original data unlimited shared output link buffers λ out - Large delays when congested - Maximum achievable throughput 4

Causes/costs of congestion: scenario 2 - one router, finite buffers - sender retransmission of timed-out packet application-layer input = application-layer output: λ in = λ out transport-layer input includes retransmissions : λ in λ in Host B λ in : original data λ' in : original data, plus retransmitted data λ out Host A finite shared output link buffers 5

Congestion scenario 2a: ideal case - sender sends only when router buffers available Host B copy λ in : original data λ' in : original data, plus retransmitted data λ out Host A free buffer space! finite shared output link buffers 6

Congestion scenario 2a: ideal case - sender sends only when router buffers available λ out R/2 λ in R/2 Host B λ in : original data λ' in : original data, plus retransmitted data λ out Host A free buffer space! finite shared output link buffers 7

Congestion scenario 2b: known loss - Packets may get dropped at router due to full buffers - Sometimes lost - Sender only resends if packet known to be lost (admittedly idealized) Host B copy λ in : original data λ' in : original data, plus retransmitted data λ out Host A 8

Congestion scenario 2b: known loss packets may get dropped at router due to full buffers sometimes not lost sender only resends if packet known to be lost (admittedly idealized) λ out R/2 when sending at R/2, some packets are retransmissions but asymptotic goodput is still R/2 (why?) λ in R/2 Host B λ in : original data λ' in : original data, plus retransmitted data λ out Host A free buffer space! 9

Congestion scenario 2c: duplicates - packets may get dropped at router due to full buffers - sender times out prematurely, sending two copies, both of which are delivered copy λ in λ' in λ out Host B Host A free buffer space! 10

Congestion scenario 2c: duplicates - packets may get dropped at router due to full buffers - sender times out prematurely, sending two copies, both of which are delivered copy timeou t λ in λ' in λ out Host B Host A free buffer space! 11

Congestion scenario 2c: duplicates - packets may get dropped at router due to full buffers - sender times out prematurely, sending two copies, both of which are delivered λ out R/4 λ in R/2 when sending at R/2, some packets are retransmissions including duplicated that are delivered! costs of congestion: more work (retrans) for given goodput unneeded retransmissions: link carries multiple copies of pkt decreasing goodput 12

Causes/costs of congestion: scenario 3 - four senders - multihop paths - timeout/retransmit Host A λ in Q: what happens as and λ in increase? λ in : original data λ' in : original data, plus retransmitted data finite shared output link buffers λ out Host B 13

Causes/costs of congestion: scenario 3 H o st A λ o u t H o st B another cost of congestion: when packet dropped, any upstream transmission capacity used for that packet was wasted! 14

Approaches towards congestion control Two broad approaches towards congestion control: end-end congestion control: no explicit feedback from network congestion inferred from endsystem observed loss, delay approach taken by TCP network-assisted congestion control: routers provide feedback to end systems single bit indicating congestion (SNA, DECbit, TCP/IP ECN, ATM) explicit rate sender should send at 15

Chapter 3 outline 3.1 Transport-layer services 3.2 Multiplexing and demultiplexing 3.3 Connectionless transport: UDP 3.4 Principles of reliable data transfer 3.5 Connection-oriented transport: TCP segment structure reliable data transfer flow control connection management 3.6 Principles of congestion control 3.7 TCP congestion control 16

TCP congestion control: additive increase, multiplicative decrease approach: increase transmission rate (window size), probing for usable bandwidth, until loss occurs additive increase: increase cwnd by 1 MSS every RTT until loss detected multiplicative decrease: cut cwnd in half after loss saw tooth behavior: probing for bandwidth cwnd: congestion window size 2 4 K b y t e s 1 6 K b y t e s 8 K b y t e s c o n g e s t i o n w i n d o w time t i m e 17

TCP Congestion Control: details sender limits transmission: LastByteSent-LastByteAcked cwnd roughly, cwnd rate = Bytes/sec RTT How does sender perceive congestion? loss event = timeout or 3 duplicate acks TCP sender reduces rate (cwnd) after loss event cwnd is dynamic, function of perceived network congestion 18

TCP Slow Start when connection begins, increase rate exponentially until first loss event: initially cwnd = 1 MSS RTT Host A Host B one segment double cwnd every RTT done by incrementing cwnd for every ACK received two segments summary: initial rate is slow but ramps up exponentially fast four segments time 19

Refinement Q: when should the exponential increase switch to linear? A: when cwnd gets to 1/2 of its value before timeout. Implementation: variable ssthresh on loss event, ssthresh is set to 1/2 of cwnd just before loss event 20

Refinement: inferring loss after 3 dup ACKs: cwnd is cut in half window then grows linearly but after timeout event: cwnd instead set to 1 MSS; window then grows exponentially to a threshold, then grows linearly Philosophy: 3 dup ACKs indicates network capable of delivering some segments timeout indicates a more alarming congestion scenario 21

Summary: TCP Congestion Control Λ cwnd = 1 MSS ssthresh = 64 KB dupackcount = 0 timeout ssthresh = cwnd/2 cwnd = 1 MSS dupackcount = 0 retransmit missing segment dupackcount == 3 ssthresh= cwnd/2 cwnd = ssthresh + 3 retransmit missing segment duplicate ACK dupackcount++ slow start new ACK cwnd = cwnd+mss dupackcount = 0 transmit new segment(s), as allowed timeout ssthresh = cwnd/2 cwnd = 1 dupackcount = 0 retransmit missing segment cwnd > ssthresh Λ timeout ssthresh = cwnd/2 cwnd = 1 MSS dupackcount = 0 retransmit missing segment fast recovery new ACK. cwnd = cwnd + MSS (MSS/cwnd) dupackcount = 0 transmit new segment(s), as allowed cwnd = ssthresh dupackcount = 0 congestion avoidance New ACK dupackcount == 3 duplicate ACK dupackcount++ ssthresh= cwnd/2 cwnd = ssthresh + 3 retransmit missing segment duplicate ACK cwnd = cwnd + MSS transmit new segment(s), as allowed 22

TCP throughput what s the average throughout of TCP as a function of window size and RTT? ignore slow start let W be the window size when loss occurs. when window is W, throughput is W/RTT just after loss, window drops to W/2, throughput to W/2RTT. average throughout:.75 W/RTT 23

TCP Futures: TCP over long, fat pipes example: 1500 byte segments, 100ms RTT, want 10 Gbps throughput requires window size W = 83,333 in-flight segments throughput in terms of loss rate: 1. 22 MSS RTT L L = 2 10-10 Wow a very small loss rate! new versions of TCP for high-speed 24

TCP Fairness fairness goal: if K TCP sessions share same bottleneck link of bandwidth R, each should have average rate of R/K TCP connection 1 TCP connection 2 bottleneck router capacity R 25

Why is TCP fair? two competing sessions: additive increase gives slope of 1, as throughout increases multiplicative decrease decreases throughput proportionally R equal bandwidth share Connection 2 throughput Connection 1 throughput loss: decrease window by factor of 2 congestion avoidance: additive increase loss: decrease window by factor of 2 congestion avoidance: additive increase R 26

Fairness (more) Fairness and UDP multimedia apps often do not use TCP do not want rate throttled by congestion control instead use UDP: pump audio/video at constant rate, tolerate packet loss Fairness and parallel TCP connections nothing prevents app from opening parallel connections between 2 hosts. web browsers do this example: link of rate R supporting 9 connections; new app asks for 1 TCP, gets rate R/10 new app asks for 11 TCPs, gets R/2! 27