CS43: Computer Networks Reliable Data Transfer. Kevin Webb Swarthmore College October 5, 2017

Similar documents
CS 43: Computer Networks. 16: Reliable Data Transfer October 8, 2018

Lecture 7: Flow Control"

CSE 123: Computer Networks Alex C. Snoeren. HW 1 due NOW!

Lecture 7: Sliding Windows. CSE 123: Computer Networks Geoff Voelker (guest lecture)

Lecture 5: Flow Control. CSE 123: Computer Networks Alex C. Snoeren

Lecture 7: Flow & Media Access Control"

Lecture 4: CRC & Reliable Transmission. Lecture 4 Overview. Checksum review. CRC toward a better EDC. Reliable Transmission

Basic Reliable Transport Protocols

Communications Software. CSE 123b. CSE 123b. Spring Lecture 3: Reliable Communications. Stefan Savage. Some slides couresty David Wetherall

Computer Networking. Reliable Transport. Reliable Transport. Principles of reliable data transfer. Reliable data transfer. Elements of Procedure

Announcements. No book chapter for this topic! Slides are posted online as usual Homework: Will be posted online Due 12/6

ECE697AA Lecture 3. Today s lecture

Reliable Transport : Fundamentals of Computer Networks Bill Nace

Transport Protocols Reading: Sections 2.5, 5.1, and 5.2

The Transport Layer Reliability

Administrivia. FEC vs. ARQ. Reliable Transmission FEC. Last time: Framing Error detection. FEC provides constant throughput and predictable delay

Sliding Window Protocols, Connection Management, and TCP Reliability

Transport Protocols Reading: Sections 2.5, 5.1, and 5.2. Goals for Todayʼs Lecture. Role of Transport Layer

Network Protocols. Sarah Diesburg Operating Systems CS 3430

No book chapter for this topic! Slides are posted online as usual Homework: Will be posted online Due 12/6

Page 1. Goals for Today" Discussion" Example: Reliable File Transfer" CS162 Operating Systems and Systems Programming Lecture 11

Lecture 6: Reliable Transmission. CSE 123: Computer Networks Alex Snoeren (guest lecture) Alex Sn

Lecture 20 Overview. Last Lecture. This Lecture. Next Lecture. Transport Control Protocol (1) Transport Control Protocol (2) Source: chapters 23, 24

CS 43: Computer Networks. 18: Transmission Control Protocol October 12-29, 2018

ELEN Network Fundamentals Lecture 15

UNIT IV -- TRANSPORT LAYER

CS 640 Introduction to Computer Networks. Role of data link layer. Today s lecture. Lecture16

CRC. Implementation. Error control. Software schemes. Packet errors. Types of packet errors

Chapter 3. The Data Link Layer. Wesam A. Hatamleh

EE 122: Transport Protocols: UDP and TCP

Transport Protocols Reading: Sections 2.5, 5.1, and 5.2

Communication Networks

6.033 Lecture 12 3/16/09. Last time: network layer -- how to deliver a packet across a network of multiple links

CS 162 Operating Systems and Systems Programming Professor: Anthony D. Joseph Spring Lecture 21: Network Protocols (and 2 Phase Commit)

Reliable Transport I: Concepts and TCP Protocol

NWEN 243. Networked Applications. Layer 4 TCP and UDP

Question. Reliable Transport: The Prequel. Don t parse my words too carefully. Don t be intimidated. Decisions and Their Principles.

TCP Service Model. Today s Lecture. TCP Support for Reliable Delivery. EE 122:TCP, Connection Setup, Reliability

ECE 435 Network Engineering Lecture 9

Announcements. More Announcements. Brief History of Networking. How does a computer send messages over the Internet? 12/7/11

Transport Layer Marcos Vieira

CS457 Transport Protocols. CS 457 Fall 2014

Principles of Reliable Data Transfer

file:///c:/users/hpguo/dropbox/website/teaching/fall 2017/CS4470/H...

Problem 7. Problem 8. Problem 9

TCP : Fundamentals of Computer Networks Bill Nace

RSC Part III: Transport Layer 3. TCP

CSE 461: Framing, Error Detection and Correction

Lecture 5. Homework 2 posted, due September 15. Reminder: Homework 1 due today. Questions? Thursday, September 8 CS 475 Networks - Lecture 5 1

EE 122: IP Forwarding and Transport Protocols

10.1 REVIEW QUESTIONS

2.4 Error Detection Bit errors in a frame will occur. How do we detect (and then. (or both) frames contains an error. This is inefficient (and not

Links Reading: Chapter 2. Goals of Todayʼs Lecture. Message, Segment, Packet, and Frame

Error Detection Codes. Error Detection. Two Dimensional Parity. Internet Checksum Algorithm. Cyclic Redundancy Check.

The flow of data must not be allowed to overwhelm the receiver

CSC 4900 Computer Networks: TCP

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

ERROR AND FLOW CONTROL. Lecture: 10 Instructor Mazhar Hussain

CMSC 332 Computer Networks Reliable Data Transfer

Fault Tolerance. it continues to perform its function in the event of a failure example: a system with redundant components

Page 1. Goals for Today" Placing Network Functionality" Basic Observation" CS162 Operating Systems and Systems Programming Lecture 15

EE 122: Error detection and reliable transmission. Ion Stoica September 16, 2002

CSC 4900 Computer Networks: Reliable Data Transport

Reliable Transport I: Concepts and TCP Protocol

CS4700/CS5700 Fundamentals of Computer Networks

CS 716: Introduction to communication networks th class; 7 th Oct Instructor: Sridhar Iyer IIT Bombay

Reliable Data Transfer

Lecture 10: Transpor Layer Principles of Reliable Data Transfer

Lecture - 14 Transport Layer IV (Reliability)

ECE 435 Network Engineering Lecture 10

CS 5565 Spring CS 5565 Midterm

Chapter 3 Transport Layer

TCP. CSU CS557, Spring 2018 Instructor: Lorenzo De Carli (Slides by Christos Papadopoulos, remixed by Lorenzo De Carli)

Chapter III: Transport Layer

Data Link Layer (1) Networked Systems 3 Lecture 6

Networked Systems and Services, Fall 2018 Chapter 2. Jussi Kangasharju Markku Kojo Lea Kutvonen

Chapter 3: Transport Layer. Chapter 3 Transport Layer. Chapter 3 outline. Transport services and protocols

Chapter 3: Transport Layer Part A

CSCI Topics: Internet Programming Fall 2008

CSC 8560 Computer Networks: TCP

Data Link Control. Surasak Sanguanpong Last updated: 11 July 2000

CSC 401 Data and Computer Communications Networks

CS519: Computer Networks. Lecture 5, Part 1: Mar 3, 2004 Transport: UDP/TCP demux and flow control / sequencing

CSCI-1680 Link Layer I Rodrigo Fonseca

Announcements. IP Forwarding & Transport Protocols. Goals of Today s Lecture. Are 32-bit Addresses Enough? Summary of IP Addressing.

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

CSCI-1680 Link Layer Reliability Rodrigo Fonseca

Outline. CS5984 Mobile Computing

CSE/EE 461. Sliding Windows and ARQ. Last Time. This Time. We finished up the Network layer Internetworks (IP) Routing (DV/RIP, LS/OSPF)

CS 5520/ECE 5590NA: Network Architecture I Spring Lecture 13: UDP and TCP

Lecture 11: Transport Layer Reliable Data Transfer and TCP

CS 3516: Advanced Computer Networks

Computer Networks. Sándor Laki ELTE-Ericsson Communication Networks Laboratory

TCP: Flow and Error Control

PROBLEMSAND EXERCISES

High Level View. EE 122: Error detection and reliable transmission. Overview. Error Detection

Chapter 3 Transport Layer

TDTS06: Computer Networks

Chapter 11 Data Link Control 11.1

The Transport Layer: TCP & Reliable Data Transfer

Transcription:

CS43: Computer Networks Reliable Data Transfer Kevin Webb Swarthmore College October 5, 2017

Agenda Today: General principles of reliability Next time: details of one concrete, very popular protocol: TCP

The Two Generals Problem Two army divisions (blue) surround enemy (red) Each division led by a general Both must agree when to simultaneously attack If either side attacks alone, defeat Generals can only communicate via messengers Messengers may get captured (unreliable channel)

The Two Generals Problem How to coordinate? Send messenger: Attack at dawn What if messenger doesn t make it?

The Two Generals Problem How to be sure messenger made it? Send acknowledgment: I delivered message

In the two generals problem, can the two armies reliably coordinate their attack? A. Yes (explain how) B. No (explain why not)

The Two Generals Problem Result Can t create perfect channel out of faulty one Can only increase probability of success

Give up? No way! As humans, we like to face difficult problems. We can t control oceans, but we can build canals We can t fly, but we ve landed on the moon We just need engineering! (Unsinkable)

Engineering Concerns Message corruption Message duplication Message loss Message reordering Performance Our toolbox Checksums Timeouts Acks & Nacks Sequence numbering Pipelining

Engineering Concerns Message corruption Message duplication Message loss Message reordering Performance Our toolbox Checksums Timeouts Acks & Nacks Sequence numbering Pipelining We use these to build Automatic Repeat Request (ARQ) protocols. (We ll briefly talk about alternatives at the end.)

Automatic Repeat Request (ARQ) Intuitively, ARQ protocols act like you would when using a cell phone with bad reception. Message garbled? Ask to repeat. Didn t hear a response? Speak again. Refer to book for building state machines. We ll look at TCP s states soon

ARQ Broad Classifications 1. Stop-and-wait

Stop and Wait Time

Corruption? Time Error detection mechanism: checksum Data good receiver sends back ACK Data corrupt receiver sends back NACK

Could we do this with just ACKs or just NACKs? A. No, we need them both. Time B. Yes, we could do without one of them, but we d need some other mechanism. C. Yes, we could get by without one of them. Error detection mechanism: checksum Data good receiver sends back ACK Data corrupt receiver sends back NACK

Could we do this with just ACKs or just NACKs? A. No, we need them both. Time B. Yes, we could do without one of them, but we d need some other mechanism. C. Yes, we could get by without one of them. With only ACK, we could get by with a timeout. With only NACK, we couldn t advance (no good).

Timeouts Time Timeout T imeout Timeout Corruption? Send no response. starts a clock. If no response, retry. Probably not a great idea for handling corruption, but it works.

Timeouts and Losses Time T imeout Timeout T imeout Timeouts help us handle message losses too!

Adding timeouts might create new problems for us to worry about. How many? Examples? Time T imeout Timeout T imeout A. No new problems (why not?) B. One new problem (what is it?) C. Two new problems (what are they?) D. More than two new problems (what are they?)

Sequence Numbering Add a monotonically increasing label to each msg Ignore messages with numbers we ve seen before When pipelining (a few slides from now) Detect gaps in the sequence (e.g., 1,2,4,5) 3 2 1

Suppose we had a modest 8 Mbps (one megabyte per second) link. Our RTT is 100 ms, and we send 1024-byte (1K) segments. What is our link utilization with a stop and wait protocol? A. < 0.1 % B. 0.1 % C. 1 % D. 1-10 % E. > 10 %

Pipelined Transmission Now what? Keep multiple segments in flight Allows sender to make efficient use of the link Sequence numbers ensure receiver can distinguish segments We ll talk about how many next time (windowing).

What should the sender do here? What information does the sender need to make that decision? What is required by either party to keep track? Now what? A. Start sending all data again from 0. B. Start sending all data again from 2. C. Resend just 2, then continue with 4 afterwards.

ARQ Broad Classifications 1. Stop-and-wait 2. Go-back-N

Timeout Go-Back-N Retransmit from point of loss Segments between loss event and retransmission are ignored Go-back-N if a timeout event occurs Fast retransmit Don t wait for timeout if we get a duplicate ACK

Timeout Go-Back-N Retransmit from point of loss Segments between loss event and retransmission are ignored Go-back-N if a timeout event occurs Fast retransmit Don t wait for timeout if we get N duplicate ACKs

ARQ Broad Classifications 1. Stop-and-wait 2. Go-back-N 3. Selective repeat a.k.a selective reject, selective acknowledgement

Timeout Selective Repeat ACKs each segment individually (not cumulative) only resends those not ACKed Requires extra buffering and state on the receiver

ARQ Alternatives Can t afford the RTT s or timeouts? When? Broadcasting, with lots of receivers Very lossy or long-delay channels (e.g., space) Use redundancy send more data Simple form: send the same message N times More efficient: use erasure coding For example, encode your data in 10 pieces such that the receiver can piece it together with any subset of size 8.