Chapter 5: The Data Link Layer. Chapter 5 Link Layer and LANs. Ethernet. Link Layer. Star topology. Ethernet Frame Structure.

Similar documents
Chapter 4. DataLink Layer. Reference: Computer Networking: A Top Down Approach 4 th edition. Jim Kurose, Keith Ross Addison-Wesley, July 2007.

The Link Layer and LANs: Ethernet and Swiches

Adaptors Communicating. Link Layer: Introduction. Parity Checking. Error Detection. Multiple Access Links and Protocols

Links. Error Detection. Link Layer. Multiple access protocols. Nodes Links Frame. Shared channel Problem: collisions How nodes share a channel

CSC 4900 Computer Networks: Link Layer (2)

CS 43: Computer Networks Switches and LANs. Kevin Webb Swarthmore College December 5, 2017

Announcements. CS 5565 Network Architecture and Protocols. Ethernet. Ethernet. Ethernet Model. Ideal Multiple Access Protocol

CMPE 150/L : Introduction to Computer Networks. Chen Qian Computer Engineering UCSC Baskin Engineering Lecture 18

Link Layer: Introduction. Chapter 5 Link Layer & LANS. Link layer: context. Link Layer Services

CS 455/555 Intro to Networks and Communications. Link Layer Addressing, Ethernet, and a Day in the Life of a Web Request

Adaptors Communicating. Link Layer: Introduction. Parity Checking. Error Detection. Multiple Access Links and Protocols

Review. Error Detection: CRC Multiple access protocols. LAN addresses and ARP Ethernet. Slotted ALOHA CSMA/CD

Chapter 5 Data Link Layer

Link Layer and LANs. Our Goals. Link Layer

Link Layer: Introduction. Chapter 5 Link Layer & LANS. Link layer: context. Link Layer Services

Link layer, LANs: outline. Chapter 5-2 Link Layer. MAC addresses (more) MAC addresses

Master Course Computer Networks IN2097

Chapter 5 part 2 LINK LAYER. Computer Networks Timothy Roscoe Summer Networks & Operating Systems Computer Networks

Data Link Layer. Our goals: understand principles behind data link layer services: instantiation and implementation of various link layer technologies

Chapter 5 Data Link Layer

Master Course Computer Networks IN2097

CS 3516: Advanced Computer Networks

Chapter 5 Link Layer. Down Approach. Computer Networking: A Top. 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012

Principles behind data link layer services

Chapter V: Link Layer

Chapter 5 Link Layer and LANs

Summary of MAC protocols

Principles behind data link layer services:

Principles behind data link layer services:

Ethernet Switches Bridges on Steroids. Ethernet Switches. IEEE Wireless LAN. Ad Hoc Networks

Chapter 5 Link Layer and LANs

Lecture 9 The Data Link Layer part II. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it

Medium Access Protocols

Module 4 Data Link Layer CS655! 4-1!

Chapter V: Link Layer

Chapter 5 Link Layer and LANs

Hubs. twisted pair. hub. 5: DataLink Layer 5-1

Lecture 5 The Data Link Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it

Link Layer and Ethernet

Lecture 6 The Data Link Layer. Antonio Cianfrani DIET Department Networking Group netlab.uniroma1.it

Link Layer and Ethernet

Link Layer: Introduction. Chapter 5 Link Layer & LANS. Link layer: context. Link Layer Services

Chapter 6 The Link Layer and LANs

Lecture 9 Ethernet and other Link Layer protocols

Topics. Link Layer Services (more) Link Layer Services LECTURE 5 MULTIPLE ACCESS AND LOCAL AREA NETWORKS. flow control: error detection:

Module 10 Data Link Layer CS655! 10-1!

CSCI Computer Networks Fall 2016

Links Reading: Chapter 2. Goals of Todayʼs Lecture. Message, Segment, Packet, and Frame

CSCI Computer Networks Spring 2017

Communication Networks ( ) / Spring 2011 The Blavatnik School of Computer Science, Tel-Aviv University. Allon Wagner

Principles behind data link layer services:

Chapter 5 Link Layer. Computer Networking: A Top Down Approach. 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012

The Link Layer II: Ethernet

Part 5: Link Layer Technologies. CSE 3461: Introduction to Computer Networking Reading: Chapter 5, Kurose and Ross

transferring datagram from one node data-link layer has responsibility of to adjacent node over a link 5-1 TDTS06 Computer networks

Link Layer. 5.1 Introduction and services 5.2 Error detection and correction 5.3Multiple access protocols 5.4 Link-Layer Addressing 5.

Chapter 5 Link Layer and LANs. Chapter 5: The Data Link Layer. Link Layer

CSMA/CD (Collision Detection)

Chapter 5 Link Layer and LANs

Chapter 5 Link Layer and LANs

Chapter 5 Link Layer. Computer Networking: A Top Down Approach. 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012

Discussions. What are the main service. Ch06 Link Layer. The Data Link Layer. Link Layer. Link Layer: Teminology. What are the services

Chapter 5: Link layer

INTRODUCTION, SERVICES. Data-link layer has responsibility of transferring datagram from one node to physically adjacent node over a link

Chapter 5 Link Layer. Computer Networking: A Top Down Approach. 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012

Chapter 6: Link layer and LANs. Link layer, LANs: outline. Link layer: introduction. Link layer: context. Link layer services (more)

CSC 8560 Computer Networks: Link Layer

ECE 4450:427/527 - Computer Networks Spring 2017

Chapter 5: DataLink Layer

High Level View. EE 122: Ethernet and Random Access protocols. Medium Access Protocols

Chapter 5: The Data Link Layer

CSC 401 Data and Computer Communications Networks

LINK LAYER AND LANS 1

CSCD 330 Network Programming Spring 2017

Chapter 5 Link Layer and LANs. Chapter 5: The Data Link Layer. Link Layer. Our goals: understand principles behind data link layer services:

Chapter 5: The Data Link Layer

EE 122: Ethernet and

Chapter 5 Link Layer and LANs. 5: DataLink Layer 5-1

Chapter 5: The Data Link Layer. Chapter 5 Link Layer and LANs. Link Layer. Link Layer: Introduction. Link layer: context. Link Layer Services

Computer Networks. Today. Principles of datalink layer services Multiple access links Adresavimas, ARP LANs Wireless LANs VU MIF CS 1/48 2/48

Chapter 6 The Link Layer and LANs

Chapter 6 The Data Link layer

Medium Access Control

Chapter 6 The Link Layer and LANs

Chapter 6 The Link Layer and LANs

Reminder: Datalink Functions Computer Networking. Datalink Architectures

Chapter 5 Link Layer and LANs

CSCD 330 Network Programming Winter 2016

Hubs. Interconnecting LANs. Q: Why not just one big LAN?

Chapter 5. understand principles behind data link layer. layer technologies. Some terminology: hosts and routers are nodes communication channels that

Chapter 5 Link Layer and LANs

Chapter 6 The Link Layer and LANs

Hubs, Bridges, and Switches (oh my) Hubs

ECE 4450:427/527 - Computer Networks Spring 2017

Chapter 6 The Link Layer and LANs. Chapter 6: Link layer and LANs. Link layer, LANs: outline

Chapter 5 Link Layer. Link Layer 5-1

Lecture 6 - Link layer. Lecture 5 Review. Link Layer. Introduction, Services. Notes. Notes. Notes. Notes. Networks and Security. Jacob Aae Mikkelsen

Link layer: introduction

Chapter 6 The Link Layer and LANs

Data Communications & Networks. Session 4 Main Theme. Link Control. Dr. Jean-Claude Franchitti

Transcription:

hapter 5 Link Layer and LNs omputer Networking: Top Down pproach 5 th edition. Jim Kurose, Keith Ross ddison-wesley, pril 2009. hapter 5: The Data Link Layer Our goals: understand principles behind data link layer services: error detection, correction sharing a broadcast channel: multiple access link layer addressing reliable data transfer, flow control: done! instantiation and implementation of various link layer technologies 5: DataLink Layer 5-1 5: DataLink Layer 5-2 Link Layer Ethernet 5.1 Introduction and services 5.2 Error detection and correction 5.3Multiple access protocols 5.4 Link-Layer ddressing 5.5 Ethernet 5. Link-layer switches 5.7 PPP 5.8 Link Virtualization: TM and MPLS wired LN technology: cheap $20 for NI first widely used LN technology simpler, cheaper than token LNs and TM kept up with speed race: 10 Mbps 10 Gbps Metcalfe s Ethernet sketch 5: DataLink Layer 5-3 5: DataLink Layer 5-4 Star topology Ethernet Frame Structure bus topology popular through mid 90s all nodes in same collision domain (can collide with each other) today: topology prevails active switch in center each spoke runs a (separate) Ethernet protocol (nodes do not collide with each other) Sending adapter encapsulates IP datagram (or other network layer protocol packet) in Ethernet frame Preamble: 7 bytes with pattern 10101010 followed by one byte with pattern 10101011 used to synchronize receiver, sender rates switch bus: coaxial cable star 5: DataLink Layer 5-5 5: DataLink Layer 5-1

Ethernet Frame Structure (more) ddresses: bytes if adapter receives frame with matching destination address, or with broadcast address (eg RP packet), it passes data in frame to network layer protocol otherwise, adapter discards frame Type: indicates higher layer protocol (mostly IP but others possible, e.g., Novell IPX, ppletalk) R: checked at receiver, if error is detected, frame is Ethernet: Unreliable, connectionless connectionless: No handshaking between sending and receiving NIs : receiving NI doesn t send acks or nacks to sending NI stream of datagrams passed to network layer can have gaps (missing datagrams) gaps will be filled if app is using TP otherwise, app will see gaps Ethernet s M protocol: unslotted SM/D 5: DataLink Layer 5-7 5: DataLink Layer 5-8 Ethernet SM/D algorithm 1. NI receives datagram 4. If NI detects another from network layer, transmission while creates frame transmitting, aborts and 2. If NI senses channel idle, sends jam signal starts frame transmission 5. fter aborting, NI If NI senses channel enters busy, waits until channel : after mth idle, then transmits collision, NI chooses K at 3. If NI transmits entire random from frame without detecting {0,1,2,,2 m -1}. NI waits another transmission, NI K 512 bit times, returns to is done with frame! Step 2 Ethernet s SM/D (more) Jam Signal: make sure all other transmitters are aware of collision; it time:.1 microsec for 10 Mbps Ethernet ; for K=1023, wait time is about 50 msec See/interact with Java applet on WL Web site: highly recommended! Exponential ackoff: Goal: adapt retransmission attempts to estimated current load heavy load: random wait will be longer first collision: choose K from {0,1}; delay is K 512 bit transmission times after second collision: choose K from {0,1,2,3} after ten collisions, choose K from {0,1,2,3,4,,1023} 5: DataLink Layer 5-9 5: DataLink Layer 5-10 SM/D efficiency T prop = max prop delay between 2 nodes in LN t trans = time to transmit max-size frame 1 efficiency = 1+ 5t prop /t trans 802.3 Ethernet Standards: Link & Physical Layers many different Ethernet standards common M protocol and frame format different speeds: 2 Mbps, 10 Mbps, 100 Mbps, 1Gbps, 10G bps different physical layer : fiber, cable efficiency goes to 1 as t prop goes to 0 as t trans goes to infinity better performance than : and simple, cheap, decentralized! 5: DataLink Layer 5-11 application transport network link physical 100SE-TX 100SE-T4 copper (twister pair) physical layer M protocol and frame format 100SE-T2 100SE-SX 100SE-FX 100SE-X fiber physical layer 5: DataLink Layer 5-12 2

Manchester encoding Link Layer used in each bit has a transition allows clocks in sending and receiving nodes to synchronize to each other no need for a centralized, global clock among nodes! Hey, this is physical-layer stuff! 5: DataLink Layer 5-13 5.1 Introduction and services 5.2 Error detection and correction 5.3 Multiple access protocols 5.4 Link-layer ddressing 5.5 Ethernet 5. Link-layer switches 5.7 PPP 5.8 Link Virtualization: TM, MPLS 5: DataLink Layer 5-14 Hubs physical-layer ( dumb ) repeaters: bits coming in one link go out other links at same rate all nodes connected to hub can collide with one another no frame buffering no SM/D at hub: host NIs detect collisions hub twisted pair Switch link-layer device: smarter than hubs, take role store, forward Ethernet frames examine incoming frame s M address, selectively forward frame to one-or-more outgoing links when frame is to be forwarded on segment, uses SM/D to access segment transparent hosts are unaware of presence of switches plug-and-play, self-learning switches do not need to be configured 5: DataLink Layer 5-15 5: DataLink Layer 5-1 Switch: allows multiple simultaneous transmissions hosts have dedicated, direct connection to switch switches packets Ethernet protocol used on each incoming link, but no collisions; full duplex each link is its own collision domain switching: -to- and - to- simultaneously, without collisions not possible with dumb hub 5 1 2 3 4 switch with six interfaces (1,2,3,4,5,) Switch Table Q: how does switch know that reachable via interface 4, reachable via interface 5? : each switch has a, each entry: (M address of host, interface to reach host, time stamp) looks like a routing table! Q: how are entries created, maintained in switch table? something like a routing protocol? 1 2 3 5 4 switch with six interfaces (1,2,3,4,5,) 5: DataLink Layer 5-17 5: DataLink Layer 5-18 3

Switch: self-learning switch which hosts can be reached through which interfaces when frame received, switch learns location of sender: incoming LN segment records sender/location pair in switch table M addr interface TTL 1 0 5 1 2 3 4 Source: Dest: Switch table (initially empty) 5: DataLink Layer 5-19 Switch: frame filtering/forwarding When frame received: 1. record link associated with sending host 2. index switch table using M dest address 3. if entry found for destination then { if dest on segment from which frame arrived then drop the frame else forward the frame on interface indicated } else forward on all but the interface on which the frame arrived 5: DataLink Layer 5-20 Self-learning, forwarding: example frame destination unknown: flood destination location known: send M addr interface TTL 1 0 4 0 1 2 3 5 4 Source: Dest: Switch table (initially empty) Interconnecting switches switches can be connected together S 1 S 2 D E Q: sending from to G - how does S 1 know to forward frame destined to F via S 4 and S 3? : self learning! (works the same as in single-switch case!) S 4 F G S 3 H I 5: DataLink Layer 5-21 5: DataLink Layer 5-22 Self-learning multi-switch example Suppose sends frame to I, I responds to Institutional network S 1 1 S 2 D 2 E F S 4 G S 3 H I to external network router mail server web server IP subnet Q: show switch tables and packet forwarding in S 1, S 2, S 3, S 4 5: DataLink Layer 5-23 5: DataLink Layer 5-24 4

Switches vs. Routers both store-and-forward devices routers: network layer devices (examine network layer headers) switches are link layer devices routers maintain routing tables, implement routing algorithms switches maintain switch tables, implement, learning algorithms Link Layer 5.1 Introduction and services 5.2 Error detection and correction 5.3Multiple access protocols 5.4 Link-Layer ddressing 5.5 Ethernet 5. Hubs and switches 5.7 PPP 5.8 Link Virtualization: TM 5: DataLink Layer 5-25 5: DataLink Layer 5-2 Point to Point Data Link ontrol one sender, one receiver, one link: easier than broadcast link: no Media ccess ontrol no need for explicit M addressing e.g., dialup link, ISDN line popular point-to-point DL protocols: PPP (point-to-point protocol) : High level data link control (Data link used to be considered high layer in protocol stack! 5: DataLink Layer 5-27 PPP Design Requirements [RF 1557] packet framing: encapsulation of network-layer datagram in data link frame carry network layer data of any network layer protocol (not just IP) at same time ability to upwards bit transparency: must carry any bit pattern in the data field error detection (no correction) connection liveness: detect, signal link failure to network layer network layer address negotiation: endpoint can learn/configure each other s network address 5: DataLink Layer 5-28 PPP non-requirements PPP Data Frame no error correction/recovery no flow control out of order delivery OK no need to support multipoint links (e.g., polling) Flag: (framing) ddress: does nothing (only one option) ontrol: does nothing; in the future possible multiple control fields Protocol: upper layer protocol to which frame delivered (eg, PPP-LP, IP, IPP, etc) Error recovery, flow control, data re-ordering all relegated to layers! 5: DataLink Layer 5-29 5: DataLink Layer 5-30 5

PPP Data Frame info: upper layer being carried check: cyclic redundancy check for error detection yte Stuffing data transparency requirement: data field must be allowed to include flag pattern <01111110> Q: is received <01111110> data or flag? Sender: adds ( stuffs ) extra < 01111110> byte after each < 01111110> byte Receiver: two 01111110 bytes in a row: discard first byte, continue data reception single 01111110: flag byte 5: DataLink Layer 5-31 5: DataLink Layer 5-32 yte Stuffing PPP Data ontrol Protocol flag byte pattern in data to send flag byte pattern plus stuffed byte in transmitted data 5: DataLink Layer 5-33 efore exchanging networklayer data, data link peers must PPP link (max. frame length, authentication) learn/configure network layer information for IP: carry IP ontrol Protocol (IPP) msgs (protocol field: 8021) to configure/learn IP address 5: DataLink Layer 5-34