CSE 124 Networked Services Fall 2009 B. S. Manoj, Ph.D 10/20/20091CSE 124 Networked Services Fall 2009 Some.

Slides:



Advertisements
Similar presentations
Introduction 1 Lecture 13 Transport Layer (Transmission Control Protocol) slides are modified from J. Kurose & K. Ross University of Nevada – Reno Computer.
Advertisements

2: Transport Layer 31 Transport Layer 3. 2: Transport Layer 32 TCP Flow Control receiver: explicitly informs sender of (dynamically changing) amount of.
Transportation Layer. Very similar to the data link layer. – two hosts connected by a link or two hosts connected by a network differences: – When two.
Transport Layer3-1 TCP. Transport Layer3-2 TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 r full duplex data: m bi-directional data flow in same connection.
1 Chapter 3 Transport Layer Computer Networking: A Top Down Approach 4 th edition. Jim Kurose, Keith Ross Addison-Wesley, July A note on the use.
3-1 TCP Protocol r point-to-point: m one sender, one receiver r reliable, in-order byte steam: m no “message boundaries” r pipelined: m TCP congestion.
Data Communications and Computer Networks Chapter 3 CS 3830 Lecture 16 Omar Meqdadi Department of Computer Science and Software Engineering University.
1 Chapter 3 Transport Layer. 2 Chapter 3 outline 3.1 Transport-layer services 3.2 Multiplexing and demultiplexing 3.3 Connectionless transport: UDP 3.4.
1 Transport Layer Lecture 9 Imran Ahmed University of Management & Technology.
1 Chapter 5 End-to-End Protocols Outline 5.1 UDP 5.2 TCP 5.3 Remote Procedure Call.
CS 471/571 Transport Layer 5 Slides from Kurose and Ross.
Transport Layer3-1 Summary of Reliable Data Transfer Checksums help us detect errors ACKs and NAKs help us deal with errors If ACK/NAK has errors sender.
Week 9 TCP9-1 Week 9 TCP 3 outline r 3.5 Connection-oriented transport: TCP m segment structure m reliable data transfer m flow control m connection management.
8. Transport Protocol and UDP 8.1 Transport protocol : End-to-end protocol –IP: Host to host packet delivery –Transport: Process to process communication.
Transport Layer3-1 Pipelined protocols Pipelining: sender allows multiple, “in-flight”, yet-to- be-acknowledged pkts m range of sequence numbers must be.
1 Reliable Byte-Stream (TCP) Outline Connection Establishment/Termination Sliding Window Revisited Flow Control Adaptive Timeout.
Transport Layer1 TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 r reliable, in-order byte steam: m no “message boundaries” r pipelined: m TCP congestion.
6-May-154/598N: Computer Networks End-to-End Protocols Underlying best-effort network –drop messages –re-orders messages –delivers duplicate copies of.
TCP segment structure source port # dest port # 32 bits application data (variable length) sequence number acknowledgement number rcvr window size ptr.
CSE Computer Networks Prof. Aaron Striegel Department of Computer Science & Engineering University of Notre Dame Lecture 14 – February 23, 2010.
Chapter 3 outline 3.1 transport-layer services
Chapter 3 Transport Layer slides are modified from J. Kurose & K. Ross CPE 400 / 600 Computer Communication Networks Lecture 10.
EEC-484/584 Computer Networks Lecture 15 Wenbing Zhao (Part of the slides are based on Drs. Kurose & Ross ’ s slides for their Computer.
Transport Layer 3-1 Transport Layer r To learn about transport layer protocols in the Internet: m TCP: connection-oriented protocol m Reliability protocol.
Transport Layer Transport Layer: TCP. Transport Layer 3-2 TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 r full duplex data: m bi-directional.
Transport Layer 3-1 Transport Layer r To learn about transport layer protocols in the Internet: m TCP: connection-oriented protocol m Reliability protocol.
1 Announcement r Project 2 out m Much harder than project 1, start early! r Homework 2 due next Tuesday.
Transport Layer3-1 Chapter 3 Transport Layer Computer Networking: A Top Down Approach Featuring the Internet, 3 rd edition. Jim Kurose, Keith Ross Addison-Wesley,
Announcement Project 2 out –Much harder than project 1, start early! Homework 2 due next Tu.
The Future r Let’s look at the homework r The next test is coming the 19 th (just before turkey day!) r Monday will finish TCP canned slides r Wednesday.
Transport Layer3-1 Data Communication and Networks Lecture 7 Transport Protocols: TCP October 21, 2004.
Announcement Homework 1 graded Homework 2 out –Due in a week, 1/30 Project 2 problems –Minet can only compile w/ old version of gcc (2.96). –Only tlab-login.
Transport Layer session 1 TELE3118: Network Technologies Week 9: Transport Layer Basics Some slides have been taken from: r Computer Networking:
Spring 2002CS 4611 Reliable Byte-Stream (TCP) Outline Connection Establishment/Termination Sliding Window Revisited Flow Control Adaptive Timeout.
Network LayerII-1 RSC Part III: Transport Layer 3. TCP Redes y Servicios de Comunicaciones Universidad Carlos III de Madrid These slides are, mainly, part.
Transport Layer1 Reliable Transfer Ram Dantu (compiled from various text books)
Transport Layer 3-1 Chapter 3 Transport Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 All.
3: Transport Layer3b-1 TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 r full duplex data: m bi-directional data flow in same connection m MSS: maximum.
2: Transport Layer 21 Transport Layer 2. 2: Transport Layer 22 TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 r full duplex data: m bi-directional data.
TCOM 509 – Internet Protocols (TCP/IP) Lecture 04_b Transport Protocols - TCP Instructor: Dr. Li-Chuan Chen Date: 09/22/2003 Based in part upon slides.
1 CSCD 330 Network Programming Some Material in these slides from J.F Kurose and K.W. Ross All material copyright Lecture 10 Transport Layer.
Transport Layer3-1 Chapter 3: Transport Layer Our goals: r understand principles behind transport layer services: m multiplexing/demultipl exing m reliable.
Transport Layer3-1 Chapter 3 outline r 3.1 Transport-layer services r 3.2 Multiplexing and demultiplexing r 3.3 Connectionless transport: UDP r 3.4 Principles.
1 Introduction to Computer Networks University of ilam Dr. Mozafar Bag-Mohammadi Transport Layer.
CSE679: Computer Network Review r Review of the uncounted quiz r Computer network review.
September 26 th, 2013 CS1652 The slides are adapted from the publisher’s material All material copyright J.F Kurose and K.W. Ross, All Rights.
Transport Layer3-1 Chapter 3 outline r 3.1 Transport-layer services r 3.2 Multiplexing and demultiplexing r 3.3 Connectionless transport: UDP r 3.4 Principles.
Transport Layer3-1 Chapter 3 Transport Layer Computer Networking: A Top Down Approach 5 th edition. Jim Kurose, Keith Ross Addison-Wesley, April 2009.
EE 122: Transport Protocols Kevin Lai October 16, 2002.
Transport Layer3-1 Transport Layer If you are going through Hell Keep going.
1 End-to-End Protocols UDP TCP –Connection Establishment/Termination –Sliding Window Revisited –Flow Control –Congestion Control –Adaptive Timeout.
CIS679: TCP and Multimedia r Review of last lecture r TCP and Multimedia.
Transport Layer1 Goals: r understand principles behind transport layer services and protocols: m UDP m TCP Overview: r transport layer services r multiplexing/demultiplexing.
Chapter 3 Transport Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 A note on the use of these.
DMET 602: Networks and Media Lab Amr El Mougy Yasmeen EssamAlaa Tarek.
@Yuan Xue A special acknowledge goes to J.F Kurose and K.W. Ross Some of the slides used in this lecture are adapted from their.
09-Transport Layer: TCP Transport Layer.
COMP 431 Internet Services & Protocols
Chapter 3 outline 3.1 Transport-layer services
CS 1652 Jack Lange University of Pittsburgh
TCP: Overview RFCs: 793, 1122, 1323, 2018, 2581 full duplex data:
CS1652 TCP Jack Lange University of Pittsburgh
Review: UDP demultiplexing TCP demultiplexing Multiplexing?
Chapter 3 Transport Layer
Transport Layer Goals: Overview:
Transport Control Protocol
Chapter 3 outline 3.1 Transport-layer services
Transportation Layer.
Chapter 3 Transport Layer
Chapter 3 Transport Layer
Presentation transcript:

CSE 124 Networked Services Fall 2009 B. S. Manoj, Ph.D 10/20/20091CSE 124 Networked Services Fall 2009 Some of these slides are adapted from various sources/individuals including but not limited to the slides from the text books by Kurose and Ross, Peterson and Davie, digital libraries such as IEEE/ACM digital libraries and slides from Prof. Vahdat. Use of these slides other than for pedagogical purpose for CSE 124, may require explicit permissions from the respective sources.

Announcements Programming Assignment 1 – Submission window th October Week-3 Homework – Due on 26 th October First Paper Discussion – Discussion on 29 th October – Write-up due on: 28 th October Midterm: November 5 10/20/20092CSE 124 Networked Services Fall 2009

End-to-end Transport Layer Protocols End-to-end issues are important – Link-level (hop-level) benefit may not translate to end-to-end benefit Main objectives of end-to-end transport protocols – Quality of Service Reliability In order delivery Flow control – Fairness Flow fairness Network congestion – Handle the end-to-end network dynamics Round-trip-time Bandwidth We focus on Transmission Control Protocol (TCP) 10/20/2009CSE 124 Networked Services Fall 20093

TCP Main features of TCP – Connection oriented Connection setup, data transfer, and connection tear-down – Reliability – In-order delivery – Byte-stream oriented – Flow control Prevents senders from flooding the receiver Transmit at a rate acceptable to the receiver – Error control Retransmission – Congestion control Prevents senders from creating congestion in the network Manage transmission at a rate acceptable to the network 10/20/2009CSE 124 Networked Services Fall 20094

Multiplexing/Addressing Higher layer (Application/session layer services/applications) Transport layer (Port Number) Network layer (IP address) S1S1 S2S2 SnSn … C1C1 C2C2 CnCn … Network Connection: 10/20/20095CSE 124 Networked Services Fall 2009

How do we optimize the transmission rate Transmission rate optimization to achieve network capacity Bandwidth delay product is the suitable metric for flow capacity 10/20/2009CSE 124 Networked Services Fall Delay Bandwidth

Stop-and-wait operation first packet bit transmitted, t = 0 senderreceive r RTT last packet bit transmitted, t = L / R first packet bit arrives last packet bit arrives, send ACK ACK arrives, send next packet, t = RTT + L / R Example: 1 Gbps link, 15 ms prop. delay, 8000 bit packet 10/20/20097CSE 124 Networked Services Fall 2009

Filling the pipe operation first packet bit transmitted, t = 0 senderreceive r RTT last packet bit transmitted, t = L / R first packet bit arrives last packet bit arrives, send ACK ACK arrives, send next packet, t = RTT + L / R Example: 1 Gbps link, 15 ms prop. delay, 8000 bit packet, BDP=1Gbpsx30ms=30Mbits 10/20/20098CSE 124 Networked Services Fall 2009

Connection Establishment Process Three way handshake SYN, SYN+ACK, and ACK 10/20/2009CSE 124 Networked Services Fall 20099

3-10 TCP segment structure source port # dest port # 32 bits application data (variable length) sequence number acknowledgement number Receive window Urg data pointer checksum F SR PAU head len not used Options (variable length) URG: urgent data (generally not used) ACK: ACK # valid PSH: push data now (generally not used) RST, SYN, FIN: connection estab (setup, teardown commands) # bytes rcvr willing to accept counting by bytes of data (not segments!) Internet checksum (as in UDP) 10/20/2009

State transition diagram of TCP 10/20/2009CSE 124 Networked Services Fall Transition Event/Action

TCP Connection Management (cont.) Closing a connection: client closes socket: close(); Step 1: client end system sends TCP FIN control segment to server Step 2: server receives FIN, replies with ACK. Closes connection, sends FIN. client FIN server ACK FIN close closed timed wait 10/20/200912CSE 124 Networked Services Fall 2009

TCP Connection Management (cont.) Step 3: client receives FIN, replies with ACK. – Enters “timed wait” - will respond with ACK to received FINs Step 4: server, receives ACK. Connection closed. client FIN server ACK FIN closing closed timed wait closed 10/20/200913CSE 124 Networked Services Fall 2009

TCP Connection Management (cont) TCP client lifecycle TCP server lifecycle 10/20/200914CSE 124 Networked Services Fall 2009

Connection Established State Data transfer – Sender transmits data in sequence – Receiver acknowledges the received data packets – Sequence number helps in detecting loss and in-order delivery Sliding window management – Helps in in order delivery, reliable delivery, and flow control – Receiver window Round trip time estimation – Adaptive approach Congestion control – Many variants 10/20/2009CSE 124 Networked Services Fall

Sliding Window Management LastByteAcked ≤ LastByteSent LastByteSent ≤ LastByteWritten LastByteRead < NextByteExpected NextByteExpected ≤ LastByteRcvd+1 (if received in order, else, the beginning of the gap) LastByteRcvd –LastByteRead ≤ MaxRcvWindow AdvertizedWindow = MaxRcvBuffer – ((NextByteExpected -1) – LastByteRead) LastByteSent – LastByteAcked ≤ AdvertisedWindow EffectiveWindow = AdvertizedWindow – (LastByteSent – LastByteAcked) – EffectiveWindow >0 for transmitter to transmit (LastByteWritten – LastByteAcked)+y > MaxSendBuffer – Else the sender application is prevented from sending more 10/20/2009CSE 124 Networked Services Fall

10/20/2009CSE 124 Networked Services Fall SenderReceiver

Linux TCP: Packet ReceptionLinux TCP: Packet Transmission 10/20/2009CSE 124 Networked Services Fall /proc/sys/net/ipv4/tcp rmem/proc/sys/net/ipv4/tcp wmem

TCP Round Trip Time and Timeout EstimatedRTT = (1-  )*EstimatedRTT +  *SampleRTT r Exponential weighted moving average r influence of past sample decreases exponentially fast r typical value:  = /20/200919CSE 124 Networked Services Fall 2009

TCP Round Trip Time and Timeout Setting the timeout EstimtedRTT plus “safety margin” – large variation in EstimatedRTT -> larger safety margin first estimate of how much SampleRTT deviates from EstimatedRTT: TimeoutInterval = EstimatedRTT + 4*DevRTT TimeoutInterval is expoentially increased with every retransmission DevRTT = (1-  )*DevRTT +  *|SampleRTT-EstimatedRTT| (typically,  = 0.25) Then set timeout interval: 10/20/200920CSE 124 Networked Services Fall 2009

Summary Reading assignment TCP from Chapter 3 in Kurose and Ross TCP from Chapter 5 in Peterson and Davie 10/20/200921CSE 124 Networked Services Fall 2009