Chapter 5 Data link Layer Computer Networking A Top Down Approach Featuring the Internet The powerpoint slides are based on the material 2nd edition provided by Jim Kurose, Keith Ros J F Kurose and K.W. Ross Addison-Wesley, Juf 2002 5: DataLink Layer 5a-1
5: DataLink Layer 5a-1 Chapter 5 Data Link Layer Computer Networking: A Top Down Approach Featuring the Internet, 2nd edition. Jim Kurose, Keith Ross Addison-Wesley, July 2002. The PowerPoint Slides are based on the material provided by J.F Kurose and K.W. Ross
Chapter 5: The data link layer Our goals O understand principles behind data link layer services: o error detection correction o sharing a broadcast channel: multiple access o link layer addressing o reliable data transfer, flow control: done! D instantiation and implementation of various link lyer technologies 5: DataLink Layer 5a-2
5: DataLink Layer 5a-2 Chapter 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
Chapter 5 outline 0 5. 1 Introduction and 0 5.6 Hubs bridges, and services switches 0 5.2 Error detection g 5.7 Wireless links and and correction LANS 0 5. 3 Multiple access 05. 8 PPP protocols 059ATM 0 5.4 LAN addresses o 5.10 Frame Relay and Arp 0 5.5 Ethernet 5: DataLink Layer 5a-3
5: DataLink Layer 5a-3 Chapter 5 outline 5.1 Introduction and services 5.2 Error detection and correction 5.3Multiple access protocols 5.4 LAN addresses and ARP 5.5 Ethernet 5.6 Hubs, bridges, and switches 5.7 Wireless links and LANs 5.8 PPP 5.9 ATM 5.10 Frame Relay
Link Layer: Introduction link" Some terminology: a hosts and routers are nodes (bridges and switches too 0 communication channels that connect adjacent nodes along communication path are links o wired links o wireless links LANS 口2 PDU is a frame encapsulates datagram data-link layer has responsibility of transferring datagram from one node to ad jacent node over a link 5: DataLink Layer 5a-4
5: DataLink Layer 5a-4 Link Layer: Introduction Some terminology: hosts and routers are nodes (bridges and switches too) communication channels that connect adjacent nodes along communication path are links wired links wireless links LANs 2-PDU is a frame, encapsulates datagram “link” data-link layer has responsibility of transferring datagram from one node to adjacent node over a link
Link layer: context o Datagram transferred by transportation analo different link protocols o trip from princeton to over different links: Lausanne o limo: Princeton to JFK o e.g., Ethernet on first link, frame relay on o plane: JFK to Geneva intermediate links 802 11 o train: Geneva to lausanne on last link 口 fourist= datagram D Each link protoco O transport segment provides different communication link services 口 transportation mode e. g, may or may not provide rdt over link link layer protocol 口 travel agent= routing algorithm 5: DataLink Layer 5a-5
5: DataLink Layer 5a-5 Link layer: context Datagram transferred by different link protocols over different links: e.g., Ethernet on first link, frame relay on intermediate links, 802.11 on last link Each link protocol provides different services e.g., may or may not provide rdt over link transportation analogy trip from Princeton to Lausanne limo: Princeton to JFK plane: JFK to Geneva train: Geneva to Lausanne tourist = datagram transport segment = communication link transportation mode = link layer protocol travel agent = routing algorithm
Link Layer Services 口 Framing, link access: encapsulate datagram into frame adding header trailer channel access if shared medium o physical addresses' used in frame headers to identify source. dest different from IP address D Reliable delivery between adjacent nodes o we learned how to do this already (chapter 3) o seldom used on low bit error link(fiber some twisted pair) o wireless links: high error rates Q: why both link-level and end-end reliability? 5: DataLink Layer 5a-6
5: DataLink Layer 5a-6 Link Layer Services Framing, link access: encapsulate datagram into frame, adding header, trailer channel access if shared medium ‘physical addresses’ used in frame headers to identify source, dest • different from IP address! Reliable delivery between adjacent nodes we learned how to do this already (chapter 3)! seldom used on low bit error link (fiber, some twisted pair) wireless links: high error rates • Q: why both link-level and end-end reliability?
Link Layer Services(more g Flow Control: o pacing between ad jacent sending and receiving nodes 口 Error Detection: o errors caused by signal attenuation, noise o receiver detects presence of errors: signals sender for retransmission or drops frame 口 Error Correction o receiver identifies and corrects bit error(s without resorting to retransmission o Half-duplex and full-duplex o with half duplex, nodes at both ends of link can transmit but not at same time 5: DataLink Layer 5a-7
5: DataLink Layer 5a-7 Link Layer Services (more) Flow Control: pacing between adjacent sending and receiving nodes Error Detection: errors caused by signal attenuation, noise. receiver detects presence of errors: • signals sender for retransmission or drops frame Error Correction: receiver identifies and corrects bit error(s) without resorting to retransmission Half-duplex and full-duplex with half duplex, nodes at both ends of link can transmit, but not at same time
Adaptors Communicating datagram roving sending link layer protocol node node frame frame adapter adapter o link layer implemented in o receiving side adaptor"(aka NIC) looks for errors, rdt flow o Ethernet card, PCmcI control etc card. 802.11 card o extracts datagram, passes 口 sending side to roving node o encapsulates datagram in D adapter is sem a frame autonomous o adds error checking bits, o link& physical layers rdt, flow control, etc 5: DataLink Layer 5a-8
5: DataLink Layer 5a-8 Adaptors Communicating link layer implemented in “adaptor” (aka NIC) Ethernet card, PCMCI card, 802.11 card sending side: encapsulates datagram in a frame adds error checking bits, rdt, flow control, etc. receiving side looks for errors, rdt, flow control, etc extracts datagram, passes to rcving node adapter is semiautonomous link & physical layers sending node frame rcving node datagram frame adapter adapter link layer protocol
Chapter 5 outline g 5.1 Introduction and 口56Hubs, bridges,and services switches 0 5.2 Error detection g 5.7 Wireless links and and correction LANS 0 5. 3 Multiple access 05. 8 PPP protocols 059ATM 0 5.4 LAN addresses o 5.10 Frame Relay and Arp 0 5.5 Ethernet 5: DataLink Layer 5a-9
5: DataLink Layer 5a-9 Chapter 5 outline 5.1 Introduction and services 5.2 Error detection and correction 5.3Multiple access protocols 5.4 LAN addresses and ARP 5.5 Ethernet 5.6 Hubs, bridges, and switches 5.7 Wireless links and LANs 5.8 PPP 5.9 ATM 5.10 Frame Relay
Error detection EDC= Error Detection and Correction bits (redundancy) D = Data protected by error checking may include header fields Error detection not 100% reliable! protocol may miss some errors, but rarely larger edc field yields better detection and correction datagram datagram a bits in D N ○K ? error ← d data bits D EDC D EDC o bit-error prone link 0 5: DataLink Lo 5a-10
5: DataLink Layer 5a-10 Error Detection EDC= Error Detection and Correction bits (redundancy) D = Data protected by error checking, may include header fields • Error detection not 100% reliable! • protocol may miss some errors, but rarely • larger EDC field yields better detection and correction