26-TCP Dr. John P. Abraham Professor UTPA. TCP  Transmission control protocol, another transport layer protocol.  Reliable delivery  Tcp must compensate.

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

© 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints.
© 2007 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets with Internet Applications, 4e By Douglas.
CSCI 4550/8556 Computer Networks
Transmission Control Protocol (TCP)
Intermediate TCP/IP TCP Operation.
1 TCP - Part I Relates to Lab 5. First module on TCP which covers packet format, data transfer, and connection management.
Chapter 7 – Transport Layer Protocols
UNIT 07 Process – to – Process Delivery: UDP,TCP and SCTP
Computer Networks Transport Layer. Topics F Introduction  F Connection Issues F TCP.
Department of Electronic Engineering City University of Hong Kong EE3900 Computer Networks Transport Protocols Slide 1 Transport Protocols.
TCP. Learning objectives Reliable Transport in TCP TCP flow and Congestion Control.
Ch 23 Ameera Almasoud Based on Data Communications and Networking, 4th Edition. by Behrouz A. Forouzan, McGraw-Hill Companies, Inc., 2007.
WXES2106 Network Technology Semester /2005 Chapter 8 Intermediate TCP CCNA2: Module 10.
Error Checking continued. Network Layers in Action Each layer in the OSI Model will add header information that pertains to that specific protocol. On.
Process-to-Process Delivery:
Gursharan Singh Tatla Transport Layer 16-May
What Can IP Do? Deliver datagrams to hosts – The IP address in a datagram header identify a host IP treats a computer as an endpoint of communication Best.
Process-to-Process Delivery:
TRANSPORT LAYER T.Najah Al-Subaie Kingdom of Saudi Arabia Prince Norah bint Abdul Rahman University College of Computer Since and Information System NET331.
1 Chapter Internetworking Part 4 (Transport Protocols, UDP and TCP, Protocol Port Numbers)
1 Transport Layer Computer Networks. 2 Where are we?
CECS 474 Computer Network Interoperability Notes for Douglas E. Comer, Computer Networks and Internets (5 th Edition) Tracy Bradley Maples, Ph.D. Computer.
IP and Errors IP Best Effort Datagrams can be: –Lost –Delayed –Duplicated –Delivered out of order –Corrupted.
TCP : Transmission Control Protocol Computer Network System Sirak Kaewjamnong.
TCP Lecture 13 November 13, TCP Background Transmission Control Protocol (TCP) TCP provides much of the functionality that IP lacks: reliable service.
University of the Western Cape Chapter 12: The Transport Layer.
SMUCSE 4344 transport layer. SMUCSE 4344 transport layer end-to-end protocols –transport code runs only on endpoint hosts encapsulates network communications.
Section 5: The Transport Layer. 5.2 CS Computer Networks John Mc Donald, Dept. of Computer Science, NUI Maynooth. Introduction In the previous section.
FALL 2005CSI 4118 – UNIVERSITY OF OTTAWA1 Part 2.5 Internetworking Chapter 25 (Transport Protocols, UDP and TCP, Protocol Port Numbers)
TCP1 Transmission Control Protocol (TCP). TCP2 Outline Transmission Control Protocol.
Transport Layer Moving Segments. Transport Layer Protocols Provide a logical communication link between processes running on different hosts as if directly.
Chapter 12 Transmission Control Protocol (TCP)
Transport Control Protocol (TCP) Features of TCP, packet loss and retransmission, adaptive retransmission, flow control, three way handshake, congestion.
1 TCP: Reliable Transport Service. 2 Transmission Control Protocol (TCP) Major transport protocol used in Internet Heavily used Completely reliable transfer.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2000 Chapter 12 Transmission Control Protocol (TCP)
McGraw-Hill©The McGraw-Hill Companies, Inc., 2000 Transmission Control Protocol (TCP)
23.1 Chapter 23 Process-to-Process Delivery: UDP, TCP, and SCTP Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Copyright © Lopamudra Roychoudhuri
Institute of Technology Sligo - Dept of Computing Chapter 12 The Transport Layer.
Chapter 24 Transport Control Protocol (TCP) Layer 4 protocol Responsible for reliable end-to-end transmission Provides illusion of reliable network to.
Computer Networks23-1 PART 5 Transport Layer. Computer Networks23-2 Position of Transport Layer Responsible for the delivery of a message from one process.
Transmission Control Protocol (TCP) BSAD 146 Dave Novak Sources: Network+ Guide to Networks, Dean 2013.
ECE 4110 – Internetwork Programming
McGraw-Hill©The McGraw-Hill Companies, Inc., 2000 Chapter 12 Transmission Control Protocol (TCP)
1 End-to-End Protocols User Datagram Protocol (UDP) Transmission Control Protocol(TCP)
4343 X2 – The Transport Layer Tanenbaum Ch.6.
IP1 The Underlying Technologies. What is inside the Internet? Or What are the key underlying technologies that make it work so successfully? –Packet Switching.
1 Computer Communication & Networks Lecture 23 & 24 Transport Layer: UDP and TCP Waleed Ejaz
McGraw-Hill Chapter 23 Process-to-Process Delivery: UDP, TCP Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
TCP/IP1 Address Resolution Protocol Internet uses IP address to recognize a computer. But IP address needs to be translated to physical address (NIC).
3. END-TO-END PROTOCOLS (PART 1) Rocky K. C. Chang Department of Computing The Hong Kong Polytechnic University 22 March
1 Chapter 24 Internetworking Part 4 (Transport Protocols, UDP and TCP, Protocol Port Numbers)
Ch23 Ameera Almasoud 1 Based on Data Communications and Networking, 4th Edition. by Behrouz A. Forouzan, McGraw-Hill Companies, Inc., 2007.
Chapter 15 Transmission Control Protocol (TCP)
5. End-to-end protocols (part 1)
Transport Layer.
Process-to-Process Delivery, TCP and UDP protocols
PART 5 Transport Layer Computer Networks.
Introduction of Transport Protocols
Process-to-Process Delivery:
Dr. John P. Abraham Professor UTPA
Dr. John P. Abraham Professor UTPA
PART V Transport Layer.
Process-to-Process Delivery: UDP, TCP
Computer Networks Protocols
Error Checking continued
Transport Layer 9/22/2019.
Presentation transcript:

26-TCP Dr. John P. Abraham Professor UTPA

TCP  Transmission control protocol, another transport layer protocol.  Reliable delivery  Tcp must compensate for loss, delay, duplication and out of order delivery that are introduced by IP.  Packet in TCP is called a segment

Service provided to applications  Connection orientation  Point-to-point (end to end)  Reliability  Full duplex  Stream interface  Reliable connection startup and gracefull connection shutdown

Virtual connections  End-to-end provides service to application from end to the other.  Virtual connection is established. Virtual connection is achieved by the software (underlying hardware does not have a real connection between the two points). The tcp software on the two machines exchange messages to achieve the connection.  Uses IP to carry the data.

Table 12.1 Well-known ports used by TCP

Figure 12.2 Stream delivery

Figure 12.3 Sending and receiving buffers

Sequencing to handle duplicates and out of order delivery  The sending side attaches a sequence number to each packets. The bytes of data being transferred in each connection are numbered by TCP. The numbering starts with a randomly generated number.  The receiving side stores both the sequence number of the last packet arrived in order as well as a list of additional packets that arrived out of order.  If packet arrived in order it hands it to the higher layer and checks the pending out of order list, if any can be handed to the higher layer.  If packet arrived out of order, it adds it to the out of order list.  If a duplicate arrived (below the current sequence number, or already in the out of order list) it is discarded.

Suppose a TCP connection is transferring a file of 5000 bytes. The first byte is numbered What are the sequence numbers for each segment if data is sent in five segments, each carrying 1000 bytes? Example 2 Solution The following shows the sequence number for each segment: Segment 1 ➡ Sequence Number: 10,001 (range: 10,001 to 11,000) Segment 2 ➡ Sequence Number: 11,001 (range: 11,001 to 12,000) Segment 3 ➡ Sequence Number: 12,001 (range: 12,001 to 13,000) Segment 4 ➡ Sequence Number: 13,001 (range: 13,001 to 14,000) Segment 5 ➡ Sequence Number: 14,001 (range: 14,001 to 15,000)

Retransmission to handle lost packets To handle packet lost tcp uses positive acknowledgement with retransmission. Whenever a frame arrives intact, the receiving protocol sends a small ACK that repots successful reception. When a packet is sent the sending side starts a timer. If the ACK is not received before the timer ends the packet is re- transmitted. If an ACK is received for a later packet, all packets upto that point is considered ACKed.

Connection establishment using three-way handshaking

Acknowledgement field The value in the sequence number field of a segment defines the number of the first data byte contained in that segment.  The value of the acknowledgment field in a segment defines the number of the next byte a party expects to receive.  The acknowledgment number is cumulative.

Selective ACK  Relying purely on the cumulative acknowledgment scheme employed by the original TCP protocol can lead to inefficiencies when packets are lost. For example, suppose 10,000 bytes are sent in 10 different TCP packets, and the first packet is lost during transmission. In a pure cumulative acknowledgment protocol, the receiver cannot say that it received bytes 1,000 to 9,999 successfully, but failed to receive the first packet, containing bytes 0 to 999. Thus the sender may then have to resend all 10,000 bytes.  In order to solve this problem TCP employs the selective acknowledgment (SACK) option, defined in RFC 2018, which allows the receiver to acknowledge discontinuous blocks of packets that were received correctly

Flow control to prevent data overrun  Covered sliding window already.  A sliding window is used to make transmission more efficient as well as to control the flow of data so that the destination does not become overwhelmed with data.  TCP’s sliding windows are byte oriented.

Techniques to avoid congestion  When transmission exceeds the capacity of a receiving device (usually router), we have congestion.  Retransmission can only worsen the situation, may lead to congestion collapse.  To avoid this routers inform senders about congestion. Congestion is estimated based on packet delays and packet losses.  A reduced window size is sent to the sender. A size of 0 means, do not send any more.  If a receiver can’t handle received data, it will begin to reduce its window size. If this is repeated to the point that the header is more that the payload, a situation called “silly window syndrome” occurs.

Three-way and shake  To guarantee that connections are established or terminated reliably.  3 messages are exchanged, each side sends a control message that specifies an initial buffer size and a sequence number.  Send syn  receive syn  send back syn + ack  receve syn+ack and send ack  receive ack.  To close a connection send fin+ack  receive it and send fin+ack  receive it and send ack  receive ack.

3-way-handshake Handshake segments cannot carry data, but consumes sequence numbers.

termination