DOC PREVIEW
Berkeley ELENG 122 - Transport Protocols

This preview shows page 1-2-3-26-27-28 out of 28 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
View full document
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 28 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

EE 122: Transport ProtocolsMotivationTransport ProtocolUDPTCPHeadersIP HeaderFragmentationFragmentation IssuesUDP HeaderPort AddressingTCP HeaderTCP ChallengesConnection Establishment: How it worksThree-way Handshake: RationaleMore RationaleEven More RationaleFlow control: Window Size and ThroughputEffective Window SizeAdvertised Window = 0Silly Window Syndrome (SWS)SWS SolutionSet timeoutRTT EstimationProblemKarn/Partridge AlgorithmJacobson/Karels AlgorithmSummaryEE 122: Transport ProtocolsKevin LaiOctober 16, [email protected] 2Motivation IP provides a weak, but efficient service model (best-effort)- packets can be delayed, dropped, reordered, duplicated- packets have limited size (why?) IP packets are addressed to a host- how to decide which application gets which packets? How should hosts send into the network?- every sends as fast as they can → drop many packets, network is under-utilized (congestion collapse)[email protected] 3Transport ProtocolLink LayerPhysical LayerNetworking LayerTransport Layer Provides more than the underlying network protocol- more reliability, in order delivery, at most once delivery- supports messages of arbitrary length- provide a way to decide which packets go to which applications (multiplexing/demultiplexing)- govern how hosts should send data to prevent congestion collapse (congestion control and avoidance)TCP/[email protected] 4UDP User Datagram Protocol minimalistic transport protocol same best-effort service model as IP messages can be larger than one packet, but still limited (64KB)- uses fragmentation provides multiplexing/demultiplexing to IP does not provide congestion control advantage over TCP: does not increase end-to-end delay over IP application example: video/audio [email protected] 5TCP Transmission Control Protocol reliable, in-order, and at most once delivery messages can be of arbitrary length provides multiplexing/demultiplexing to IP provides congestion control and avoidance increases end-to-end delay over IP e.g., file transfer, [email protected] 6Headers IP header Æ used for IP routing, fragmentation, error detection… UDP header Æ used for multiplexing/demultiplexing, error detection TCP header Æ used for multiplexing/demultiplexing, flow and congestion control IPTCP UDPdatadataApplicationSenderdataIPTCP UDPApplicationReceiverdatadataTCP/UDPIPdataTCP/UDP TCP/UDPIP TCP/[email protected] 7IP HeaderComments- HLen – header length only in 32-bit words (5 <= HLen <= 15)- TOS (Type of Service): Differentiated Service (6 bits) Explicit Congestion Notification (ECN) (2 bits)- Length – the length of the entire datagram/segment; header + data- Flags: Don’t Fragment (DF) and More Fragments (MF)- Protocol: identifies the transport protocol- Header checksum - uses 1’s complement Version HLenTOS LengthIdentificationFragment offsetFlagsSource addressDestination addressTTL Protocol Header checksum04 8 16 19 31Options (variable)Payload20 [email protected] 8Fragmentation What happens if router has to forward an IP packet that is larger than allowed by a data link layer? Break the IP packet into smaller IP packets and provide a way to reassemble- set “more fragments” bit in all fragments but last- set the fragment offset of fragment to be offset (in 8-byte offsets) from beginning of original packet- set the packet len to be length of this [email protected] 9Fragmentation Issues Sending host had better be changing the IP ID Loose one fragment, loose them all Reassembly is complex- requires per packet state Only reassemble at destination Fragmentation can be avoided using Path Maximum Transmission Unit Discovery (PMTU)- most TCP implementations use [email protected] 10UDP HeaderSource portDestination port016 31UDP length UDP checksumPayload (variable) Source and destination ports use port address space UDP length is UDP packet length (including UDP header and payload, but not IP header) Optional UDP checksum is over UDP packet- why have UDP checksum in addition to IP checksum?- why not have just the UDP checksum?- why is the UDP checksum [email protected] 11Port Addressing Need to decide which application gets which packetsSolution: map each socket to a portClient must know server’s portseparate 16-bit port address space for UDP and TCP- (src IP, src port, dst IP, dst port) uniquely identifies TCP connectionWell known ports(0-1023): everyone agrees which services run on these ports- e.g., ssh:22, http:80- on UNIX, must be root to gain access to these ports (why?)ephemeral ports(most 1024-65535): given to clients- e.g. chatclient gets one of [email protected] 12TCP HeaderSource portDestination portOptions (variable)Sequence numberAcknowledgementAdvertised windowChecksum Urgent pointerFlagsHdrLen0 4 10 16 31Payload (variable)Sequence number, acknowledgement, and advertised window –used by sliding-window based flow controlFlags:- SYN, FIN – establishing/terminating a TCP connection- ACK – set when Acknowledgement field is valid- URG – urgent data; Urgent Pointer says where non-urgent data starts- PUSH – don’t wait to fill segment- RESET – abort [email protected] 13TCP Challengeshow to provide reliable, in-order, and at most once delivery? (sliding window)need to synchronize sender and receiver (connection establishment)- e.g., exchange initial sequence numbersprevent sender from sending too fast for receiver (flow control)estimate RTT for flow control and timeoutshow to initially decide on sending rate (slow start)estimate how much bandwidth is available in network (congestion avoidance)slow down sending rate when we were sending too fast (congestion control)[email protected] 14Connection Establishment: How it worksThree-way handshake- Goal: agree on a set of parameters: the start sequence number for each side- Starting sequence numbers are random.ServerClient (initiator)ActiveOpenSYN and ACK, SeqNum = y and Ack = xconnect() listen()SYN, SeqNum= xPassiveOpenaccept() + 1ACK, Ack= y + 1allocatebuffer [email protected] 15Three-way Handshake: Rationale Three-way handshare adds 1 RTT delay  Why not just start sending data immediately?- congestion control• network could be congested• SYN = 40 bytes, Data < 1500 bytes• packets which are dropped at a


View Full Document

Berkeley ELENG 122 - Transport Protocols

Documents in this Course
Lecture 6

Lecture 6

22 pages

Wireless

Wireless

16 pages

Links

Links

21 pages

Ethernet

Ethernet

10 pages

routing

routing

11 pages

Links

Links

7 pages

Switches

Switches

30 pages

Multicast

Multicast

36 pages

Switches

Switches

18 pages

Security

Security

16 pages

Switches

Switches

18 pages

Lecture 1

Lecture 1

56 pages

OPNET

OPNET

5 pages

Lecture 4

Lecture 4

16 pages

Ethernet

Ethernet

65 pages

Models

Models

30 pages

TCP

TCP

16 pages

Wireless

Wireless

48 pages

Load more
Download Transport Protocols
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Transport Protocols and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Transport Protocols 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?