+ All Categories
Home > Documents > Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First...

Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First...

Date post: 30-May-2020
Category:
Upload: others
View: 2 times
Download: 0 times
Share this document with a friend
17
Lecture 2: Links and Signaling CSE 123: Computer Networks Aaron Schulman DISCUSSION @2pm Friday
Transcript
Page 1: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Lecture 2:Links and Signaling

CSE 123: Computer NetworksAaron Schulman

DISCUSSION @2pm Friday

Page 2: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Our Problem! Communications is complicated

u Modulation and encoding bitsu Splitting sequences of bits into packetsu Fixing errorsu Controlling access to networku Routingu Recovering from lost messagesu Etc….

! Really hard to think about all of this and get it right! Not all applications need all of it! How to achieve interoperability?

2CSE 123 – Lecture 2: Layers & Framing

Page 3: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Layering: A Modular Approach! Sub-divide the problem

u Each layer relies on services from layer below u Each layer exports services to layer above

! Interface between layers defines interactionu Hides implementation details (encapsulation)u Layers can change without disturbing other layers (modularity)

! Interface among peers in a layer is a protocolu If peers speak same protocol, they can interoperate

3CSE 123 – Lecture 2: Layers & Framing

Page 4: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Protocol Standardization! Communicating hosts speaking the same protocol

u Standardization to enable multiple implementationsu Or, the same folks have to write all the software

! Internet Engineering Task Forceu Based on working groups that focus on specific issuesu Produces “Request For Comments” (RFCs)

» Rough consensus and running code» After enough time passes, promoted to Internet Standards

! Other standards bodies existu ISO, ITU, IEEE, etc.

4CSE 123 – Lecture 2: Layers & Framing

Page 5: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Key Design Decision! How do you divide functionality across the layers?

! End-to-end argument [Saltzer84]u Functionality should be implemented at a lower layer iff it can

be correctly and completely implemented thereu Incomplete versions of a function can be used as a

performance enhancement, but not for correctness! Early, and still relevant, example

u ARPAnet provided reliable link transfers between switchesu Was this enough for reliable communication?u No, packets could still get corrupted on host-switch link, or

inside of the switchesu Hence, still need reliability at higher layers

5CSE 123 – Lecture 2: Layers & Framing

Page 6: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

TCP/IP Protocol Stack

HTTP

TCP

IP

Ethernetinterface

HTTP

TCP

IP

Ethernetinterface

IP IP

Ethernetinterface

Ethernetinterface

SONETinterface

SONETinterface

host host

router router

6

Application Layer

Transport Layer

Link Layer

CSE 123 – Lecture 2: Layers & Framing

Network Layer

We will start the class here

Page 7: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Encapsulation via Headers

! Typical packet in Web transfer

! Notice that layers add overheadu Space (headers), effective bandwidthu Time (processing headers, “peeling the onion”), latency

IP Hdr Payload (Web object)TCP Hdr HTTP HdrEthernet Hdr

Start of packet End of packetdatalink network transport application

7CSE 123 – Lecture 2: Layers & Framing

Page 8: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Data Link

Physical

Applications

The Hourglass Model

“Thin Waist”

FTP HTTP TFTPNV

TCP UDP

IP

NET1 NET2 NETn…

8

Transport

Internet Protocol Suite

CSE 123 – Lecture 2: Layers & Framing

The success of the Internet (and its problems) can largely be attributed to the “thin waist”

A variety of applications

…on a variety of networks

Page 9: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Later: Phy/(MAC)Link layer! Signal encoding

u Encode binary data from source node into signals that physical links carry

u Signal is decoded back into binary data at receiving nodeu Work performed by network adapter at sender and receiver

! Media accessu Arbitrate which nodes can send frames at any point in timeu Not always necessary; e.g. point-to-point duplex links

9CSE 123 – Lecture 2: Layers & Framing

Page 10: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

For now: (Data) Link Layer! Framing

u Break stream of bits up into discrete chunks

! Error handlingu Detect and/or correct errors in received frames

! Multiplexingu Determine appropriate destination for a given frameu Also not always required; again, point-to-point

10CSE 123 – Lecture 2: Layers & Framing

Page 11: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Today’s Focus: FramingBreak down a stream of bits into smaller, digestible chunks called frames

! Identifies the beginning and end of a piece of information

! Allows the link to be sharedu Multiple senders and/or receivers can time multiplex the link

» One frame sent at a timeu Each frame can be separately addressed

! Provides manageable unit for error handlingu Easy to determine whether something went wrongu And perhaps even to fix it if desired

11CSE 123 – Lecture 2: Layers & Framing

Page 12: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Where is the beginning/end?010010010010000001110100011010000110100101101110011010110010000001110100011010000110000101110100001000000100100100100000011100110110100001100001011011000110110000100000011011100110010101110110011001010111001000100000011100110110010101100101000101001000001001000000110011101110010011000010111000001101000001000000110110101101111011100100110010100100000011011000110111101110110011001010110110001111001001000000111010001101000011000010110111000100000011000010010000001110100011100100110010101100101001011100001010010000010010000001110100011100100110010101100101001000000111011101101000011011110111001101100101001000000110001101110010011101010110001101101001011000010110110000100000011100000111001001101111011100000110010101110010011101000111100100010100100100101110011001000000110110001101111011011110111000000101101011001100111001001100101011001010010000001100011011011110110111001101110011001010110001101110100011010010111011001101001011101000111100100101110000101001000001001000000111010001110010011001010110010100100000011101000110100001100001011101000010000001101101011101010111001101110100001000000110001001100101001000000111001101110101011100100110010100100000011101000110111100100000011100110111000001100001011011100001010010100110110111100100000011100000110000101100011011010110110010101110100011100110010000001100011011000010110111000100000011100100110010101100001011000110110100000100000011001010111011001100101011100100111100100100000010011000100000101001110001011100001010010001100110100101110010011100110111010000101100001000000111010001101000011001010010000001110010011011110110111101110100001000000110110101110101011100110111010000100000011000100110010100100000011100110110010101101100011001010110001101110100011001010110010000101110000101001000010011110010010000001001001010001000010110000100000011010010111010000100000011010010111001100100000011001010110110001100101011000110111010001100101011001000010111000010100100110001100101011000010111001101110100001011010110001101101111011100110111010000100000011100000110000101110100011010000111001100100000011001100111001001101111011011010010000001110010011011110110111101110100001000000110000101110010011001010010000001110100011100100110000101100011011001010110010000101110000101001001001011011100010000001110100011010000110010100100000011101000111001001100101011001010010110000100000011101000110100001100101011100110110010100100000011100000110000101110100011010000111001100100000011000010111001001100101001000000111000001101100011000010110001101100101011001000010111000010100100000100100000011011010110010101110011011010000010000001101001011100110010000001101101011000010110010001100101001000000110001001111001001000000110011001101111011011000110101101110011001000000110110001101001011010110110010100100000011011010110010100101100000101001010100011010000110010101101110001000000110001001110010011010010110010001100111011001010111001100100000011001100110100101101110011001000010000001100001001000000111001101110000011000010110111001101110011010010110111001100111001000000111010001110010011001010110010100101110

CSE 123 – Lecture 2: Links and Signaling 12

Page 13: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

What’s a Frame?

! Wraps payload up with some additional informationu Header usually contains addressing informationu Maybe includes a trailer (w/checksum—next lecture)

! Basic unit of receptionu Link either delivers entire frame payload, or none of itu Typically some maximum transmission unit (MTU)

! Some link layers require absence of frames as wellu I.e., minimum gaps between frames

13

PayloadHeader Trailer

CSE 123 – Lecture 2: Layers & Framing

Page 14: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Identifying Frames! First task is to delineate frames

u Receiver needs to know when a frame starts and endsu Otherwise, errors from misinterpretation of data stream

! Several different alternativesu Fixed length (bits) framesu Explicitly delimited frames

» Length-based framing» Sentinel-based framing

u Fixed duration (seconds) frames

14CSE 123 – Lecture 2: Layers & Framing

Page 15: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Fixed-Length Frames! Easy to manage for receiver

u Well understood buffering requirements

! Introduces inefficiencies for variable length payloadsu May waste space (padding) for small payloadsu Larger payloads need to be fragmented across many framesu Very common inside switches

! Requires explicit design tradeoffu ATM uses 53-byte frames (cells)u Why 53? 48 + 5. Why 48?

15CSE 123 – Lecture 2: Layers & Framing

Page 16: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

Length-Based Framing

! To avoid overhead, we’d like variable length framesu Each frame declares how long it isu E.g. DECNet DDCMP

! What’s the issue with explicit length field?u Must correctly read the length field (bad if corrupted)

» Need to decode while receiving u Still need to identify the beginning…

16

PayloadStart Length

CSE 123 – Lecture 2: Layers & Framing

Page 17: Lecture 2: Links and Signaling · CSE 123–Lecture 2: Layers & Framing. Identifying Frames! First task is to delineate frames u Receiver needs to know when a frame startsand ends

For Next Class! Read 2.4

! Project 1 out on Friday

17CSE 123 – Lecture 2: Layers & Framing


Recommended