If part of message is lost or garbled, you only have to resend the affected packet(s)
Speed
Store-and-forward delay is minimized
A can send packet 1 to B while receiving packet 2 from S
Not possible if whole message sent at once
TCP Protocol: Guaranteed Delivery
Error Detection on TCP Packets
Checksum detects if IP packet is corrupt
E.g., parity check: even or odd number of 1s in payload
If error detected, discard packet
Sender remembers packets it sent
Receiver ACKs each packet received
Clever optimization: piggyback ACK to data packet already flowing other direction
If ACK not received within a specified timeout interval, the sender resends packet
Receiver may get two copies!
Just ignore the second one
TCP Guaranteed Delivery Demo
Same as before, except
The sender will retransmit if ACK not received within the timeout interval
When packet reaches destination, receiver must acknowledge by telling the class the sequence number of the packet received
The TCP header includes error checking information.
Identifying A Connection: Another Use Of TCP Ports
Each side of a TCP connection is referred to as a socket, and can be identified by the IP address and port
A logical connection between a source and destination host is uniquely identified by the two sockets involved
TCP Congestion
If a router is overworked
Its queues fill up
It drops additional packets
Because TCP provides guaranteed delivery through ACK, the source clients resend the packets
Even more congestion
Flow Control
Similar to congestion, but not due to network interference
Destination host’s own traffic is too much
Destination unable to receive so fast
TCP flow control implementation is similar to solution for congestion control
Receiver can explicitly request lower send rate in ACKs
Summary of TCP/IP
IP
Best-effort delivery to remote destination
Globally unique addresses
Routers forward to next hop
TCP
Message fragmentation and reassembly
Guaranteed delivery
Sessions
Port numbers
Congestion and flow control
Commercial Provision of TCP/IP
Internet Access Providers (IAPs)
Customers connect computer or network to IAP (ISP)
IAP connects to rest of the Internet
Routes may involve intermediate transit carriers
Transit traffic = neither source nor destination address is a direct customer of the carrier
Interconnection between transit carriers
Peering
NAPs (multilateral peering between IAPs)
Paid interconnects (small providers to big ones that carry lots of transit traffic)
Usually flat rate based on maximum bitrate, not actual bitrate of transfers
No comments:
Post a Comment