CSCI-1680 Link Layer Wrap-Up Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti Rodrigo Fonseca.

Slides:



Advertisements
Similar presentations
CSCI-1680 Switching Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti Rodrigo Fonseca.
Advertisements

CCNA3: Switching Basics and Intermediate Routing v3.0 CISCO NETWORKING ACADEMY PROGRAM Switching Concepts Introduction to Ethernet/802.3 LANs Introduction.
Communication Networks Recitation 3 Bridges & Spanning trees.
Topic 7 Local Area Networks (LAN)
Packet Switching COM1337/3501 Textbook: Computer Networks: A Systems Approach, L. Peterson, B. Davie, Morgan Kaufmann Chapter 3.
The ALOHA Protocol “Free for all”: whenever station has a frame to send, it does so. –Station listens for maximum RTT for an ACK. –If no ACK after a specified.
CSCI-1680 Link Layer Wrap-Up Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti Rodrigo Fonseca.
5/31/05CS118/Spring051 twisted pair hub 10BaseT, 100BaseT, hub r T= Twisted pair (copper wire) r Nodes connected to a hub, 100m max distance r Hub: physical.
1 Switching and Forwarding Bridges and Extended LANs.
CCNA 3 v3.1 Module 4.
1 Chapter 3 Switching and Forwarding Outline 3.1 Switching and Forwarding 3.2 Bridges and LAN Switches 3.3 Cell Switching (ATM) 3.4 Implementation and.
1 Shared Access Networks Outline Bus (Ethernet) Token ring (FDDI) Wireless (802.11)
1 Version 3 Module 8 Ethernet Switching. 2 Version 3 Ethernet Switching Ethernet is a shared media –One node can transmit data at a time More nodes increases.
Spring 2002CS 4611 Shared Access Networks Outline Bus (Ethernet) Token ring (FDDI) Wireless (802.11)
EEC-484/584 Computer Networks Lecture 13 Wenbing Zhao
5-1 Data Link Layer r Today, we will study the data link layer… r This is the last layer in the network protocol stack we will study in this class…
CSE331: Introduction to Networks and Security Lecture 6 Fall 2002.
1 Switching and Forwarding Bridges and Extended LANs.
1 K. Salah Module 4.3: Repeaters, Bridges, & Switches Repeater Hub NIC Bridges Switches VLANs GbE.
Introduction to Computer Networks 09/23 Presenter: Fatemah Panahi.
DataLink Layer1 Ethernet Technologies: 10Base2 10: 10Mbps; 2: 200 meters (actual is 185m) max distance between any two nodes without repeaters thin coaxial.
LOGO Local Area Network (LAN) Layer 2 Switching and Virtual LANs (VLANs) Local Area Network (LAN) Layer 2 Switching and Virtual LANs (VLANs) Chapter 6.
Layer 2 Switch  Layer 2 Switching is hardware based.  Uses the host's Media Access Control (MAC) address.  Uses Application Specific Integrated Circuits.
Connecting LANs, Backbone Networks, and Virtual LANs
Lecture 8: Ethernet and Token Ring Networks. Ethernet Carrier Sense, Multiple Access and Collision Detect (CSMA/CD) LAN Ethernet Standard-DEC, Intel,
CSCI-1680 Link Layer Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti Rodrigo Fonseca.
1 Token Passing: IEEE802.5 standard  4 Mbps  maximum token holding time: 10 ms, limiting packet length  packet (token, data) format:  SD, ED mark start,
ICOM 6115©Manuel Rodriguez-Martinez ICOM 6115 – Computer Networks and the WWW Manuel Rodriguez-Martinez, Ph.D. Lecture 17.
Lecture 17 Ethernet r Widely deployed because: m First LAN technology m Simpler and less expensive than token LANs and ATM m Kept up with the speed race:
Introduction1-1 Data Communications and Computer Networks Chapter 5 CS 3830 Lecture 27 Omar Meqdadi Department of Computer Science and Software Engineering.
CSCI-2950-u Switching and Routing Overview Most slides from CS-168 Rodrigo Fonseca.
Brierley 1 Module 4 Module 4 Introduction to LAN Switching.
ICOM 6115©Manuel Rodriguez-Martinez ICOM 6115 – Computer Networks and the WWW Manuel Rodriguez-Martinez, Ph.D. Lecture 16.
S3C2 – LAN Switching Addressing LAN Problems. Congestion is Caused By Multitasking, Faster operating systems, More Web-based applications Client-Server.
Token Passing: IEEE802.5 standard  4 Mbps  maximum token holding time: 10 ms, limiting packet length  packet (token, data) format:  SD, ED mark start,
CPS 356: Introduction to Computer Networks Lecture 7: Switching technologies Ch 2.8.2, 3.1, 3.4 Xiaowei Yang
Module 8: Ethernet Switching
CCNA 3 Week 4 Switching Concepts. Copyright © 2005 University of Bolton Introduction Lan design has moved away from using shared media, hubs and repeaters.
Review: –Ethernet What is the MAC protocol in Ethernet? –CSMA/CD –Binary exponential backoff Is there any relationship between the minimum frame size and.
1 © 2003, Cisco Systems, Inc. All rights reserved. CCNA 3 v3.0 Module 4 Switching Concepts.
Cisco 3 - Switching Perrine. J Page 16/4/2016 Chapter 4 Switches The performance of shared-medium Ethernet is affected by several factors: data frame broadcast.
Sem1 - Module 8 Ethernet Switching. Shared media environments Shared media environment: –Occurs when multiple hosts have access to the same medium. –For.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Connecting Devices CORPORATE INSTITUTE OF SCIENCE & TECHNOLOGY, BHOPAL Department of Electronics and.
Chapter 11 Extending LANs 1. Distance limitations of LANs 2. Connecting multiple LANs together 3. Repeaters 4. Bridges 5. Filtering frame 6. Bridged network.
CSCI-1680 Connecting Link Layers Based partly on lecture notes by David Mazières, Phil Levis, Rodrigo Fonseca John Jannotti.
EE 122: Lecture 6 Ion Stoica September 13, 2001 (* this talk is based in part on the on-line slides of J. Kurose & K. Rose)
CCNA3 Module 4 Brierley Module 4. CCNA3 Module 4 Brierley Topics LAN congestion and its effect on network performance Advantages of LAN segmentation in.
CSCI-1680 Link Layer Wrap-Up Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti Rodrigo Fonseca.
1 Ethernet History –developed by Xerox PARC in mid-1970s –roots in Aloha packet-radio network –standardized by Xerox, DEC, and Intel in 1978 –similar to.
1 Switching and Forwarding Sections Connecting More Than Two Hosts Multi-access link: Ethernet, wireless –Single physical link, shared by multiple.
1 Multiple Access: Ethernet Section Point-to-Point vs. Broadcast Media Point-to-point –PPP for dial-up access –Point-to-point link between Ethernet.
5: DataLink Layer5-1 Hubs Hubs are essentially physical-layer repeaters: m bits coming from one link go out all other links m at the same rate m no frame.
1 Packet Switching Outline Switching and Forwarding Bridges and Extended LANs.
CSCI-1680 Link Layer Wrap-Up Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti Rodrigo Fonseca.
Chapter 3 Part 1 Switching and Bridging
Youngstown State University Cisco Regional Academy
CSCI-1680 Link Layer Wrap-Up
Advanced Computer Networks
Packet Switching Outline Store-and-Forward Switches
Chapter 4 Data Link Layer Switching
Hubs Hubs are essentially physical-layer repeaters:
Switching and Forwarding Bridges and Extended LANs
Chapter 3 Part 1 Switching and Bridging
CS 457 – Lecture 6 Ethernet Spring 2012.
Hubs Hubs are essentially physical-layer repeaters:
Bridges and Extended LANs
CS4470 Computer Networking Protocols
Packet Switching Outline Store-and-Forward Switches
LAN Addresses and ARP IP address: drives the packet to destination network LAN (or MAC or Physical) address: drives the packet to the destination node’s.
Virtual LAN (VLAN).
Presentation transcript:

CSCI-1680 Link Layer Wrap-Up Based partly on lecture notes by David Mazières, Phil Levis, John Jannotti Rodrigo Fonseca

Administrivia Homework I out later today, due next Friday, Feb 17th

Today: Link Layer (cont.) Framing Reliability –Error correction –Sliding window Medium Access Control Case study: Ethernet Link Layer Switching

Media Access Control Control access to shared physical medium –E.g., who can talk when? –If everyone talks at once, no one hears anything –Job of the Link Layer Two conflicting goals –Maximize utilization when one node sending –Approach 1/N allocation when N nodes sending

Different Approaches Partitioned Access –Time Division Multiple Access (TDMA) –Frequency Division Multiple Access (FDMA) –Code Division Multiple Access (CDMA) Random Access –ALOHA/ Slotted ALOHA –Carrier Sense Multiple Access / Collision Detection (CSMA/CD) –Carrier Sense Multiple Access / Collision Avoidance (CSMA/CA) –RTS/CTS (Request to Send/Clear to Send) –Token-based

Case Study: Ethernet (802.3) Dominant wired LAN technology –10BASE2, 10BASE5 (Vampire Taps) –10BASET, 100BASE-TX, 1000BASE-T, 10GBASE-T,… Both Physical and Link Layer specification CSMA/CD –Carrier Sense / Multiple Access / Collision Detection Frame Format (Manchester Encoding):

Ethernet Addressing Globally unique, 48-bit unicast address per adapter –Example: 00:1c:43:00:3d:09 (Samsung adapter) –24 msb: organization – txthttp://standards.ieee.org/develop/regauth/oui/oui. txt Broadcast address: all 1s Multicast address: first bit 1 Adapter can work in promiscuous mode

Ethernet MAC: CSMA/CD Problem: shared medium –10Mbps: 2500m, with 4 repeaters at 500m Transmit algorithm –If line is idle, transmit immediately –Upper bound message size of 1500 bytes –Must wait 9.6μs (96-bit time) between back to back frames (Old limit) To give time to switch from tx to rx mode –If line is busy: wait until idle and transmit immediately

Handling Collisions Collision detection (10Base2 Ethernet) –Uses Manchester encoding. Why does that help? –Constant average voltage unless multiple transmitters If collision –Jam for 32 bits, then stop transmitting frame Collision detection constrains protocol –Imposes min. packet size (64 bytes or 512 bits) –Imposes maximum network diameter (2500m) –Ensure transmission time ≥ 2x propagation delay (why?)

Collision Detection Without minimum frame length, might not detect collision

When to transmit again? Delay and try again: exponential backoff nth time: k × 51.2μs, for k = U{0..2 min(n,10) - 1} –1 st time: 0 or 51.2μs –2 nd time: 0, 51.2, 102.4, or 153.6μs Give up after several times (usually 16)

Capture Effect Exponential backoff leads to self- adaptive use of channel A and B are trying to transmit, and collide Both will back off either 0 or 51.2μs Say A wins. Next time, collide again. –A will wait between 0 or 1 slots –B will wait between 0, 1, 2, or 3 slots …

Token Ring Idea: frames flow around ring Capture special “token” bit pattern to transmit Variation used today in Metropolitan Area Networks, with fiber

Interface Cards Problem: if host dies, can break the network Hardware typically has relays

Token Ring Frames Frame format (Differential Manchester) Sender grabs token, sends message(s) Recipient checks address Sender removes frame from ring after lap Maximum holding time: avoid capture Monitor node reestablishes lost token

Switching

Basic Problem Direct-link networks don’t scale Solution: use switches to connect network segments

Switching Switches must be able to, given a packet, determine the outgoing port 3 ways to do this: –Virtual Circuit Switching –Datagram Switching –Source Routing

Virtual Circuit Switching Explicit set-up and tear down phases –Establishes Virtual Circuit Identifier on each link –Each switch stores VC table Subsequent packets follow same path –Switches map [in-port, in-VCI] : [out-port, out-VCI] Also called connection-oriented model

Virtual Circuit Model Requires one RTT before sending first packet Connection request contain full destination address, subsequent packets only small VCI Setup phase allows reservation of resources, such as bandwidth or buffer- space –Any problems here? If a link or switch fails, must re-establish whole circuit Example: ATM

Datagram Switching Each packet carries destination address Switches maintain address-based tables –Maps [destination address]:[out-port] Also called connectionless model Add r Port A3 B0 C3 D3 E2 F1 G0 H0 Switch 2

Datagram Switching No delay for connection setup Source can’t know if network can deliver a packet Possible to route around failures Higher overhead per-packet Potentially larger tables at switches

Source Routing Packets carry entire route: ports Switches need no tables! –But end hosts must obtain the path information Variable packet header

Bridging

Bridges and Extended LANs LANs have limitations –E.g. Ethernet < 1024 hosts, < 2500m Connect two or more LANs with a bridge –Operates on Ethernet addresses –Forwards packets from one LAN to the other(s) Ethernet switch is just a multi-way bridge

Learning Bridges Idea: don’t forward a packet where it isn’t needed –If you know recipient is not on that port Learn hosts’ locations based on source addresses –Build a table as you receive packets –Table is a cache: if full, evict old entries. Why is this fine? Table says when not to forward a packet –Doesn’t need to be complete for correctness

Attack on a Learning Switch Eve: wants to sniff all packets sent to Bob Same segment: easy (shared medium) Different segment on a learning bridge: hard –Once bridge learns Bob’s port, stop broadcasting How can Eve force the bridge to keep broadcasting? –Flood the network with frames with spoofed src addr!

Bridges Unicast: forward with filtering Broadcast: always forward Multicast: always forward or learn groups Difference between bridges and repeaters? –Bridges: same broadcast domain; copy frames –Repeaters: same broadcast and collision domain; copy signals

Dealing with Loops Problem: people may create loops in LAN! –Accidentally, or to provide redundancy –Don’t want to forward packets indefinitely

Spanning Tree Need to disable ports, so that no loops in network Like creating a spanning tree in a graph –View switches and networks as nodes, ports as edges

Distributed Spanning Tree Algorithm Every bridge has a unique ID (Ethernet address) Goal: –Bridge with the smallest ID is the root –Each segment has one designated bridge, responsible for forwarding its packets towards the root Bridge closest to root is designated bridge If there is a tie, bridge with lowest ID wins

Spanning Tree Protocol Spanning Tree messages contain: –ID of bridge sending the message –ID sender believes to be the root –Distance (in hops) from sender to root Bridges remember best config msg on each port Send message when you think you are the root Otherwise, forward messages from best known root –Add one to distance before forwarding –Don’t forward if you know you aren’t dedicated bridge In the end, only root is generating messages

Limitations of Bridges Scaling –Spanning tree algorithm doesn’t scale –Broadcast does not scale –No way to route around congested links, even if path exists May violate assumptions –Could confuse some applications that assume single segment –Much more likely to drop packets –Makes latency between nodes non-uniform –Beware of transparency

VLANs Company network, A and B departments –Broadcast traffic does not scale –May not want traffic between the two departments –Topology has to mirror physical locations –What if employees move between offices? b1b1 b2b2 a1a1 a2a2

VLANs Solution: Virtual LANs –Assign switch ports to a VLAN ID (color) –Isolate traffic: only same color –Trunk links may belong to multiple VLANs –Encapsulate packets: add 12-bit VLAN ID Easy to change, no need to rewire a2a2 b2b2 a1a1 b1b1

Generic Switch Architecture Goal: deliver packets from input to output ports Three potential performance concerns: –Throughput in bytes/second –Throughput in packets/second –Latency

Cut through vs. Store and Forward Two approaches to forwarding a packet –Receive a full packet, then send to output port –Start retransmitting as soon as you know output port, before full packet Cut-through routing can greatly decrease latency Disadvantage –Can waste transmission (classic optimistic approach) –CRC may be bad –If Ethernet collision, may have to send runt packet on output link

Buffering Buffering of packets can happen at input ports, fabric, and/or output ports Queuing discipline is very important Consider FIFO + input port buffering –Only one packet per output port at any time –If multiple packets arrive for port 2, they may block packets to other ports that are free –Head-of-line blocking 2 21 Port 1 Port 2

Shared Memory Switch 1 st Generation – like a regular PC –NIC DMAs packet to memory over I/O bus –CPU examines header, sends to destination NIC –I/O bus is serious bottleneck –For small packets, CPU may be limited too –Typically < 0.5 Gbps

Shared Bus Switch 2 st Generation –NIC has own processor, cache of forwarding table –Shared bus, doesn’t have to go to main memory –Typically limited to bus bandwidth (Cisco 5600 has a 32Gbps bus)

Point to Point Switch 3 rd Generation: overcomes single-bus bottleneck Example: Cross-bar switch –Any input-output permutation –Multiple inputs to same output requires trickery –Cisco series: 60Gbps

Coming Up Connecting multiple networks: IP and the Network Layer Remember: no class on Tuesday!