last lecture summary
play

Last Lecture: Summary Goals: Overview: network layer services - PDF document

Last Lecture: Summary Goals: Overview: network layer services understand principles IP addressing behind network layer services: routing principle: path selection o routing (path IP selection) hierarchical routing o dealing


  1. Last Lecture: Summary Goals: Overview: ¸ network layer services ¸ understand principles ¸ IP addressing behind network layer services: ¸ routing principle: path selection o routing (path ¸ IP selection) ¸ hierarchical routing o dealing with scale ¸ Internet routing protocols o how a router works reliable transfer o advanced topics: IPv6, intra-domain o multicast inter-domain o ¸ instantiation and ¸ what’s inside a router? implementation in ¸ IPv6 the Internet ¸ multicast routing 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 1 Chapter 5: The Data Link Layer Our goals: ¸ 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! ¸ instantiation and implementation of various link layer technologies 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 2 Chapter 5 outline ¸ 5.1 Introduction and Self studies (extensive) services ¸ 5.2 Error detection and ¸ 5.4 LAN addresses and correction ARP ¸ 5.8 PPP ¸ 5.5 Ethernet ¸ 5.9 ATM ¸ 5.6 Hubs, bridges, and switches ¸ 5.10 Frame Relay ¸ 5.7 Wireless links and LANs ¸ 5.3Multiple access protocols Intro o (CSMA/CD) o 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 3 1

  2. Link Layer: Introduction “link” Some terminology: hosts and routers are nodes ¸ (bridges and switches too) communication channels that ¸ connect adjacent nodes along communication path are links wired links o wireless links o LANs o 2-PDU is a frame, encapsulates ¸ datagram data-link layer has responsibility of transferring datagram from one node to adjacent node over a link 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 4 Link layer: context transportation analogy ¸ Datagram transferred by trip from Princeton to Lausanne ¸ different link protocols limo: Princeton to JFK o over different links: plane: JFK to Geneva o o e.g., Ethernet on first link, train: Geneva to Lausanne o frame relay on ¸ tourist = datagram intermediate links, 802.11 ¸ transport segment = on last link communication link ¸ Each link protocol ¸ transportation mode = link provides different layer protocol services ¸ travel agent = routing o e.g., may or may not algorithm provide rdt over link 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 5 Link Layer Services ¸ Framing, link access: encapsulate datagram into frame, adding header, trailer o channel access if shared medium o ‘physical addresses’ used in frame headers to identify source, o dest ß different from IP address! ¸ Reliable delivery between adjacent nodes 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 o ß Q: why both link-level and end-end reliability? 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 6 2

  3. Link Layer Services (more) ¸ Flow Control: pacing between adjacent sending and receiving nodes o ¸ Error Detection : errors caused by signal attenuation, noise. o receiver detects presence of errors: o ß signals sender for retransmission or drops frame ¸ Error Correction: receiver identifies and corrects bit error(s) without resorting o to retransmission ¸ Half-duplex and full-duplex with half duplex, nodes at both ends of link can transmit, but o not at same time 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 7 Adaptors Communicating datagram rcving link layer protocol sending node node frame frame adapter adapter ¸ link layer implemented in ¸ receiving side “adaptor” (aka NIC) o looks for errors, rdt, flow o Ethernet card, PCMCI control, etc card, 802.11 card o extracts datagram, passes ¸ sending side: to rcving node o encapsulates datagram in ¸ adapter is semi- a frame autonomous o adds error checking bits, rdt, flow control, etc. ¸ link & physical layers 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 8 Chapter 5 outline 5.1 Introduction and services Self studies (extensive) ¸ 5.4 LAN addresses and ARP ¸ ¸ 5.2 Error detection and 5.5 Ethernet ¸ correction 5.6 Hubs, bridges, and ¸ ¸ 5.8 PPP switches 5.7 Wireless links and LANs ¸ ¸ 5.9 ATM 5.3Multiple access protocols ¸ ¸ 5.10 Frame Relay Intro o (CSMA/CD) o 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 9 3

  4. LAN Addresses and ARP 32-bit IP address: ¸ network-layer address ¸ used to get datagram to destination IP network (recall IP network definition) LAN (or MAC or physical or Ethernet) address: ¸ used to get datagram from one interface to another physically- connected interface (same network) ¸ 48 bit MAC address (for most LANs) burned in the adapter ROM 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 10 LAN Addresses and ARP Each adapter on LAN has unique LAN address 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 11 LAN Address (more) ¸ MAC address allocation administered by IEEE ¸ manufacturer buys portion of MAC address space (to assure uniqueness) ¸ Analogy: (a) MAC address: like Social Security Number (b) IP address: like postal address ¸ MAC flat address => portability can move LAN card from one LAN to another o ¸ IP hierarchical address NOT portable depends on IP network to which node is attached o 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 12 4

  5. Recall earlier routing discussion Starting at A, given IP A datagram addressed to B: 223.1.1.1 ¸ look up net. address of B, find B 223.1.2.1 223.1.1.2 on same net. as A 223.1.2.9 223.1.1.4 ¸ link layer send datagram to B B 223.1.2.2 inside link-layer frame E 223.1.1.3 223.1.3.27 223.1.3.1 223.1.3.2 frame source, datagram source, dest address dest address A’s IP B’s MAC A’s MAC B’s IP IP payload addr addr addr addr datagram frame 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 13 ARP: Address Resolution Protocol ¸ Each IP node (Host, Router) Question: how to determine on LAN has ARP table MAC address of B ¸ ARP Table: IP/MAC address mappings for some LAN knowing B’s IP address? nodes < IP address; MAC address; TTL> TTL (Time To Live): time o after which address mapping will be forgotten (typically 20 min) 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 14 ARP protocol A wants to send datagram to ¸ A caches (saves) IP-to- ¸ B, and A knows B’s IP address. MAC address pair in its ARP table until information Suppose B’s MAC address is ¸ not in A’s ARP table. becomes old (times out) A broadcasts ARP query o soft state: information ¸ packet, containing B's IP that times out (goes address away) unless refreshed all machines on LAN o ¸ ARP is “plug-and-play”: receive ARP query o nodes create their ARP B receives ARP packet, replies ¸ to A with its (B's) MAC tables without address intervention from net frame sent to A’s MAC administrator o address (unicast) 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 15 5

  6. Routing to another LAN walkthrough: send datagram from A to B via R assume A know’s B IP address A Two ARP tables in router R, one for each IP network (LAN) ¸ R B ¸ In routing table at source Host, find router 111.111.111.110 ¸ In ARP table at source, find MAC address E6-E9-00-17-BB- 4B, etc 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 16 A creates datagram with source A, destination B ¸ A uses ARP to get R’s MAC address for 111.111.111.110 ¸ A creates link-layer frame with R's MAC address as dest, frame ¸ contains A-to-B IP datagram A’s data link layer sends frame ¸ R’s data link layer receives frame ¸ R removes IP datagram from Ethernet frame, sees its destined to ¸ B R uses ARP to get B’s physical layer address ¸ R creates frame containing A-to-B IP datagram sends to B ¸ A R B 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 17 Chapter 5 outline ¸ 5.1 Introduction and Self studies (extensive) services ¸ 5.2 Error detection and ¸ 5.4 LAN addresses and correction ARP ¸ 5.8 PPP ¸ 5.5 Ethernet ¸ 5.9 ATM ¸ 5.6 Hubs, bridges, and ¸ 5.10 Frame Relay switches ¸ 5.7 Wireless links and LANs ¸ 5.3Multiple access protocols o Intro o (CSMA/CD) 7/10 Datakommunikation & Internet, Anders Broberg, UmU Link layer 18 6

Recommend


More recommend