0% found this document useful (0 votes)
20 views94 pages

Lecture 1 - Network Layer

Chapter 5 of 'Computer Networking' discusses the network layer, focusing on design issues such as packet switching, services to the transport layer, and routing algorithms. It covers connectionless and connection-oriented services, traffic management techniques, and quality of service requirements. The chapter also addresses internetworking, packet fragmentation, and the principles of software-defined networking.

Uploaded by

rlaehgus30605
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views94 pages

Lecture 1 - Network Layer

Chapter 5 of 'Computer Networking' discusses the network layer, focusing on design issues such as packet switching, services to the transport layer, and routing algorithms. It covers connectionless and connection-oriented services, traffic management techniques, and quality of service requirements. The chapter also addresses internetworking, packet fragmentation, and the principles of software-defined networking.

Uploaded by

rlaehgus30605
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 94

Computer Networking

Sixth edition

Chapter 5
The Network Layer

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Network Layer Design Issues

• Store-and-forward packet switching


• Services provided to the transport layer
• Implementation of connectionless service
• Implementation of connection-oriented service
• Comparison of virtual-circuit and datagram networks

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Store-and-Forward Packet Switching

The environment of the network layer protocols

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Services Provided to the Transport Layer

• Services independent of router technology


• Transport layer shielded from number, type, topology of
routers
• Network addresses available to transport layer use
uniform numbering plan
– Even across LANs and WANs

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Implementation of Connectionless Service

Routing within a datagram network

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Implementation of Connection-Oriented
Service

Routing within a virtual-circuit network

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Comparison of Virtual-Circuit and
Datagram Networks

Comparison of datagram and virtual-circuit networks

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Routing Algorithms in a Single Network
(1 of 3)

• Optimality principle
• Shortest path algorithm
• Flooding
• Distance vector routing
• Link state routing

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Routing Algorithms in a Single Network
(2 of 3)

• Hierarchical routing within a network


• Broadcast routing
• Multicast routing
• Anycast routing

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Routing Algorithms in a Single Network
(3 of 3)

Network with a conflict between fairness and efficiency

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The Optimality Principle

(a) A network. (b) A sink tree for router B.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Shortest Path Algorithm (1 of 2)

The first six steps used in computing the shortest path from A to D. The arrows indicate
the working node.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Shortest Path Algorithm (2 of 2)

Dijkstra’s algorithm to compute the shortest path through a graph

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Distance Vector Routing

(a) A network. (b) Input from A, I, H, K, and the new routing table for J.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The Count-to-Infinity Problem

The count-to-infinity problem

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Link State Routing

• Discover neighbors, learn network addresses


• Set distance/cost metric to each neighbor
• Construct packet telling all it has learned
• Send packet to, receive packets from other routers
• Compute shortest path to every other router

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Learning about the Neighbors

(a) Nine routers and a broadcast LAN. (b) A graph model of (a).

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Building Link State Packets

(a) A network. (b) The link state packets for this network.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Distributing the Link State Packets

The packet buffer for router B in Fig. 5-12(a)

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Hierarchical Routing within a Network

Hierarchical routing

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Broadcast Routing

Reverse path forwarding. (a) A network. (b) Sink tree for router I. (c) The tree built by
reverse path forwarding from I.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Multicast Routing (1 of 2)

(a) A network. (b) A spanning tree for the leftmost router. (c) A multicast tree for group 1.
(d) A multicast tree for group 2.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Multicast Routing (2 of 2)

(a) Core-based tree for group 1. (b) Sending to group 1.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Anycast Routing

(a) Anycast routes to group 1. (b) Topology seen by the routing protocol.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Traffic Management at the Network Layer

• The need for traffic management: congestion


• Approaches to traffic management
– Traffic-aware routing
– Admission control
– Load shedding
– Traffic shaping
– Active queue management
– Random early detection
– Choke packets
– Explicit congestion notification
– Hop-by-hop backpressure

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Congestion

Performance drops significantly in the presence of congestion: packet loss rates


increase, and latency also increases as router queues fill with packets

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Approaches to Traffic Management

Timescales of approaches to traffic and congestion management

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Traffic-Aware Routing

A network in which the East and West parts are connected by two links

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Admission Control

(a) A congested network. (b) The portion of the network that is not congested. A virtual
circuit from A to B is also shown.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Traffic Shaping (1 of 2)

(a) Shaping packets. (b) A leaky bucket. (c) A token bucket.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Traffic Shaping (2 of 2)

(a) Traffic from a host. Output shaped by a token bucket of rate 200 Mbps and capacity
(b) 9600 KB and (c) 0 KB. Token bucket level for shaping with rate 200 Mbps and
capacity (d) 16,000 KB, (e) 9600 KB, and (f) 0 KB.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Explicit Congestion Notification

Explicit congestion notification

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Hop-by-Hop Backpressure

(a) A choke packet that affects only the source. (b) A choke packet that affects each hop
it passes through.
Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Quality of Service and Application QoE

• Application QoS requirements


• Overprovisioning
• Packet scheduling
• Integrated services
– RSVP—The Resource reSerVation Protocol

• Differentiated services
– Expedited forwarding
– Assured forwarding

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Application QoS Requirements

Stringency of applications’ quality-of-service requirements

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Categories of QoS and Examples

• Constant bit rate


– Telephony

• Real-time variable bit rate


– Compressed videoconferencing

• Non-real-time variable bit rate


– Watching a movie on demand

• Available bit rate


– File transfer

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Overprovisioning

• Helps to provide good quality of service


– Ensure the network has the capacity for all traffic
– Expensive solution

• Network issues to address for quality of service


– Addressing applications needs
– Regulating traffic entering the network
– Reserving resources at routers to guarantee performance
– Safely accepting more traffic

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Packet Scheduling

• Router resources reserved for different flows


– Bandwidth
– Buffer space
– CPU cycles

• Algorithms
– First-In First-Out (FIFO) scheduling
– Fair queueing
– Weighted fair queueing
– Putting it together

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Fair Queueing (1 of 2)

Round-robin fair queueing

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Fair Queueing (2 of 2)

(a) Weighted Fair Queueing. (b) Finishing times for the packets.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Putting it Together (1 of 2)

An example flow specification

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Putting it Together (2 of 2)

Bandwidth and delay guarantees with token buckets and WFQ

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Integrated Services (1 of 2)

(a) A network. (b) The multicast spanning tree for host 1. (c) The multicast spanning tree
for host 2.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Integrated Services (2 of 2)

(a) Host 3 requests a channel to host 1. (b) Host 3 then requests a second channel, to
host 2. (c) Host 5 requests a channel to host 1.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Differentiated Services (1 of 2)

Expedited packets experience a traffic-free network

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Differentiated Services (2 of 2)

A possible implementation of assured forwarding

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Internetworking

• Internetworks: an overview
• How networks differ
• Connecting heterogeneous networks
• Connecting endpoints across heterogeneous networks
• Internetwork routing: routing across multiple networks
• Supporting different packet sizes: packet fragmentation

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
How Networks Differ

Some of the many ways networks can differ

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Connecting Heterogeneous Networks

(a) A packet crossing different networks. (b) Network and link layer protocol processing.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Connecting Endpoints Across
Heterogeneous Networks (1 of 2)

Tunneling a packet from Paris to London

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Connecting Endpoints Across
Heterogeneous Networks (2 of 2)

Tunneling a car from France to England

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Supporting Different Packet Sizes: Packet
Fragmentation (1 of 3)

(a) Transparent fragmentation. (b) Nontransparent fragmentation.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Supporting Different Packet Sizes: Packet
Fragmentation (2 of 3)

Fragmentation when the elementary data size is 1 byte. (a) Original packet, containing 10
data bytes. (b) Fragments after passing through a network with maximum packet size of
8 payload bytes plus header. (c) Fragments after passing through a size 5 gateway.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Supporting Different Packet Sizes: Packet
Fragmentation (3 of 3)

Path MTU discovery

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Software-Defined Networking

• Overview
• The SDN control plane: logically centralized software
control
• The SDN data plane: programmable hardware
• Programmable network telemetry

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Overview

Control and data plane separation in SDN

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The SDN Data Plane: Programmable
Hardware (1 of 2)

Reconfigurable match-action pipeline for a programmable data plane

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The SDN Data Plane: Programmable
Hardware (2 of 2)

Reconfigurable match-action pipelines on both ingress and egress

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The Network Layer in the Internet (1 of 3)

• Top 10 principles
– Make sure it works
– Keep it simple
– Make clear choices
– Exploit modularity
– Expect heterogeneity
– Avoid static options and parameters
– Look for a good design; it need not be perfect
– Be strict when sending and tolerant when receiving
– Think about scalability
– Consider performance and cost

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The Network Layer in the Internet (2 of 3)

• The IP Version 4 Protocol


• IP Addresses
• IP Version 6
• Internet control protocols
• Label switching and MPLS
• OSPF—An interior gateway routing protocol
• BGP—The exterior gateway routing protocol
• Internet multicasting

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The Network Layer in the Internet (3 of 3)

The Internet is an interconnected collection of many networks.

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The IP Version 4 Protocol (1 of 2)

The IPv4 (Internet Protocol version 4) header

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The IP Version 4 Protocol (2 of 2)

Some of the IP options

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
IP Addresses

• Prefixes
– A contiguous block of IP address space

• Subnets
• CIDR—Classless InterDomain Routing
• Classful and special addressing
• NAT—Network Address Translation

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Prefixes

A prefix and a subnet mask

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Subnets

Splitting an IP prefix into separate networks with subnetting

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
CIDR—Classless InterDomain Routing
(1 of 3)

A set of IP address assignments

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
CIDR—Classless InterDomain Routing
(2 of 3)

Aggregation of IP prefixes

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
CIDR—Classless InterDomain Routing
(3 of 3)

Longest matching prefix routing at the New York router

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Classful and Special Addressing (1 of 2)

IP address formats

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Classful and Special Addressing (2 of 2)

Special IP addresses

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
NAT—Network Address Translation

Placement and operation of a NAT box

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
IP Version 6 (1 of 3)

• The main IPv6 header


• Extension headers
• Controversies

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
IP Version 6 (2 of 3)

• IPv6 major goals


– Support billions of hosts
– Reduce routing table size
– Simplify the protocol
– Provide better security
– Attention to type of service
– Aid multicasting
– Roaming host without changing address
– Allow future protocol evolution
– Permit coexistence of old and new protocols for years

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
IP Version 6 (3 of 3)

• IP version 6 improvements
– Longer addresses than IPv4
– Simplification of the header
– Better support for options
– Big advance is in security
– Quality of service

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
The Main IPv6 Header

The IPv6 fixed header (required)

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Extension Headers (1 of 3)

IPv6 extension headers

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Extension Headers (2 of 3)

The hop-by-hop extension header for large datagrams (jumbograms)

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Extension Headers (3 of 3)

The extension header for routing

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Internet Control Protocols

• ICMP—The Internet Control Message Protocol


• ARP—The Address Resolution Protocol
• DHCP—The Dynamic Host Configuration Protocol

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
ICMP—The Internet Control Message
Protocol

The principal ICMP message types

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
ARP—The Address Resolution Protocol

Two switched Ethernet LANs joined by a router

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Label Switching and MPLS (1 of 3)

• MPLS (MultiProtocol Label Switching)


– Perilously close to circuit switching
– Adds a label in front of each packet
– Forwards based on the label (not the destination address)
– Forwarding can be done very quickly

• New MPLS header is added in front of the IP header

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Label Switching and MPLS (2 of 3)

Transmitting a TCP segment using IP, MPLS, and PPP

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Label Switching and MPLS (3 of 3)

Forwarding an IP packet through an MPLS network

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
OSPF—An Interior Gateway Routing
Protocol (1 of 4)

• Intradomain routing
– IGP (Interior Gateway Protocol)

• RIP (Routing Information Protocol)


– Works well in small systems

• OSPF (Open Shortest Path First)


– Widely used in company networks

• IS-IS (Intermediate-System to Intermediate-System)


– Widely used in ISP networks

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
OSPF—An Interior Gateway Routing
Protocol (2 of 4)

• OSPF
– Published in the open literature
– Supports a variety of distance metrics
– Dynamic
– Supports routing based on type of service
– Performs load balancing, splitting the load over multiple lines
– Supports hierarchical systems
– Provides security
– Provision for dealing with routers that were connected to the
Internet via a tunnel

• OSPF supports multiaccess networks

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
OSPF—An Interior Gateway Routing
Protocol (3 of 4)

(a) An autonomous system. (b) A graph representation of (a).

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
OSPF—An Interior Gateway Routing
Protocol (4 of 4)

The five types of OSPF messages

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
BGP—The Exterior Gateway Routing
Protocol (1 of 3)

• Possible routing constraints


– Do not carry commercial traffic on the educational network
– Never send traffic from the Pentagon on a route through Iraq
– Use TeliaSonera instead of Verizon because it is cheaper
– Don’t use AT&T in Australia because performance is poor
– Traffic starting or ending at Apple should not transit Google

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
BGP—The Exterior Gateway Routing
Protocol (2 of 3)

Routing policies between four autonomous systems

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
BGP—The Exterior Gateway Routing
Protocol (3 of 3)

Propagation of BGP route advertisements

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Interdomain Traffic Engineering

• Tune parameters and configuration network protocols to


manage utilization and congestion
• Inbound traffic engineering
– Selects routes to control how traffic enters the network
– Set the local preference attribute for individual routes
– Use AS path prepending
– Leverage longest prefix match
▪ Split a prefix into multiple smaller (longer) prefixes, so that upstream routers
prefer the routes with longer prefixes

• Outbound traffic engineering


– How traffic leaves the network

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved
Internet Multicasting

• Internet multicasting
– One-to-many communication using class D IP addresses

• Each class D address identifies a group of hosts


• Twenty-eight bits available for identifying groups
– Over 250 million groups can exist at the same time

• Process sends a packet to a class D address


– Best-effort attempt is made to deliver it to all the members of the
group addressed, but no guarantees are given

Copyright © 2020, 2011, 2003 Pearson Education, Inc. All Rights Reserved

You might also like