Transport Layer. Transport Protocols. Transport Layer Services. Transport Services and Protocols. Transport vs. Application and Network Layer

Size: px
Start display at page:

Download "Transport Layer. Transport Protocols. Transport Layer Services. Transport Services and Protocols. Transport vs. Application and Network Layer"

Transcription

1 Transport Layer Transport Layer Services connection-oriented vs. connectionless multiplexing and demultplexing UDP: Connectionless Unreliable Service TCP: Connection-Oriented Reliable Service connection management: set-up and tear down reliable data transfer protocols flow and congestion control Readings: Chapter 5 (5.1, 5.2) Transport Protocols Lowest level end-toend protocol. Header generated by sender is interpreted only by the destination Routers view transport header as part of the payload Transport IP Datalink Physical IP router Transport IP Datalink Physical Csci 232 Computer Networks Transport Layer & TCP 1 Csci 232 Computer Networks Transport Layer & TCP 2 Transport Services and Protocols provide logical communication between app processes running on different hosts transport protocols run in end systems send side: breaks app messages into segments, passes to layer rcv side: reassembles segments into messages, passes to app layer more than one transport protocol available to apps Internet: TCP and UDP transport logical end-end transport transport Transport Layer Services Underlying best-effort drops messages re-orders messages delivers duplicate copies of a given message delivers messages after an arbitrarily long delay Common end-to-end services guarantee message delivery deliver messages in the same order they are sent deliver at most one copy of each message allow the receiver to flow control the sender support multiple processes on each host Csci 232 Computer Networks Transport Layer & TCP 3 Csci 232 Computer Networks Transport Layer & TCP 4 Transport vs. Application and Network Layer layer: processes and message exchange layer: logical communication between hosts transport layer: logical communication support for app processes relies on, enhances, layer services Household analogy: 12 kids sending letters to 12 kids processes = kids app messages = letters in envelopes hosts = houses transport protocol = Ann and Bill -layer protocol = postal service End to End Issues Transport services built on top of (potentially) unreliable service packets can be corrupted or lost s can be delayed or arrive out of order Do we detect and/or recover errors for apps? Error Control & Reliable Data Transfer Do we provide in-order delivery of packets? Connection Management & Reliable Data Transfer Potentially different capacity at destination, and potentially different capacity Flow and Congestion Control Csci 232 Computer Networks Transport Layer & TCP 5 Csci 232 Computer Networks Transport Layer & TCP 6 1

2 Internet Transport Protocols TCP service: connection-oriented: setup required between client, reliable transport between sender and receiver flow control: sender won t overwhelm receiver congestion control: throttle sender when overloaded UDP service: unreliable data transfer between sender and receiver does not provide: connection setup, reliability, flow control, congestion control Both provide logical communication between app processes running on different hosts! Csci 232 Computer Networks Transport Layer & TCP 7 Multiplexing/Demultiplexing Demultiplexing at rcv host: delivering received segments to correct process transport link = API ( socket ) P3 = process P1 P1 transport link host 1 host 2 Multiplexing at send host: gathering data from multiple app processes, enveloping data with header (later used for demultiplexing) transport Csci 232 Computer Networks Transport Layer & TCP 8 P2 P4 host 3 link How Demultiplexing Works host receives IP datagrams each datagram has source IP address, destination IP address each datagram carries 1 transport-layer segment each segment has source, destination port number (recall: well-known port numbers for specific s) host uses IP addresses & port numbers to direct segment to appropriate app process (identified by socket ) 32 bits source port # dest port # other header fields data (message) TCP/UDP segment format UDP: User Datagram Protocol [RFC 768] no frills, bare bones Internet transport protocol best effort service, UDP segments may be: lost delivered out of order to app connectionless: no handshaking between UDP sender, receiver each UDP segment handled independently of others Why is there a UDP? no connection establishment (which can add delay) simple: no connection state at sender, receiver small segment header no congestion control: UDP can blast away as fast as desired Csci 232 Computer Networks Transport Layer & TCP 9 Csci 232 Computer Networks Transport Layer & TCP 10 UDP (cont d) UDP Checksum often used for streaming multimedia apps loss tolerant rate sensitive other UDP users DNS SNMP reliable transfer over UDP: add reliability at layer -specific error recovery! Length, in bytes of UDP segment, including header 32 bits source port # dest port # length Application data (message) checksum UDP segment format Goal: detect errors (e.g., flipped bits) in transmitted segment Sender: treat segment contents as sequence of 16-bit integers checksum: addition (1 s complement sum) of segment contents sender puts checksum value (1 s complement of 1 s complement sum of 16- bit words) into UDP checksum field Receiver: compute checksum of received segment check if computed checksum equals checksum field value: NO - error detected YES - no error detected. But maybe errors nonetheless? More later. Csci 232 Computer Networks Transport Layer & TCP 11 Csci 232 Computer Networks Transport Layer & TCP 12 2

3 Checksum: Example arrange data segment in sequences of bit words sum: checksum(1 s complement): Connection-oriented Byte-stream app writes bytes TCP sends segments app reads bytes Application process TCP Overview Write bytes Full duplex Flow control: keep sender from overrunning receiver Congestion control: keep sender from overrunning Application process Read bytes verify by adding: TCP Send buffer TCP Receive buffer Segment Segment Segment Transmit segments Csci 232 Computer Networks Transport Layer & TCP 13 Csci 232 Computer Networks Transport Layer & TCP 14 Functionality Split Network provides best-effort delivery End-systems implement many functions Reliability In-order delivery Demultiplexing Message boundaries Connection abstraction Flow Control Congestion control High-Level TCP Characteristics Protocol implemented entirely at the ends Fate sharing Protocol has evolved over time and will continue to do so Nearly impossible to change the header Use options to add information to the header Change processing at endpoints Backward compatibility is what makes it TCP Csci 232 Computer Networks Transport Layer & TCP 15 Csci 232 Computer Networks Transport Layer & TCP 16 Evolution of TCP TCP Through the 1990s 1975 Three-way handshake Raymond Tomlinson In SIGCOMM TCP described by Vint Cerf and Bob Kahn In IEEE Trans Comm 1984 Nagel s algorithm to reduce overhead 1987 of small packets; Karn s algorithm 1990 predicts congestion to better estimate 4.3BSD Reno collapse round-trip time fast retransmit delayed s 1983 BSD Unix supports TCP/IP Congestion Van Jacobson s collapse algorithms observed congestion avoidance 1982 and congestion control TCP & IP (most implemented in RFC 793 & BSD Tahoe) 1993 TCP Vegas (Brakmo et al) real congestion avoidance 1994 T/TCP (Braden) Transaction TCP 1994 ECN (Floyd) Explicit Congestion Notification 1996 S TCP (Floyd et al) Selective Acknowledgement Hoe F TCP Improving TCP (Mathis et al) startup extension to S Csci 232 Computer Networks Transport Layer & TCP 17 Csci 232 Computer Networks Transport Layer & TCP 18 3

4 TCP Segment Header Structure URG: urgent data (generally not used) : # valid PSH: push data now (generally not used) RST, SYN, : connection estab (setup, teardown commands) Internet checksum (as in UDP) 32 bits source port # dest port # sequence number acknowledgement number head not UAP R S rcvr window size len used F checksum ptr urgent data Options (variable length) data (variable length) counting by bytes of data (not segments!) # bytes rcvr willing to accept Csci 232 Computer Networks Transport Layer & TCP 19 TCP Segment Format (cont) Each connection identified with 4-tuple: (SrcPort, SrcIPAddr, DstPort, DstIPAddr) Sliding window + flow control acknowledgment, SequenceNum, AdvertisedWinow Sender Data (SequenceNum) Receiver Acknowledgment + AdvertisedWindow Flags SYN,,, RESET, PUSH, URG Checksum pseudo header (src & dst IP addresses) + TCP header + data Csci 232 Computer Networks Transport Layer & TCP 20 TCP Connection Set Up TCP sender, receiver establish connection before exchanging data segments initialize TCP variables: seq. # buffers, flow control info client: end host that initiates connection : end host contacted by client Three way handshake: Step 1: client sends TCP SYN control segment to specifies initial seq # Step 2: receives SYN, replies with SYN+ control segment s received SYN specifies receiver initial seq. # Step 3:client receives SYN+, replies with segment (which may contain 1 st data segment) Csci 232 Computer Networks Transport Layer & TCP 21 initiate connection connection established client TCP 3-Way Hand-Shake SYN, seq=x SYN+, seq=y, ack=x+1, seq=x+1, ack=y+1 (1 st data segment) SYN received connection established Question: a. What kind of state client and need to maintain? b. What initial sequence # should client (and ) use? Csci 232 Computer Networks Transport Layer & TCP 22 TCP Connection Setup Example No. Time Source > Destination Proto SrcPort>DstPort [Flags] TCP 1414 > 22 [SYN] Seq= Len=0 MSS= TCP 22 > 1414 [SYN, ] Seq= Ack= Win=25200 Len=0 MSS= TCP 1414 > 22 [] Seq= Ack= Win=16384 Len=0 TCP Connection Setup Example No. Time Source > Destination Proto SrcPort>DstPort [Flags] TCP 1567 > 80 [SYN] Seq= Len=0 MSS= TCP 80> 1567 [SYN, ] Seq= Ack= Win=25200 Len=0 MSS= TCP 1567 > 80 [] Seq= Ack= Win=17640 Len= TCP 1567 > 80 [PSH,] Seq= Ack= Win=17640 Len= TCP 80> 1567 [] Seq= Ack= Win=25200 Len=0 MSS=1460 Csci 232 Computer Networks Transport Layer & TCP 23 Csci 232 Computer Networks Transport Layer & TCP 24 4

5 Connection Setup Error Scenarios Lost (control) packets What happen if SYN lost? client vs. actions What happen if SYN+ lost? client vs. actions What happen if lost? client vs. actions Duplicate (control) packets What does do if duplicate SYN received? What does client do if duplicate SYN+ received? What does do if duplicate received? Connection Setup Error Scenarios (cont d) Importance of (unique) initial seq. no.? When receiving SYN, how does know it s a new connection request? When receiving SYN+, how does client know it s a legitimate, i.e., a response to its SYN request? Dealing with old duplicate packets from old connections (or from malicious users) If not careful: TCP Hijacking How to choose unique initial seq. no.? randomly choose a number (and add to last syn# used) Other security concern: SYN Flood -- denial-of-service attack Csci 232 Computer Networks Transport Layer & TCP 25 Csci 232 Computer Networks Transport Layer & TCP 26 Detecting Half-Open Connections TCP A 1. (CRASH) 2. D 3. SYN-SENT <SEQ=400><CTL=SYN> 4. (!!) <SEQ=300><=100><CTL=> 5. SYN-SENT <SEQ=100><CTL=RST> 6. SYN-SENT 7. SYN-SENT <SEQ=400><CTL=SYN> (send 300, receive 100) ESTABLISHED (??) ESTABLISHED (Abort!!) D Csci 232 Computer Networks Transport Layer & TCP 27 TCP B TCP State Diagram: Connection Setup SYN RCVD Send Client D Server passive OPEN create TCP delete TCP rcv SYN snd SYN rcv of SYN LISTEN rcv SYN snd ESTAB SEND snd SYN Rcv SYN, Snd delete TCP active OPEN create TCP Snd SYN SYN SENT Csci 232 Computer Networks Transport Layer & TCP 28 TCP: Closing Connection Remember TCP duplex connection! Client wants to close connection: client Step 1: client end system sends TCP control segment to client closing Step 2: receives, replies with. half Step 3: client receives. half half, wait for to close Server finishes sending data, also ready to close: Step 4: sends. half closing TCP: Closing Connection (cont d) Step 5: client receives, replies with. connection fully Step 6:, receives. connection fully Well Done! Problem Solved? client closing half full client half closing full Csci 232 Computer Networks Transport Layer & TCP 29 Csci 232 Computer Networks Transport Layer & TCP 30 5

6 TCP: Closing Connection (revised) Two Army Problem! Step 5: client receives, replies with. Enters timed wait - will respond with to received s Step 6:, receives. connection fully Step 7: client, timer expires, connection fully client closing half timed wait full client X half closing timeout full TCP Connection Tear-Down Example No. Time Source > Destination Proto SrcPort>DstPort [Flags] TCP 1414 > 22 [PSH,] Seq= Ack= Win=15920 Len= TCP 1414 > 22 [, ] Seq= Ack= Win=15920 Len= TCP 22 > 1414 [] Seq= Ack= Win=25200 Len= TCP 22 > 1414 [] Seq= Ack= Win=25200 Len= TCP 22 > 1414 [,] Seq= Ack= Win=25200 Len= TCP 1414 > 22 [] Seq= Ack= Win=15920 Len=0 Csci 232 Computer Networks Transport Layer & TCP 31 Csci 232 Computer Networks Transport Layer & TCP 32 State Diagram: Connection Tear-down TCP Connection Management FSM TCP client lifecycle send WAIT-1 WAIT-2 Active Close ESTAB send rcv snd rcv + snd CLOSING rcv send rcv of Passive Close WAIT snd LAST- rcv of TCP client lifecycle rcv snd TIME WAIT =2min delete TCP D Csci 232 Computer Networks Transport Layer & TCP 33 Csci 232 Computer Networks Transport Layer & TCP 34 TCP Connection Management FSM TCP lifecycle TCP lifecycle Reliability and Error Recovery ARQ vs. FEC automatic retransmission request forward error correction General ARQ Algorithms Stop & Wait Perform issue: low utilization when delay-bw product large Sliding Window Protocols Go-Back-N Selective Repeat Key design issues: window size vs. size of seq. no. space Csci 232 Computer Networks Transport Layer & TCP 35 Csci 232 Computer Networks Transport Layer & TCP 36 6

7 Error Recovery: Stop and Wait ARQ Receiver sends acknowledgement () when it receives packet Sender waits for and timeouts if it does not arrive within some time period Simplest ARQ protocol Send a packet, stop and wait until arrives Time Sender Csci 232 Computer Networks Transport Layer & TCP 37 Receiver Time Recovering from Error lost lost Csci 232 Computer Networks Transport Layer & TCP 38 Early timeout DUPLICATE PETS!!! Problems with Stop and Wait How to recognize a duplicate Performance Can only send one packet per round trip How to Recognize Resends? Use sequence numbers both packets and acks Sequence # in packet is finite How big should it be? For stop and wait? One bit won t send seq #1 until received for seq #0 Pkt 0 0 Pkt Pkt 1 Csci 232 Computer Networks Transport Layer & TCP 39 Csci 232 Computer Networks Transport Layer & TCP 40 Problem with Stop & Wait Protocol Sender first packet bit transmitted, t = 0 RTT arrives, send next packet, t = RTT + L / R data (L bytes) Receiver Can t keep the pipe full Utilization is low when bandwidth-delay product (R x RTT)is large! first packet bit arrives Stop & Wait: Performance Analysis Example: 1 Gbps connection, 15 ms end-end prop. delay, data segment size: 1 KB = 8Kb L (packet length in bits) 8 kb Ttransmit = = 9 R (transmiss ion rate, bps) 10 b/s 6 = 8 10 s = ms L / R L.008 U sender = = = = RTT + L / R RTT * R + L U sender : utilization, i.e., fraction of time sender busy sending 1KB data segment every 30 msec (round trip time) --> 0.027% x 1 Gbps = 33kB/sec throughput over 1 Gbps link Moral of story: protocol limits use of resources! Csci 232 Computer Networks Transport Layer & TCP 41 Csci 232 Computer Networks Transport Layer & TCP 42 7

8 How to Keep the Pipe Full? Send multiple packets without waiting for first to be acked Number of pkts in flight = window Reliable, unordered delivery Several parallel stop & waits Send new packet after each ack Sender keeps list of unack ed packets; resends after timeout Receiver same as stop & wait How large a window is needed? Suppose 10Mbps link, 4ms delay, 500byte pkts 1? 10? 20? Round trip delay * bandwidth = capacity of pipe Csci 232 Computer Networks Transport Layer & TCP 43 Pipelined (Sliding Window) Protocols Pipelining: sender allows multiple, in-flight, yet-tobe-acknowledged data segments range of sequence numbers must be increased buffering at sender and/or receiver Two generic forms of pipelined protocols: Go-Back-N and Selective Repeat Csci 232 Computer Networks Transport Layer & TCP 44 Pipelining: Increased Utilization sender receiver Sliding Window first packet bit transmitted, t = 0 last bit transmitted, t = L / R RTT arrives, send next packet, t = RTT + L / R U sender = 3 * L / R RTT + L / R = first packet bit arrives last packet bit arrives, send last bit of 2 nd packet arrives, send last bit of 3 rd packet arrives, send = Increase utilization by a factor of 3! Reliable, ordered delivery Receiver has to hold onto a packet until all prior packets have arrived Why might this be difficult for just parallel stop & wait? Sender must prevent buffer overflow at receiver Circular buffer at sender and receiver s in transit buffer size Advance when sender and receiver agree packets at beginning have been received Csci 232 Computer Networks Transport Layer & TCP 45 Csci 232 Computer Networks Transport Layer & TCP 46 Sender/Receiver State Window Sliding Common Case Max received Sent & Acked Sender Next seqnum Sender window Sent Not Acked Receiver Next expected Received & Acked Receiver window Max acceptable Acceptable On reception of new (i.e. for something that was not acked earlier) Increase sequence of max received Send next packet On reception of new in-order data packet (next expected) Hand packet to Send cumulative acknowledges reception of all packets up to sequence number Increase sequence of max acceptable packet OK to Send Not Usable Not Usable Csci 232 Computer Networks Transport Layer & TCP 47 Csci 232 Computer Networks Transport Layer & TCP 48 8

9 Loss Recovery Go-Back-N recovery Set timer upon transmission of each packet Cumulative Retransmit all unacknowledged packets No receiver buffering, out-of-order packets are discarded Selective Repeat Sender keeps a timer for each packet Selective Receiver must buffer all out-of-order packets When timeout, retransmit only one packet Performance during loss recovery No longer have an entire window in transit Can have much more clever loss recovery Csci 232 Computer Networks Transport Layer & TCP 49 Go-Back-N in Action Csci 232 Computer Networks Transport Layer & TCP 50 Selective Repeat Receiver individually acknowledges all correctly received pkts Buffers packets, as needed, for eventual in-order delivery to upper layer Sender only resends packets for which not received Sender timer for each uned packet Sender window N consecutive seq # s Again limits seq #s of sent, uned packets Selective Repeat: Sender, Receiver Windows Csci 232 Computer Networks Transport Layer & TCP 51 Csci 232 Computer Networks Transport Layer & TCP 52 Sequence Numbers How large does size of sequence number space need to be? Must be able to detect wrap-around Depends on sender/receiver window size E.g. size of seq. no. space = 8, send win=recv win=7 If pkts 0..6 are sent succesfully and all acks lost Receiver expects 7,0..5, sender retransmits old 0..6!!! size of sequence no. space must be send window + recv window Csci 232 Computer Networks Transport Layer & TCP 53 Sequence Numbers in TCP TCP regards data as a byte-stream each byte in byte stream is numbered. 32 bit value, wraps around initial values selected at start up time TCP breaks up byte stream in packets. size is limited to the Maximum Segment Size (MSS) Each packet has a sequence number seq. no of 1 st byte indicates where it fits in the byte stream TCP connection is duplex data in each direction has its own sequence numbers packet 8 packet 9 packet 10 Csci 232 Computer Networks Transport Layer & TCP 54 9

10 TCP Seq. # s and s Seq. # s: byte stream number of first byte in segment s data s: seq # of next byte expected from other side User types C host s receipt of echoed C Host A Host B Seq=42, =79, data = C Seq=79, =43, data = C Seq=43, =80 red: A-to-B green: B-to-A simple telnet scenario host s receipt of C, echoes back C time TCP Reliable Data Transfer TCP creates reliable data transfer service on top of IP s unreliable service Pipelined segments Cumulative s TCP uses single retransmission timer Retransmissions are triggered by: timeout events duplicate acks Initially consider simplified TCP sender: ignore duplicate acks ignore flow control, congestion control Csci 232 Computer Networks Transport Layer & TCP 55 Csci 232 Computer Networks Transport Layer & TCP 56 TCP = Go-Back-N Variant Sliding window with cumulative acks Receiver can only return a single ack sequence number to the sender. Acknowledges all bytes with a lower sequence number Starting point for retransmission Duplicate acks sent when out-of-order packet received But: sender only retransmits a single packet. Reason??? Only one that it knows is lost Network is congested shouldn t overload it Error control is based on byte sequences, not packets. Retransmitted packet can be different from the original lost packet Why? data rcvd from app: Create segment with seq # seq # is byte-stream number of first data byte in segment start timer if not already running (think of timer as for oldest unacked segment) expiration interval: TimeOutInterval TCP Sender Events: timeout: retransmit segment that caused timeout restart timer received: If acknowledges previously uned segments update what is known to be ed start timer if there are outstanding segments Csci 232 Computer Networks Transport Layer & TCP 57 Csci 232 Computer Networks Transport Layer & TCP 58 TCP generation [RFC 1122, RFC 2581] Event at Receiver Arrival of in-order segment with expected seq #. All data up to expected seq # already ed Arrival of in-order segment with expected seq #. One other segment has pending Arrival of out-of-order segment higher-than-expect seq. #. Gap detected Arrival of segment that partially or completely fills gap TCP Receiver Action Delayed. Wait up to 500ms for next segment. If no next segment, send Immediately send single cumulative, ing both in-order segments Immediately send duplicate, indicating seq. # of next expected byte Immediate send, provided that segment starts at lower end of gap Csci 232 Computer Networks Transport Layer & TCP 59 receive side of TCP connection has a receive buffer: app process may be slow at reading from buffer TCP Flow Control flow control sender won t overflow receiver s buffer by transmitting too much, too fast speed-matching service: matching the send rate to the receiving app s drain rate Csci 232 Computer Networks Transport Layer & TCP 60 10

11 TCP Flow Control: How It Works (Suppose TCP receiver discards out-of-order segments) spare room in buffer = RcvWindow (dynamically changes) = RcvBuffer-[LastByteRcvd - LastByteRead] Rcvr advertises spare room by including value of RcvWindow in segments Sender limits uned data to RcvWindow guarantees receive buffer doesn t overflow URG: urgent data (generally not used) : # valid PSH: push data now (generally not used) RST, SYN, : connection estab (setup, teardown commands) Internet checksum (as in UDP) TCP Segment Structure 32 bits source port # dest port # sequence number acknowledgement number head not UAP R S rcvr window size len used F checksum ptr urgent data Options (variable length) data (variable length) counting by bytes of data (not segments!) # bytes rcvr willing to accept Csci 232 Computer Networks Transport Layer & TCP 61 Csci 232 Computer Networks Transport Layer & TCP 62 Triggering Transmission How does TCP decide to transmit a segment? MSS (Maximum segment size) Set to size of the largest segment TCP can send without local IP fragmentation (MTU of directly connected) Sending process explicitly asked to do (Push to flush) Firing timer Silly Window Syndrome Flow control needs to be maintained Sender can transmit full segment (MSS) when Acked by receiver Silly Window Syndrome (cont d) Window currently from receiver opens MSS/2 bytes Should sender transmit MSS/2? Original TCP implementation silent Early implementation of TCP decided to go ahead Sender can not know when the window will open for full MSS If sender is aggressive, sending available window size results Silly window syndrome small segment size remains indefinitely Hence a problem when either sender transmits a small segment or receiver opens window a small amount Csci 232 Computer Networks Transport Layer & TCP 63 Csci 232 Computer Networks Transport Layer & TCP 64 Triggering Transmission (cont d) Receiver may delay s, but how long? Ultimate solution lies with sender: When does the TCP sender decide to transmit a segment? Nagle s Algorithm: Waiting too long hurt interactive s (Telnet) Without waiting, risk of sending a bunch of tiny packets (silly window syndrome) Wait till timer expires: Self clocking: As long as TCP has any data in flight, sender receives an which can be used to trigger transmission If no data in flight, immediately send the segment (setting TCP_NoDElAY option) TCP Round Trip Time and Q: how to set TCP timeout value? longer than RTT but RTT varies too short: premature timeout unnecessary retransmissions too long: slow reaction to segment loss Q: how to estimate RTT? SampleRTT: measured time from segment transmission until receipt ignore retransmissions, why? SampleRTT will vary, want estimated RTT smoother average several recent measurements, not just current SampleRTT Csci 232 Computer Networks Transport Layer & TCP 65 Csci 232 Computer Networks Transport Layer & TCP 66 11

12 Round-trip Time Estimation Importance of accurate RTT estimators: Low RTT estimate unneeded retransmissions High RTT estimate poor throughput RTT estimator must adapt to change in RTT But not too fast, or too slow! Spurious timeouts Conservation of packets principle never more than a window worth of packets in flight Adaptive Retransmission (Original Algorithm) Measure SampleRTT for each segment/ pair Compute weighted running average of RTT EstRTT = α x EstimatedRTT + (1-α) x SampleRTT α between 0.8 and 0.9 ( to smooth Estimated RTT) - Small α indicates temp. fluctuation, a large value more stable, may not be quick to adapt to real changes Set timeout based on EstRTT TimeOut = 2 x EstRTT Csci 232 Computer Networks Transport Layer & TCP 67 Csci 232 Computer Networks Transport Layer & TCP 68 SampleR TT Sender Retransmission Ambiguity Original transmission Retransmission Receiver Sender Original transmission Receiver is for Original transmission but was for retransmission => Sample RTT is too large is for retransmission but was for original => Sample RTT too small SampleR TT Retransmission Karn/Partridge Algorithm Solution: Do not sample RTT when retransmitting only measures sample RTT for segments sent once Double timeout for each retransmission Next timeout to be twice the last timeout, rather than basing it on the last Estimated RTT Karn and Patridge proposal is exponential backoff Congestion is most likely cause of lost segments TCP sources should not react too aggressively to a timeout More timeouts mean more cautious the source should become (congestion problem) Csci 232 Computer Networks Transport Layer & TCP 69 Csci 232 Computer Networks Transport Layer & TCP 70 Jacobson/ Karels Algorithm Original computation for RTT did not take the variance of sample RTTs into account If variation among samples is small, Estimated RTT can be better used without increasing the estimate twice A large variance in the samples mean Time out values should not be too tightly coupled to the Estimated RTT New Calculations for average RTT Diff = SampleRTT - EstRTT EstRTT = EstRTT + ( δ x Diff) Dev = Dev + δ ( Diff - Dev) where δ is a fraction between 0 and 1 Consider variance when setting timeout value TimeOut = μ x EstRTT + φ x Dev where μ = 1 and φ = 4 TCP Round Trip Time Estimation EstimatedRTT = (1- α)*estimatedrtt + α*samplertt Exponential weighted moving average influence of past sample decreases exponentially fast typical value: α = Setting the timeout interval Estimted RTT plus safety margin large variation in EstimatedRTT -> larger safety margin safty margin : accommodate variations in estimatedrtt DevRTT = (1-β)*DevRTT + β* SampleRTT-EstimatedRTT (typically, β = 0.25) Interval = EstimatedRTT + 4*DevRTT Csci 232 Computer Networks Transport Layer & TCP 71 Csci 232 Computer Networks Transport Layer & TCP 72 12

13 Example RTT Estimation: RTT: gaia.cs.umass.edu to fantasia.eurecom.fr Timestamp Extension 350 RTT (milliseconds) time (seconnds) SampleRTT Estimated RTT Csci 232 Computer Networks Transport Layer & TCP 73 Used to improve timeout mechanism by more accurate measurement of RTT When sending a packet, insert current time into option 4 bytes for time, 4 bytes for echo a received timestamp Receiver echoes timestamp in Actually will echo whatever is in timestamp Removes retransmission ambiguity Can get RTT sample on any packet Csci 232 Computer Networks Transport Layer & TCP 74 Timer Granularity Many TCP implementations set RTO (Retransmission ) in multiples of 200,500,1000ms Why? Avoid spurious timeouts RTTs can vary quickly due to cross traffic Make timers interrupts efficient What happens for the first couple of packets? Pick a very conservative value (seconds) Important Lessons TCP state diagram setup/teardown TCP timeout calculation how is RTT estimated Modern TCP loss recovery Why are timeouts bad? How to avoid them? e.g. fast retransmit Csci 232 Computer Networks Transport Layer & TCP 75 Csci 232 Computer Networks Transport Layer & TCP 76 13

Outline. TCP connection setup/data transfer. 15-441 Computer Networking. TCP Reliability. Congestion sources and collapse. Congestion control basics

Outline. TCP connection setup/data transfer. 15-441 Computer Networking. TCP Reliability. Congestion sources and collapse. Congestion control basics Outline 15-441 Computer Networking Lecture 8 TCP & Congestion Control TCP connection setup/data transfer TCP Reliability Congestion sources and collapse Congestion control basics Lecture 8: 09-23-2002

More information

La couche transport dans l'internet (la suite TCP/IP)

La couche transport dans l'internet (la suite TCP/IP) La couche transport dans l'internet (la suite TCP/IP) C. Pham Université de Pau et des Pays de l Adour Département Informatique http://www.univ-pau.fr/~cpham Congduc.Pham@univ-pau.fr Cours de C. Pham,

More information

La couche transport dans l'internet (la suite TCP/IP)

La couche transport dans l'internet (la suite TCP/IP) La couche transport dans l'internet (la suite TCP/IP) C. Pham RESO-LIP/INRIA Université Lyon 1 http://www.ens-lyon.fr/~cpham Basé sur les transparent de Shivkumar Kalyanaraman La couche transport dans

More information

Transport Layer Protocols

Transport Layer Protocols Transport Layer Protocols Version. Transport layer performs two main tasks for the application layer by using the network layer. It provides end to end communication between two applications, and implements

More information

Transport Layer and Data Center TCP

Transport Layer and Data Center TCP Transport Layer and Data Center TCP Hakim Weatherspoon Assistant Professor, Dept of Computer Science CS 5413: High Performance Systems and Networking September 5, 2014 Slides used and adapted judiciously

More information

Computer Networks. Chapter 5 Transport Protocols

Computer Networks. Chapter 5 Transport Protocols Computer Networks Chapter 5 Transport Protocols Transport Protocol Provides end-to-end transport Hides the network details Transport protocol or service (TS) offers: Different types of services QoS Data

More information

Names & Addresses. Names & Addresses. Hop-by-Hop Packet Forwarding. Longest-Prefix-Match Forwarding. Longest-Prefix-Match Forwarding

Names & Addresses. Names & Addresses. Hop-by-Hop Packet Forwarding. Longest-Prefix-Match Forwarding. Longest-Prefix-Match Forwarding Names & Addresses EE 122: IP Forwarding and Transport Protocols Scott Shenker http://inst.eecs.berkeley.edu/~ee122/ (Materials with thanks to Vern Paxson, Jennifer Rexford, and colleagues at UC Berkeley)

More information

Computer Networks UDP and TCP

Computer Networks UDP and TCP Computer Networks UDP and TCP Saad Mneimneh Computer Science Hunter College of CUNY New York I m a system programmer specializing in TCP/IP communication protocol on UNIX systems. How can I explain a thing

More information

Higher Layer Protocols: UDP, TCP, ATM, MPLS

Higher Layer Protocols: UDP, TCP, ATM, MPLS Higher Layer Protocols: UDP, TCP, ATM, MPLS Massachusetts Institute of Technology Slide 1 The TCP/IP Protocol Suite Transmission Control Protocol / Internet Protocol Developed by DARPA to connect Universities

More information

Chapter 5. Transport layer protocols

Chapter 5. Transport layer protocols Chapter 5. Transport layer protocols This chapter provides an overview of the most important and common protocols of the TCP/IP transport layer. These include: User Datagram Protocol (UDP) Transmission

More information

TCP in Wireless Mobile Networks

TCP in Wireless Mobile Networks TCP in Wireless Mobile Networks 1 Outline Introduction to transport layer Introduction to TCP (Internet) congestion control Congestion control in wireless networks 2 Transport Layer v.s. Network Layer

More information

TCP Flow Control. TCP Receiver Window. Sliding Window. Computer Networks. Lecture 30: Flow Control, Reliable Delivery

TCP Flow Control. TCP Receiver Window. Sliding Window. Computer Networks. Lecture 30: Flow Control, Reliable Delivery TCP Flow Control Computer Networks The receiver side of a TCP connection maintains a receiver buffer: Lecture : Flow Control, eliable elivery application process may be slow at reading from the buffer

More information

ICOM 5026-090: Computer Networks Chapter 6: The Transport Layer. By Dr Yi Qian Department of Electronic and Computer Engineering Fall 2006 UPRM

ICOM 5026-090: Computer Networks Chapter 6: The Transport Layer. By Dr Yi Qian Department of Electronic and Computer Engineering Fall 2006 UPRM ICOM 5026-090: Computer Networks Chapter 6: The Transport Layer By Dr Yi Qian Department of Electronic and Computer Engineering Fall 2006 Outline The transport service Elements of transport protocols A

More information

B-2 Analyzing TCP/IP Networks with Wireshark. Ray Tompkins Founder of Gearbit www.gearbit.com

B-2 Analyzing TCP/IP Networks with Wireshark. Ray Tompkins Founder of Gearbit www.gearbit.com B-2 Analyzing TCP/IP Networks with Wireshark June 15, 2010 Ray Tompkins Founder of Gearbit www.gearbit.com SHARKFEST 10 Stanford University June 14-17, 2010 TCP In this session we will examine the details

More information

Transport Layer. Chapter 3.4. Think about

Transport Layer. Chapter 3.4. Think about Chapter 3.4 La 4 Transport La 1 Think about 2 How do MAC addresses differ from that of the network la? What is flat and what is hierarchical addressing? Who defines the IP Address of a device? What is

More information

TCP/IP Optimization for Wide Area Storage Networks. Dr. Joseph L White Juniper Networks

TCP/IP Optimization for Wide Area Storage Networks. Dr. Joseph L White Juniper Networks TCP/IP Optimization for Wide Area Storage Networks Dr. Joseph L White Juniper Networks SNIA Legal Notice The material contained in this tutorial is copyrighted by the SNIA. Member companies and individuals

More information

COMP 3331/9331: Computer Networks and Applications. Lab Exercise 3: TCP and UDP (Solutions)

COMP 3331/9331: Computer Networks and Applications. Lab Exercise 3: TCP and UDP (Solutions) COMP 3331/9331: Computer Networks and Applications Lab Exercise 3: TCP and UDP (Solutions) AIM To investigate the behaviour of TCP and UDP in greater detail. EXPERIMENT 1: Understanding TCP Basics Tools

More information

First Midterm for ECE374 03/09/12 Solution!!

First Midterm for ECE374 03/09/12 Solution!! 1 First Midterm for ECE374 03/09/12 Solution!! Instructions: Put your name and student number on each sheet of paper! The exam is closed book. You have 90 minutes to complete the exam. Be a smart exam

More information

q Connection establishment (if connection-oriented) q Data transfer q Connection release (if conn-oriented) q Addressing the transport user

q Connection establishment (if connection-oriented) q Data transfer q Connection release (if conn-oriented) q Addressing the transport user Transport service characterization The Transport Layer End-to-End Protocols: UDP and TCP Connection establishment (if connection-oriented) Data transfer Reliable ( TCP) Unreliable / best effort ( UDP)

More information

Lecture Objectives. Lecture 07 Mobile Networks: TCP in Wireless Networks. Agenda. TCP Flow Control. Flow Control Can Limit Throughput (1)

Lecture Objectives. Lecture 07 Mobile Networks: TCP in Wireless Networks. Agenda. TCP Flow Control. Flow Control Can Limit Throughput (1) Lecture Objectives Wireless and Mobile Systems Design Lecture 07 Mobile Networks: TCP in Wireless Networks Describe TCP s flow control mechanism Describe operation of TCP Reno and TCP Vegas, including

More information

[Prof. Rupesh G Vaishnav] Page 1

[Prof. Rupesh G Vaishnav] Page 1 Basics The function of transport layer is to provide a reliable end-to-end communications service. It also provides data transfer service for the user layers above and shield the upper layers from the

More information

Improving the Performance of TCP Using Window Adjustment Procedure and Bandwidth Estimation

Improving the Performance of TCP Using Window Adjustment Procedure and Bandwidth Estimation Improving the Performance of TCP Using Window Adjustment Procedure and Bandwidth Estimation R.Navaneethakrishnan Assistant Professor (SG) Bharathiyar College of Engineering and Technology, Karaikal, India.

More information

CSE331: Introduction to Networks and Security. Lecture 9 Fall 2006

CSE331: Introduction to Networks and Security. Lecture 9 Fall 2006 CSE33: Introduction to Networks and Security Lecture 9 Fall 2006 Announcements Project Due TODAY HW Due on Friday Midterm I will be held next Friday, Oct. 6th. Will cover all course material up to next

More information

Computer Networks - CS132/EECS148 - Spring 2013 ------------------------------------------------------------------------------

Computer Networks - CS132/EECS148 - Spring 2013 ------------------------------------------------------------------------------ Computer Networks - CS132/EECS148 - Spring 2013 Instructor: Karim El Defrawy Assignment 3 - Solutions Deadline : May 9 th 9:30pm (hard and soft copies required) ------------------------------------------------------------------------------

More information

Final for ECE374 05/06/13 Solution!!

Final for ECE374 05/06/13 Solution!! 1 Final for ECE374 05/06/13 Solution!! Instructions: Put your name and student number on each sheet of paper! The exam is closed book. You have 90 minutes to complete the exam. Be a smart exam taker -

More information

TCP over Multi-hop Wireless Networks * Overview of Transmission Control Protocol / Internet Protocol (TCP/IP) Internet Protocol (IP)

TCP over Multi-hop Wireless Networks * Overview of Transmission Control Protocol / Internet Protocol (TCP/IP) Internet Protocol (IP) TCP over Multi-hop Wireless Networks * Overview of Transmission Control Protocol / Internet Protocol (TCP/IP) *Slides adapted from a talk given by Nitin Vaidya. Wireless Computing and Network Systems Page

More information

Midterm Exam CMPSCI 453: Computer Networks Fall 2011 Prof. Jim Kurose

Midterm Exam CMPSCI 453: Computer Networks Fall 2011 Prof. Jim Kurose Midterm Exam CMPSCI 453: Computer Networks Fall 2011 Prof. Jim Kurose Instructions: There are 4 questions on this exam. Please use two exam blue books answer questions 1, 2 in one book, and the remaining

More information

This sequence diagram was generated with EventStudio System Designer (http://www.eventhelix.com/eventstudio).

This sequence diagram was generated with EventStudio System Designer (http://www.eventhelix.com/eventstudio). Client App Network Server App 25-May-13 15:32 (Page 1) This sequence diagram was generated with EventStudio System Designer (http://www.eventhelix.com/eventstudio). TCP is an end to end protocol which

More information

IP - The Internet Protocol

IP - The Internet Protocol Orientation IP - The Internet Protocol IP (Internet Protocol) is a Network Layer Protocol. IP s current version is Version 4 (IPv4). It is specified in RFC 891. TCP UDP Transport Layer ICMP IP IGMP Network

More information

Architecture and Performance of the Internet

Architecture and Performance of the Internet SC250 Computer Networking I Architecture and Performance of the Internet Prof. Matthias Grossglauser School of Computer and Communication Sciences EPFL http://lcawww.epfl.ch 1 Today's Objectives Understanding

More information

Mobile Communications Chapter 9: Mobile Transport Layer

Mobile Communications Chapter 9: Mobile Transport Layer Mobile Communications Chapter 9: Mobile Transport Layer Motivation TCP-mechanisms Classical approaches Indirect TCP Snooping TCP Mobile TCP PEPs in general Additional optimizations Fast retransmit/recovery

More information

Ethernet. Ethernet. Network Devices

Ethernet. Ethernet. Network Devices Ethernet Babak Kia Adjunct Professor Boston University College of Engineering ENG SC757 - Advanced Microprocessor Design Ethernet Ethernet is a term used to refer to a diverse set of frame based networking

More information

IP Network Layer. Datagram ID FLAG Fragment Offset. IP Datagrams. IP Addresses. IP Addresses. CSCE 515: Computer Network Programming TCP/IP

IP Network Layer. Datagram ID FLAG Fragment Offset. IP Datagrams. IP Addresses. IP Addresses. CSCE 515: Computer Network Programming TCP/IP CSCE 515: Computer Network Programming TCP/IP IP Network Layer Wenyuan Xu Department of Computer Science and Engineering University of South Carolina IP Datagrams IP is the network layer packet delivery

More information

TCP and Wireless Networks Classical Approaches Optimizations TCP for 2.5G/3G Systems. Lehrstuhl für Informatik 4 Kommunikation und verteilte Systeme

TCP and Wireless Networks Classical Approaches Optimizations TCP for 2.5G/3G Systems. Lehrstuhl für Informatik 4 Kommunikation und verteilte Systeme Chapter 2 Technical Basics: Layer 1 Methods for Medium Access: Layer 2 Chapter 3 Wireless Networks: Bluetooth, WLAN, WirelessMAN, WirelessWAN Mobile Networks: GSM, GPRS, UMTS Chapter 4 Mobility on the

More information

TCP Performance Management for Dummies

TCP Performance Management for Dummies TCP Performance Management for Dummies Nalini Elkins Inside Products, Inc. Monday, August 8, 2011 Session Number 9285 Our SHARE Sessions Orlando 9285: TCP/IP Performance Management for Dummies Monday,

More information

COMP 361 Computer Communications Networks. Fall Semester 2003. Midterm Examination

COMP 361 Computer Communications Networks. Fall Semester 2003. Midterm Examination COMP 361 Computer Communications Networks Fall Semester 2003 Midterm Examination Date: October 23, 2003, Time 18:30pm --19:50pm Name: Student ID: Email: Instructions: 1. This is a closed book exam 2. This

More information

TCP/IP Over Lossy Links - TCP SACK without Congestion Control

TCP/IP Over Lossy Links - TCP SACK without Congestion Control Wireless Random Packet Networking, Part II: TCP/IP Over Lossy Links - TCP SACK without Congestion Control Roland Kempter The University of Alberta, June 17 th, 2004 Department of Electrical And Computer

More information

TCP over Wireless Networks

TCP over Wireless Networks TCP over Wireless Networks Raj Jain Professor of Computer Science and Engineering Washington University in Saint Louis Saint Louis, MO 63130 Audio/Video recordings of this lecture are available at: http://www.cse.wustl.edu/~jain/cse574-10/

More information

Overview. Securing TCP/IP. Introduction to TCP/IP (cont d) Introduction to TCP/IP

Overview. Securing TCP/IP. Introduction to TCP/IP (cont d) Introduction to TCP/IP Overview Securing TCP/IP Chapter 6 TCP/IP Open Systems Interconnection Model Anatomy of a Packet Internet Protocol Security (IPSec) Web Security (HTTP over TLS, Secure-HTTP) Lecturer: Pei-yih Ting 1 2

More information

Simulation-Based Comparisons of Solutions for TCP Packet Reordering in Wireless Network

Simulation-Based Comparisons of Solutions for TCP Packet Reordering in Wireless Network Simulation-Based Comparisons of Solutions for TCP Packet Reordering in Wireless Network 作 者 :Daiqin Yang, Ka-Cheong Leung, and Victor O. K. Li 出 處 :Wireless Communications and Networking Conference, 2007.WCNC

More information

Chapter 6 Congestion Control and Resource Allocation

Chapter 6 Congestion Control and Resource Allocation Chapter 6 Congestion Control and Resource Allocation 6.3 TCP Congestion Control Additive Increase/Multiplicative Decrease (AIMD) o Basic idea: repeatedly increase transmission rate until congestion occurs;

More information

TCP/IP Networking for Wireless Systems. Integrated Communication Systems Group Ilmenau University of Technology

TCP/IP Networking for Wireless Systems. Integrated Communication Systems Group Ilmenau University of Technology TCP/IP Networking for Wireless Systems Integrated Communication Systems Group Ilmenau University of Technology Content Internet Protocol Suite Link Layer: Ethernet, PPP, ARP, MAC Addressing Network Layer:

More information

15-441: Computer Networks Homework 2 Solution

15-441: Computer Networks Homework 2 Solution 5-44: omputer Networks Homework 2 Solution Assigned: September 25, 2002. Due: October 7, 2002 in class. In this homework you will test your understanding of the TP concepts taught in class including flow

More information

Data Communications & Networks. Session 6 Main Theme Reliable Data Transfer. Dr. Jean-Claude Franchitti

Data Communications & Networks. Session 6 Main Theme Reliable Data Transfer. Dr. Jean-Claude Franchitti Data Communications & Networks Session 6 Main Theme Reliable Data Transfer Dr. Jean-Claude Franchitti New York University Computer Science Department Courant Institute of Mathematical Sciences Adapted

More information

SIP: Session Initiation Protocol

SIP: Session Initiation Protocol SIP: Session Initiation Protocol Comes from IETF (RFC 3261) SIP long-term vision All telephone calls and video conference calls take place over the Internet People are identified by names or e-mail addresses,

More information

Prefix AggregaNon. Company X and Company Y connect to the same ISP, and they are assigned the prefixes:

Prefix AggregaNon. Company X and Company Y connect to the same ISP, and they are assigned the prefixes: Data Transfer Consider transferring an enormous file of L bytes from Host A to B using a MSS of 1460 bytes and a 66 byte header. What is the maximum value of L such that TCP sequence numbers are not exhausted?

More information

Networking Overview. (as usual, thanks to Dave Wagner and Vern Paxson)

Networking Overview. (as usual, thanks to Dave Wagner and Vern Paxson) Networking Overview (as usual, thanks to Dave Wagner and Vern Paxson) Focus For This Lecture Sufficient background in networking to then explore security issues in next few lectures Networking = the Internet

More information

TCP for Wireless Networks

TCP for Wireless Networks TCP for Wireless Networks Outline Motivation TCP mechanisms Indirect TCP Snooping TCP Mobile TCP Fast retransmit/recovery Transmission freezing Selective retransmission Transaction oriented TCP Adapted

More information

Indian Institute of Technology Kharagpur. TCP/IP Part I. Prof Indranil Sengupta Computer Science and Engineering Indian Institute of Technology

Indian Institute of Technology Kharagpur. TCP/IP Part I. Prof Indranil Sengupta Computer Science and Engineering Indian Institute of Technology Indian Institute of Technology Kharagpur TCP/IP Part I Prof Indranil Sengupta Computer Science and Engineering Indian Institute of Technology Kharagpur Lecture 3: TCP/IP Part I On completion, the student

More information

Visualizations and Correlations in Troubleshooting

Visualizations and Correlations in Troubleshooting Visualizations and Correlations in Troubleshooting Kevin Burns Comcast kevin_burns@cable.comcast.com 1 Comcast Technology Groups Cable CMTS, Modem, Edge Services Backbone Transport, Routing Converged Regional

More information

Access Control: Firewalls (1)

Access Control: Firewalls (1) Access Control: Firewalls (1) World is divided in good and bad guys ---> access control (security checks) at a single point of entry/exit: in medieval castles: drawbridge in corporate buildings: security/reception

More information

Objectives of Lecture. Network Architecture. Protocols. Contents

Objectives of Lecture. Network Architecture. Protocols. Contents Objectives of Lecture Network Architecture Show how network architecture can be understood using a layered approach. Introduce the OSI seven layer reference model. Introduce the concepts of internetworking

More information

Network Layer: Network Layer and IP Protocol

Network Layer: Network Layer and IP Protocol 1 Network Layer: Network Layer and IP Protocol Required reading: Garcia 7.3.3, 8.1, 8.2.1 CSE 3213, Winter 2010 Instructor: N. Vlajic 2 1. Introduction 2. Router Architecture 3. Network Layer Protocols

More information

Computer Networks. Data Link Layer

Computer Networks. Data Link Layer Computer Networks The Data Link Layer 1 Data Link Layer Application Transport Network DLL PHY 2 What does it do? What functions it performs? Typically: Handling transmission errors, a.k.a., error control.

More information

A Survey on Congestion Control Mechanisms for Performance Improvement of TCP

A Survey on Congestion Control Mechanisms for Performance Improvement of TCP A Survey on Congestion Control Mechanisms for Performance Improvement of TCP Shital N. Karande Department of Computer Science Engineering, VIT, Pune, Maharashtra, India Sanjesh S. Pawale Department of

More information

High Speed Internet Access Using Satellite-Based DVB Networks

High Speed Internet Access Using Satellite-Based DVB Networks High Speed Internet Access Using Satellite-Based DVB Networks Nihal K. G. Samaraweera and Godred Fairhurst Electronics Research Group, Department of Engineering University of Aberdeen, Aberdeen, AB24 3UE,

More information

Networks: IP and TCP. Internet Protocol

Networks: IP and TCP. Internet Protocol Networks: IP and TCP 11/1/2010 Networks: IP and TCP 1 Internet Protocol Connectionless Each packet is transported independently from other packets Unreliable Delivery on a best effort basis No acknowledgments

More information

EITF25 Internet Techniques and Applications L5: Wide Area Networks (WAN) Stefan Höst

EITF25 Internet Techniques and Applications L5: Wide Area Networks (WAN) Stefan Höst EITF25 Internet Techniques and Applications L5: Wide Area Networks (WAN) Stefan Höst Data communication in reality In reality, the source and destination hosts are very seldom on the same network, for

More information

Digital Audio and Video Data

Digital Audio and Video Data Multimedia Networking Reading: Sections 3.1.2, 3.3, 4.5, and 6.5 CS-375: Computer Networks Dr. Thomas C. Bressoud 1 Digital Audio and Video Data 2 Challenges for Media Streaming Large volume of data Each

More information

CS 457 Lecture 19 Global Internet - BGP. Fall 2011

CS 457 Lecture 19 Global Internet - BGP. Fall 2011 CS 457 Lecture 19 Global Internet - BGP Fall 2011 Decision Process Calculate degree of preference for each route in Adj-RIB-In as follows (apply following steps until one route is left): select route with

More information

Congestion Control Review. 15-441 Computer Networking. Resource Management Approaches. Traffic and Resource Management. What is congestion control?

Congestion Control Review. 15-441 Computer Networking. Resource Management Approaches. Traffic and Resource Management. What is congestion control? Congestion Control Review What is congestion control? 15-441 Computer Networking What is the principle of TCP? Lecture 22 Queue Management and QoS 2 Traffic and Resource Management Resource Management

More information

Transport Layer Services Mul9plexing/Demul9plexing. Transport Layer Services

Transport Layer Services Mul9plexing/Demul9plexing. Transport Layer Services Computer Networks Mul9plexing/Demul9plexing Transport services and protocols provide logical communica+on between app processes running on different hosts protocols run in end systems send side: breaks

More information

Networking part 3: the transport layer

Networking part 3: the transport layer Networking part 3: the transport layer Juliusz Chroboczek Université de Paris-Diderot (Paris 7) September 2011 Summary of the previous episodes Episode 1: switching, packet switching and the Internet.

More information

Lecture 15: Congestion Control. CSE 123: Computer Networks Stefan Savage

Lecture 15: Congestion Control. CSE 123: Computer Networks Stefan Savage Lecture 15: Congestion Control CSE 123: Computer Networks Stefan Savage Overview Yesterday: TCP & UDP overview Connection setup Flow control: resource exhaustion at end node Today: Congestion control Resource

More information

2 TCP-like Design. Answer

2 TCP-like Design. Answer Homework 3 1 DNS Suppose you have a Host C, a local name server L, and authoritative name servers A root, A com, and A google.com, where the naming convention A x means that the name server knows about

More information

First Midterm for ECE374 03/24/11 Solution!!

First Midterm for ECE374 03/24/11 Solution!! 1 First Midterm for ECE374 03/24/11 Solution!! Note: In all written assignments, please show as much of your work as you can. Even if you get a wrong answer, you can get partial credit if you show your

More information

TCP Adaptation for MPI on Long-and-Fat Networks

TCP Adaptation for MPI on Long-and-Fat Networks TCP Adaptation for MPI on Long-and-Fat Networks Motohiko Matsuda, Tomohiro Kudoh Yuetsu Kodama, Ryousei Takano Grid Technology Research Center Yutaka Ishikawa The University of Tokyo Outline Background

More information

Transport layer protocols for ad hoc networks

Transport layer protocols for ad hoc networks Transport layer protocols for ad hoc networks Lecturer: Dmitri A. Moltchanov E-mail: moltchan@cs.tut.fi http://www.cs.tut.fi/kurssit/tlt-2616/ Which transport layer protocol? Classification of transport

More information

Transport Protocols and Distributed Applications

Transport Protocols and Distributed Applications Transport Protocols and Distributed Applications EP1100 Data Communications and Computer Networks Illustrations in this material are collected from Behrouz A Forouzan, Data Communications and Networking,

More information

TCP/IP Fundamentals. OSI Seven Layer Model & Seminar Outline

TCP/IP Fundamentals. OSI Seven Layer Model & Seminar Outline OSI Seven Layer Model & Seminar Outline TCP/IP Fundamentals This seminar will present TCP/IP communications starting from Layer 2 up to Layer 4 (TCP/IP applications cover Layers 5-7) IP Addresses Data

More information

RARP: Reverse Address Resolution Protocol

RARP: Reverse Address Resolution Protocol SFWR 4C03: Computer Networks and Computer Security January 19-22 2004 Lecturer: Kartik Krishnan Lectures 7-9 RARP: Reverse Address Resolution Protocol When a system with a local disk is bootstrapped it

More information

Application Level Congestion Control Enhancements in High BDP Networks. Anupama Sundaresan

Application Level Congestion Control Enhancements in High BDP Networks. Anupama Sundaresan Application Level Congestion Control Enhancements in High BDP Networks Anupama Sundaresan Organization Introduction Motivation Implementation Experiments and Results Conclusions 2 Developing a Grid service

More information

Computer Networks Practicum 2015

Computer Networks Practicum 2015 Computer Networks Practicum 2015 Vrije Universiteit Amsterdam, The Netherlands http://acropolis.cs.vu.nl/ spyros/cnp/ 1 Overview This practicum consists of two parts. The first is to build a TCP implementation

More information

How do I get to www.randomsite.com?

How do I get to www.randomsite.com? Networking Primer* *caveat: this is just a brief and incomplete introduction to networking to help students without a networking background learn Network Security. How do I get to www.randomsite.com? Local

More information

Chapter 11. User Datagram Protocol (UDP)

Chapter 11. User Datagram Protocol (UDP) Chapter 11 User Datagram Protocol (UDP) The McGraw-Hill Companies, Inc., 2000 1 CONTENTS PROCESS-TO-PROCESS COMMUNICATION USER DATAGRAM CHECKSUM UDP OPERATION USE OF UDP UDP PACKAGE The McGraw-Hill Companies,

More information

Recent advances in transport protocols

Recent advances in transport protocols Recent advances in transport protocols April 12, 2013 Abstract Transport protocols play a critical role in today s Internet. This chapter first looks at the evolution of the Internet s Transport Layer

More information

1. The subnet must prevent additional packets from entering the congested region until those already present can be processed.

1. The subnet must prevent additional packets from entering the congested region until those already present can be processed. Congestion Control When one part of the subnet (e.g. one or more routers in an area) becomes overloaded, congestion results. Because routers are receiving packets faster than they can forward them, one

More information

Chapter 3. TCP/IP Networks. 3.1 Internet Protocol version 4 (IPv4)

Chapter 3. TCP/IP Networks. 3.1 Internet Protocol version 4 (IPv4) Chapter 3 TCP/IP Networks 3.1 Internet Protocol version 4 (IPv4) Internet Protocol version 4 is the fourth iteration of the Internet Protocol (IP) and it is the first version of the protocol to be widely

More information

Low-rate TCP-targeted Denial of Service Attack Defense

Low-rate TCP-targeted Denial of Service Attack Defense Low-rate TCP-targeted Denial of Service Attack Defense Johnny Tsao Petros Efstathopoulos University of California, Los Angeles, Computer Science Department Los Angeles, CA E-mail: {johnny5t, pefstath}@cs.ucla.edu

More information

CSE 473 Introduction to Computer Networks. Exam 2 Solutions. Your name: 10/31/2013

CSE 473 Introduction to Computer Networks. Exam 2 Solutions. Your name: 10/31/2013 CSE 473 Introduction to Computer Networks Jon Turner Exam Solutions Your name: 0/3/03. (0 points). Consider a circular DHT with 7 nodes numbered 0,,...,6, where the nodes cache key-values pairs for 60

More information

Multipath TCP in Practice (Work in Progress) Mark Handley Damon Wischik Costin Raiciu Alan Ford

Multipath TCP in Practice (Work in Progress) Mark Handley Damon Wischik Costin Raiciu Alan Ford Multipath TCP in Practice (Work in Progress) Mark Handley Damon Wischik Costin Raiciu Alan Ford The difference between theory and practice is in theory somewhat smaller than in practice. In theory, this

More information

Secure SCTP against DoS Attacks in Wireless Internet

Secure SCTP against DoS Attacks in Wireless Internet Secure SCTP against DoS Attacks in Wireless Internet Inwhee Joe College of Information and Communications Hanyang University Seoul, Korea iwjoe@hanyang.ac.kr Abstract. The Stream Control Transport Protocol

More information

IP address format: Dotted decimal notation: 10000000 00001011 00000011 00011111 128.11.3.31

IP address format: Dotted decimal notation: 10000000 00001011 00000011 00011111 128.11.3.31 IP address format: 7 24 Class A 0 Network ID Host ID 14 16 Class B 1 0 Network ID Host ID 21 8 Class C 1 1 0 Network ID Host ID 28 Class D 1 1 1 0 Multicast Address Dotted decimal notation: 10000000 00001011

More information

Per-Flow Queuing Allot's Approach to Bandwidth Management

Per-Flow Queuing Allot's Approach to Bandwidth Management White Paper Per-Flow Queuing Allot's Approach to Bandwidth Management Allot Communications, July 2006. All Rights Reserved. Table of Contents Executive Overview... 3 Understanding TCP/IP... 4 What is Bandwidth

More information

17: Queue Management. Queuing. Mark Handley

17: Queue Management. Queuing. Mark Handley 17: Queue Management Mark Handley Queuing The primary purpose of a queue in an IP router is to smooth out bursty arrivals, so that the network utilization can be high. But queues add delay and cause jitter.

More information

Internet Protocols. Background CHAPTER

Internet Protocols. Background CHAPTER CHAPTER 3 Internet Protocols Background The Internet protocols are the world s most popular open-system (nonproprietary) protocol suite because they can be used to communicate across any set of interconnected

More information

What is a DoS attack?

What is a DoS attack? CprE 592-YG Computer and Network Forensics Log-based Signature Analysis Denial of Service Attacks - from analyst s point of view Yong Guan 3216 Coover Tel: (515) 294-8378 Email: guan@ee.iastate.edu October

More information

Data Networks Summer 2007 Homework #3

Data Networks Summer 2007 Homework #3 Data Networks Summer Homework # Assigned June 8, Due June in class Name: Email: Student ID: Problem Total Points Problem ( points) Host A is transferring a file of size L to host B using a TCP connection.

More information

A Survey: High Speed TCP Variants in Wireless Networks

A Survey: High Speed TCP Variants in Wireless Networks ISSN: 2321-7782 (Online) Volume 1, Issue 7, December 2013 International Journal of Advance Research in Computer Science and Management Studies Research Paper Available online at: www.ijarcsms.com A Survey:

More information

Introduction to TCP/IP

Introduction to TCP/IP Introduction to TCP/IP Raj Jain The Ohio State University Columbus, OH 43210 Nayna Networks Milpitas, CA 95035 Email: Jain@ACM.Org http://www.cis.ohio-state.edu/~jain/ 1 Overview! Internetworking Protocol

More information

Protocols. Packets. What's in an IP packet

Protocols. Packets. What's in an IP packet Protocols Precise rules that govern communication between two parties TCP/IP: the basic Internet protocols IP: Internet Protocol (bottom level) all packets shipped from network to network as IP packets

More information

TCP, Active Queue Management and QoS

TCP, Active Queue Management and QoS TCP, Active Queue Management and QoS Don Towsley UMass Amherst towsley@cs.umass.edu Collaborators: W. Gong, C. Hollot, V. Misra Outline motivation TCP friendliness/fairness bottleneck invariant principle

More information

Protocols and Architecture. Protocol Architecture.

Protocols and Architecture. Protocol Architecture. Protocols and Architecture Protocol Architecture. Layered structure of hardware and software to support exchange of data between systems/distributed applications Set of rules for transmission of data between

More information

Transport layer issues in ad hoc wireless networks Dmitrij Lagutin, dlagutin@cc.hut.fi

Transport layer issues in ad hoc wireless networks Dmitrij Lagutin, dlagutin@cc.hut.fi Transport layer issues in ad hoc wireless networks Dmitrij Lagutin, dlagutin@cc.hut.fi 1. Introduction Ad hoc wireless networks pose a big challenge for transport layer protocol and transport layer protocols

More information

8.2 The Internet Protocol

8.2 The Internet Protocol TCP/IP Protocol Suite HTTP SMTP DNS RTP Distributed applications Reliable stream service TCP UDP User datagram service Best-effort connectionless packet transfer Network Interface 1 IP Network Interface

More information

First Midterm for ECE374 02/25/15 Solution!!

First Midterm for ECE374 02/25/15 Solution!! 1 First Midterm for ECE374 02/25/15 Solution!! Instructions: Put your name and student number on each sheet of paper! The exam is closed book. You have 90 minutes to complete the exam. Be a smart exam

More information

Sources: Chapter 6 from. Computer Networking: A Top-Down Approach Featuring the Internet, by Kurose and Ross

Sources: Chapter 6 from. Computer Networking: A Top-Down Approach Featuring the Internet, by Kurose and Ross Multimedia Communication Multimedia Systems(Module 5 Lesson 2) Summary: H Internet Phone Example Making the Best use of Internet s Best-Effort Service. Sources: H Chapter 6 from Computer Networking: A

More information

CPS221 Lecture: Layered Network Architecture

CPS221 Lecture: Layered Network Architecture CPS221 Lecture: Layered Network Architecture Objectives last revised 9/10/12 1. To discuss the OSI layered architecture model 2. To discuss the specific implementation of this model in TCP/IP Materials:

More information

TCP/IP Inside the Data Center and Beyond. Dr. Joseph L White, Juniper Networks

TCP/IP Inside the Data Center and Beyond. Dr. Joseph L White, Juniper Networks Dr. Joseph L White, Juniper Networks SNIA Legal Notice The material contained in this tutorial is copyrighted by the SNIA. Member companies and individual members may use this material in presentations

More information

Configuring TCP Intercept (Preventing Denial-of-Service Attacks)

Configuring TCP Intercept (Preventing Denial-of-Service Attacks) Configuring TCP Intercept (Preventing Denial-of-Service Attacks) This chapter describes how to configure your router to protect TCP servers from TCP SYN-flooding attacks, a type of denial-of-service attack.

More information