Network Superhighway CSCD 330. Network Programming Winter Lecture 13 Network Layer. Reading: Chapter 4

Similar documents
CSCD 330 Network Programming

Chapter 4 Network Layer

Chapter 4. Computer Networking: A Top Down Approach 5 th edition. Jim Kurose, Keith Ross Addison-Wesley, sl April 2009.

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

Computer Networks. Instructor: Niklas Carlsson

CSE 3214: Computer Network Protocols and Applications Network Layer

The Network Layer and Routers

CMSC 332 Computer Networks Network Layer

Routers: Forwarding EECS 122: Lecture 13

Key Network-Layer Functions

TOC: Switching & Forwarding

Routers: Forwarding EECS 122: Lecture 13

Lecture 7. Network Layer. Network Layer 1-1

Topic 4a Router Operation and Scheduling. Ch4: Network Layer: The Data Plane. Computer Networking: A Top Down Approach

HW3 and Quiz. P14, P24, P26, P27, P28, P31, P37, P43, P46, P55, due at 3:00pm with both soft and hard copies, 11/11/2013 (Monday) TCP), 20 mins

TOC: Switching & Forwarding

Chapter 4 Network Layer: The Data Plane

CSC 4900 Computer Networks: Network Layer

CSCE 463/612 Networks and Distributed Processing Spring 2018

Lecture 16: Network Layer Overview, Internet Protocol

CSC 401 Data and Computer Communications Networks

Lecture 3. The Network Layer (cont d) Network Layer 1-1

EECS 122: Introduction to Computer Networks Switch and Router Architectures. Today s Lecture

Last time. BGP policy. Broadcast / multicast routing. Link virtualization. Spanning trees. Reverse path forwarding, pruning Tunneling

Lecture 4 - Network Layer. Transport Layer. Outline. Introduction. Notes. Notes. Notes. Notes. Networks and Security. Jacob Aae Mikkelsen

Network Layer Introduction

Chapter 4: network layer. Network service model. Two key network-layer functions. Network layer. Input port functions. Router architecture overview

Last time. Wireless link-layer. Introduction. Characteristics of wireless links wireless LANs networking. Cellular Internet access

Chapter 4 Network Layer

CSCE 463/612 Networks and Distributed Processing Spring 2018

1-1. Switching Networks (Fall 2010) EE 586 Communication and. October 25, Lecture 24

Chapter 4: network layer

Network layer overview

Network Layer: outline

Chapter 4 Network Layer: The Data Plane. Part A. Computer Networking: A Top Down Approach

Growth. Individual departments in a university buy LANs for their own machines and eventually want to interconnect with other campus LANs.

CS 43: Computer Networks. 20: The Network Layer November 5, 2018

Computer Networks LECTURE 10 ICMP, SNMP, Inside a Router, Link Layer Protocols. Assignments INTERNET CONTROL MESSAGE PROTOCOL

Router Architecture Overview

TOC: Switching & Forwarding

COMP211 Chapter 4 Network Layer: The Data Plane

Network layer (addendum) Slides adapted from material by Nick McKeown and Kevin Lai

TDTS06: computer Networks

internet technologies and standards

Revision of Previous Lectures

Routers Technologies & Evolution for High-Speed Networks

Lecture 2: Internet Structure

Chapter 4: Network Layer

Generic Architecture. EECS 122: Introduction to Computer Networks Switch and Router Architectures. Shared Memory (1 st Generation) Today s Lecture

CS 43: Computer Networks The Network Layer. Kevin Webb Swarthmore College November 2, 2017

Network Layer: Router Architecture, IP Addressing

LS Example 5 3 C 5 A 1 D

Topics for Today. Network Layer. Readings. Introduction Addressing Address Resolution. Sections 5.1,

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

CSE 123A Computer Networks

Routers. Session 12 INST 346 Technologies, Infrastructure and Architecture

4.2 Virtual Circuit and Datagram Networks

LAN Interconnection and Other Link Layer Protocols

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

Sample Routers and Switches. High Capacity Router Cisco CRS-1 up to 46 Tb/s thruput. Routers in a Network. Router Design

Digital Communication Networks

internet technologies and standards

Lecture 16: Router Design

Network Performance: Queuing

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

Network Layer: Control/data plane, addressing, routers

Course 6. Internetworking Routing 1/33

Module 1. Introduction. Version 2, CSE IIT, Kharagpur

Network Layer PREPARED BY AHMED ABDEL-RAOUF

NETWORK LAYER DATA PLANE

CS 3516: Advanced Computer Networks

Chapter 4 Network Layer: The Data Plane

Data Communication & Networks G Session 7 - Main Theme Networks: Part I Circuit Switching, Packet Switching, The Network Layer

Internetworking Part 1

ELEC / COMP 177 Fall Some slides from Kurose and Ross, Computer Networking, 5 th Edition

Lecture 17 Overview. Last Lecture. Wide Area Networking (2) This Lecture. Internet Protocol (1) Source: chapters 2.2, 2.3,18.4, 19.1, 9.

CSCD 433/533 Advanced Networks

Lecture 8. Network Layer (cont d) Network Layer 1-1

EPL606. Internetworking. Part 2a. 1Network Layer

Virtual Link Layer : Fundamentals of Computer Networks Bill Nace

Chapter 4 Network Layer

1/29/2008. From Signals to Packets. Lecture 6 Datalink Framing, Switching. Datalink Functions. Datalink Lectures. Character and Bit Stuffing.

Chapter 4 Network Layer

Switching and Forwarding Reading: Chapter 3 1/30/14 1

Router Architecture Overview

Chapter 4 Network Layer: The Data Plane

Computer Communications and Network Basics p. 1 Overview of Computer Communications and Networking p. 2 What Does Computer Communications and

CH : 15 LOCAL AREA NETWORK OVERVIEW

Where we are in the Course

Computer Networking. Introduction. Quintin jean-noël Grenoble university

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

Cisco Series Internet Router Architecture: Packet Switching

Introduction to Networks and the Internet

Lecture 6 Datalink Framing, Switching. From Signals to Packets

Virtual Link Layer : Fundamentals of Computer Networks Bill Nace

Chapter 4 Network Layer: The Data Plane

CSC358 Week 6. Adapted from slides by J.F. Kurose and K. W. Ross. All material copyright J.F Kurose and K.W. Ross, All Rights Reserved

Network Performance: Queuing

Local Area Network Overview

Internet Architecture and Protocol

Transcription:

CSCD 330 Network Superhighway Network Programming Winter 2015 Lecture 13 Network Layer Reading: Chapter 4 Some slides provided courtesy of J.F Kurose and K.W. Ross, All Rights Reserved, copyright 1996-2007 1

Introduction So far, have looked at Application Layer Transport Layer Now, move down protocol stack to Network Layer What services are offered? How does this layer fit with other layers? Hardware is used at this layer? 2

Network Layer Goals Understand principles behind network layer Network layer service models Forwarding versus routing, difference How a router works - Internally Routing itself Addresses, paths, algorithms 3

TCP/IP Model Appliction Transport Network Data Link We are Here 4

Network Layer Diagram shows at end points entire protocol stack implemented Need transport and applications layers for processes Routers only need layers up through network layer Data Link Network application transport network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical network data link physical application transport network data link physical Diagram of Differences Network vs. Transport 5

Two Key Network-Layer Functions Forwarding Move packets from router s input queues to router's output queues Movement is contained within router Routing Determine routing for packets from source to destination Routing algorithms important in efficiently routing packets Movement of packets is distributed 6

Routing vs. Forwarding Analogy You take a road trip across country, go through many highway interchanges Routing: Process of planning trip from source to destination Forwarding: Process of getting through single interchange

How Routing Works Every router has Forwarding Table Also called, Routing Table Router forwards packets by examining value in arriving packet header Uses value to index into router s forwarding table See following slide 8

Interplay between Routing and Forwarding Create Routing Table routing algorithm local forwarding table header value output link 0100 0101 0111 1001 3 2 2 1 All routers have routing tables Specify next hop in route value in arriving packet s header 0111 3 2 1 Built by routing algorithms 9

IP Datagram Delivery View at Data link Layer Internetwork collection of LANs or point-to-point links or switched networks that are connected by routers Ed R1 R2 Point-to-point link Point-to-point link H2 Ted Network of Ethernet switches Ethernet H1 IP R3 R4 Ethernet Token Ring LAN 10

11 IP Datagram Delivery View at IP Layer An IP network is a logical entity with a network number We represent an IP network as a cloud The IP delivery service takes the view of clouds, and ignores IP data link layer view R1 10.1.2.0/24 10.2.1.0/24 R2 20.1.0.0/16 20.2.1.0/28 H2 H1 10.1.0.0/24 10.3.0.0/16 R3 R4

12 Routing tables Each router keeps a routing table which tells the router how to process an outgoing packet Main columns Destination address: Where is IP datagram going to? Next hop: How to send the IP datagram? Interface: What is the output port? Routing tables help datagrams gets closer to its destination IP datagrams can be directly delivered ( direct ) or is sent to a router ( R4 ) Destination 10.1.0.0/24 10.1.2.0/24 10.2.1.0/24 10.3.1.0/24 20.1.0.0/16 20.2.1.0/28 Routing Table Next Hop direct direct R4 direct R4 R4 interface eth0 eth0 serial0 eth1 eth0 eth0

13 Delivery with routing tables Destination Next Hop 10.1.0.0/24 R3 10.1.2.0/24 direct 10.2.1.0/24 direct 10.3.1.0/24 R3 20.2.0.0/16 R2 30.1.1.0/28 R2 Destination Next Hop 10.1.0.0/24 R1 10.1.2.0/24 R1 10.2.1.0/24 direct 10.3.1.0/24 R4 20.1.0.0/16 direct 20.2.1.0/28 direct Destination Next Hop 10.1.0.0/24 R2 10.1.2.0/24 R2 10.2.1.0/24 R2 10.3.1.0/24 R2 20.1.0.0/16 R2 20.2.1.0/28 direct R1 R2 10.1.2.0/24 10.2.1.0/24 20.1.0.0/16 20.2.1.0/28 H2 20.2.1.2/28 to: 20.2.1.2 H1 10.1.0.0/24 10.3.1.0 10.3.0.0/16 R3 R4 Destination Next Hop 10.1.0.0/24 direct 10.1.2.0/24 R3 10.2.1.0/24 R3 10.3.1.0/24 R3 20.1.0.0/16 R3 20.2.1.0/28 R3 Destination Next Hop 10.1.0.0/24 direct 10.1.2.0/24 direct 10.2.1.0/24 R4 10.3.1.0/24 direct 20.1.0.0/16 R4 20.2.1.0/28 R4 Destination Next Hop 10.1.0.0/24 R3 10.1.2.0/24 R3 10.2.1.0/24 R2 10.3.1.0/24 direct 20.1.0.0/16 direct 20.2.1.0/28 R2

Two Service Models at Network Layer What services could network layer provide? Guarantee delivery, Guarantee bandwidth, Order packets, Time delay guarantee Given what you know of the Network layer, are any of these services implemented? No! Decided that network only does best effort delivery!! 14

Two Service Models at Network Layers However, you can try to emulate these services in network layer virtually Datagram service is what we typically have 1.Datagram service best effort, no previous connection setup Virtual service model lets you creatively obtain services other than best effort 2. Virtual Service tries to compensate for lack of guaranteed service, sets up connections ahead of time Example of Virtual Service ATM, Asynchronous Transfer Mode 15

Datagram Service Connectionless Unacknowledged Network Service Attitude to packets Characterized by Send and forget! Does not guarantee actual delivery Does not guarantee data is undamaged Does not guarantee data delivered in order Does not guarantee that only one copy of the data will be delivered 16

Virtual Service Sets Up... Source-to-destination path ahead of time Uses that route to send all packets Behaves much like telephone circuit Call setup, teardown for each call before data can flow Each packet carries VC identifier (not the same as a destination host address) Every router on source-destination path maintains state for each passing connection 17

Virtual Service Book discusses mechanics of a generic virtual service, Section 4.2 to be exact Have virtual identifiers instead of IP addresses Can run a virtual service over the Internet Routers need to recognize the virtual identifiers Two Examples: ATM and MPLS Asynchronous Transfer Mode http://www2.rad.com/networks/infrastructure/atm/main.htm Multiprotocol Label Switching http://www2.rad.com/networks/infrastructure/ipmpls/main.htm

Datagram Networks Basics No call setup at network layer Routers: No state about end-to-end connections No network-level concept of connection Packets forwarded using destination host address Packets between same source-dest pair may take application transport network data link physical different paths application transport 1. Send data 2. Receive data network data link physical 19

Datagram Networks No advance setup of paths, link to link connections Need a global number recognized by all network components, hosts and routers How would you set up routing tables in order to accommodate currently, over 4 billion entries? Question: Whats the best way to do this? 20

Routing Table Organization One dumb idea, global table 4 billion entries 2 32 But, didn't do that IP addresses assigned contiguous address blocks So, can use a matching algorithm and match the network prefix to route packets Have distributed address space More on addressing later... 21

Routers 22

Routers Internals Routers are the glue that holds the Internet together Router speeds greatly affect how well traffic gets moved around the network Performance of routers turns out to be critical Today, look at evolution of routers and the speedups that have occurred

Routers Commercial Realities A router is sold as one big box Cisco, Juniper, Redback, Avici, No standard interfaces between components Cisco switch, Juniper cards, and Avici software Vendors vs. Service providers Vendors: Build the routers and obey standards Providers: Buy the routers and configure them EWU is a provider

25 Routing Architectures A Router Consists of Ports Connections to wires to other network entities Switching fabric A network inside the router that transfers packets between ports Routing processor: Brain of the router...maintains lookup tables Switching Fabric Routing Processor ports

Router Architecture Overview Routers do two important things Builds and Maintains Routing Tables Performs Packet Switching and Updating Several input ports Several output ports 26

Input Port Functions Physical layer: bit-level reception Data link layer: Ethernet Process packet up to network layer Input Port Function: Given datagram destination lookup output port using forwarding table in input port memory 27

Input Port Functions Needs to perform lookup at line speed Gbps in most networks Example: OC-48 link runs at 2.5 Gbps (OC) Optical Carrier Digital signals that can be carried on SONET fiber optic network, different sizes If packets are 256 bytes Must lookup speeds of 1 Million lookups/sec Binary search typically done to speed things up And other methods... more later 28

29 Switching Fabrics Switching fabric is heart of a router Through switching that datagrams are actually moved from an input port to an output port Switching can be accomplished in a number of ways...

30 Three types of switching fabrics 1. 2. 3.

First Generation Switching Via Memory First generation routers Traditional computers with switching under direct control of CPU, act as router Packet copied to system s memory Speed limited by memory bandwidth 2 bus crossings per datagram, looks like shared memory multi-processors Input Port Memory Output Port System Bus CISCO Catalyst 8500's 31

Typically <0.5Gb/s aggregate capacity 32 First Generation Routers Shared Bus CPU Route Table Off-chip Buffer Buffer Memory CPU Memory Line Interface Line Interface Line Interface Line Interface MAC MAC MAC

33 First Generation Switching via Memory Comment Modern routers also switch via memory Difference from early routers Lookup of destination address and switching of packet in memory Performed by processors on input line cards Greatly speeds things up

2 nd Generation Switching Via a Bus Use shared bus No intervention by routing processor Since bus is shared Only one packet at a time can be transferred over bus Because every packet must cross single bus, switching bandwidth of router limited to bus speed. Bus contention: Switching speed limited by bus bandwidth, one packet at a time Also have buffer memory on the input cards! Example: 1 Gbps bus, Cisco 1900: sufficient speed for access and enterprise routers (not regional or backbone) 34

Second Generation Routers CPU Route Table Buffer Memory Shared bus Line Card Line Card Line Card Buffer Memory Fwding Cache Buffer Memory Fwding Cache Buffer Memory Fwding Cache Buffer Memory MAC MAC MAC Typically <5Gb/s aggregate capacity 35

Third Generation Crossbar Switch A crossbar switch is a matrix of switches between inputs and outputs Overcome bandwidth limitation of single, shared bus More sophisticated interconnection network Used in past to interconnect processors in a multiprocessor computer architectures 36

Crossbar Switch Crossbar switch Consists of 2N buses Connect N Input ports to N Output ports Packet arrives at input port travels along horizontal bus attached to input port until it intersects with vertical bus leading to desired output port If vertical bus leading to output port is free Packet is transferred to output port If vertical bus is being used to transfer a packet from another input port to same output port, Arriving packet is blocked and must be queued at the input port More on queuing later Paper on routers: http://www.cs.cmu.edu/~srini/15-744/f02/readings/mck97.html 37

Third Generation Routers Crossbar : Switched Backplane Line Card CPU Card Line Card Line Interface CPU Local Buffer Memory Routing Table Local Buffer Memory Memory Fwding Table Fwding Table MAC MAC Typically <50Gb/s aggregate capacity 38

39 Output Ports Output port processing Datagrams stored in output port's memory and transmits them over outgoing link Queuing and buffer management needed when switch fabric delivers packets to output port at a rate that exceeds output link rate Cover output port queuing below

Output Ports Here is where packets get dropped encapsulation Buffering required when datagrams arrive from fabric faster than transmission rate Scheduling algorithm chooses among queued datagrams for transmission Can be simple FIFO or some fairness algorithm based on destination packet distribution 40

Where Does Packet Queue Occur? Consider That... Packet queues can form at both input ports and output ports As queues grow large, router's buffer space will eventually be exhausted Packet loss will occur!!!

Input and Output Queues Question of Speeds Suppose that input line speeds and output line speeds are all identical, With n input ports and n output ports If switching fabric speed is at least n times as fast as the input line speed, Will queues form at input ports? NO.

Input and Output Queues What about output ports? Worst case, packets arrive at each n input ports will be destined to same output port In time it takes to receive (or send) a packet, n packets will arrive at this output port Since output port can only transmit a single packet in a unit of time (the packet transmission time), n arriving packets will have to queue (wait) for transmission over the outgoing link

Input and Output Queues If switch fabric is not fast enough (relative to input line speeds) to transfer all arriving packets through fabric without delay, then packet queuing will also occur at input ports If two packets at front of two input queues are destined to same output queue, then one packet will be blocked and must wait at input queue -

Input and Output Queues This phenomenon is known as Head-of-the-line (HOL) blocking Defined On an input-queued switch Queued packet in an input queue must wait for transfer through fabric due to blocking of another packet at head-of-the-line What would be one solution?

46 Solution: Virtual Output Queues Maintain N virtual queues at each input one per output Input 1 Input 2 Output 1 Output 2 Output 3 Input 3

47 Summary Multiple things can be done to enhance router performance Input cards Have own CPU processors Use caches for address lookup Have copies of routing tables Switch fabric Cross Switches faster - use parallelism to switch packets

Reading: Chapter 4 - Network Layer 48

1

24

32

35

38

46

47