Вы находитесь на странице: 1из 102

HP Switching and Routing Technologies

Web-based Training Course Companion Version 10.41

Copyright 2010 Hewlett-Packard Development Company, L.P.

The information contained herein is subject to change without notice. The only warranties for HP products and services are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. HP shall not be liable for technical or editorial errors or omissions contained herein. This is an HP copyrighted work that may not be reproduced without the written permission of HP. You may not use these materials to deliver training to any person outside of your organization without the written permission of HP. HP Switching and Routing Technologies Web-based Training Course Companion Rev. 10.41

HP Switching and Routing Technologies

Introduction

Module 1 Objectives
This module will introduce you to some of the challenges involved in providing high-quality voice and video on an existing data network. After completing this module, you will be able to: Identify business and technological forces that have driven the development of converged networks Describe how HP networking products can meet converged network demand for high availability and predictability

Converged Applications Drive Infrastructure Enhancements


Organizations typically implement converged solutions to lower the costs of services like voice telephony and multimedia conferences, training, and presentations. At the same time, converged solutions enable greater flexibility by integrating services formerly carried on separate networks.

IP Telephony

Video conferencing and distance learning

Video surveillance

While these integrated applications enhance user productivity, they place additional requirements on the infrastructure i f Some applications may require the added flexibility provided by wireless access. Video application support can mean high bandwidth at the edge, with even higher bandwidth requirements at the distribution and core layers. Network devices must support controls that enable prioritized handling for time-sensitive traffic.

Rev. 10.41

1-1

HP Switching and Routing Technologies

Introduction

Convergence Requires High Availability 1


High availability is crucial in converged networks. Because all communication systems are concentrated in a single infrastructure, network outages would be particularly disruptive. HP networking products can enhance resilience on many levels by supporting: The Virtual Router Redundancy Protocol, which enables a standby router to automatically resume forwarding traffic if the p primary y default g gateway y fails The Spanning Tree Protocol, which blocks redundant switched links until a failure elsewhere may cause them to transition to the forwarding state Multiple Spanning Tree, which defines separate active paths per instance, enabling utilization of redundant links and devices that would otherwise remain inactive Instance 1 Primary default gateway Instance 2 Backup default gateway Instance 1 Backup default gateway Instance 2 Primary default gateway

Links that are active for Instance 1 Links that are active for Instance 2
Hosts in VLANs mapped to Instance 1 Hosts in VLANs mapped to Instance 2 Hosts in VLANs mapped to Instance 1 Hosts in VLANs mapped to Instance 2

Convergence Requires High Availability 2


Redundant routed links between distribution and core layer switches may be utilized if you select a routing protocol, such as OSPF, that supports Equal-Cost Multipath (ECMP). If both core switches in the example have access to the same resources, the distribution layer switches can forward traffic over both equal-cost paths. Connections to other resources and client systems

C Core layer l switches

Distribution layer y switches

Rev. 10.41

1-2

HP Switching and Routing Technologies

Introduction

Redundant Components in Network Devices


You can increase the availability of network devices by providing redundant hardware components within distribution and/or core switches. The HP E8200 switch series can be configured to provide resilience for hardware components. Redundant management module failover to hot standby module Resilient switch fabric modules system can tolerate the loss of one module Redundant, hot-swappable power supplies providing N+1 power protection are accessible from the rear of the unit Redundant management modules

Redundant power supplies

Resilient fabric modules

Real-time Traffic Requires Predictability


Real-time traffic, such as web video and VoIP, is far more sensitive to network congestion than typical IP data traffic. To be successful, a converged network must exhibit predictable behavior under all circumstances. In this example, devices within the network cloud experience varying levels of congestion. Consequently, some packets in the real real-time time data stream are delayed delayed. The outcome of the congestion is a variation in the interval between packet arrival, known as jitter, which results in a choppy voice or video stream. Network users who experience high jitter levels are likely to be dissatisfied with the performance of voice and video applications, producing the perception that the network is not functioning properly.

Host 1 Senders of real-time traffic transmit packets at fixed intervals.

Host 2 Receivers expect the packets to arrive at the same interval.

Rev. 10.41

1-3

HP Switching and Routing Technologies

Introduction

IP Telephony Traffic Requires Low Delay


Traffic sent by this IP phone must reach the receiver in a timely manner. However, a certain amount of delay is inevitable as a message is sent through the network. One-way delay is defined as the interval between the time the first bit in a packet is sent and the time it is received. Congestion can cause levels of delay that are unacceptable for IP telephony and video-conferencing applications A converged infrastructure must employ measures that limit delay applications. delay.

Phone 1

Phone 2

IP Telephony Requires Intelligence at the Edge


To minimize the effects of congestion on real-time traffic, a converged infrastructure requires intelligent devices at the edge and core layers. An HP networking edge switch and an IP phone negotiate parameters using a standardized mechanism known as Link Layer Discovery Protocol for Media Endpoint Devices (LLDP-MED).

LLDP-MED

The phone identifies itself as a VOIP ,p providing g manufacturer and device, other inventory information The phone adds appropriate 802.1Q tag and priority settings to the traffic it generates.

The switch dynamically places the IP phone in appropriate p pp p VLAN and reports the VLAN ID to the phone. Switch applies policies that will ensure voice quality.

You will learn more about LLDP-MED and other topics relating to Quality of Service in Module 6.

Rev. 10.41

1-4

HP Switching and Routing Technologies

Introduction

Module 1 Summary

In this module, you learned about traffic control and high availability features required to successfully support a converged network.

Rev. 10.41

1-5

HP Switching and Routing Technologies

Providing Redundant Links and Gateways

Module 2: Providing Redundant Links and Gateways


Objectives
Each hosts default gateway is crucial in enabling its communication with remote resources. This module will describe the operation of Version 2 of the Virtual Router Redundancy Protocol (VRRP v2) and its interaction with the Spanning Tree Protocol. After completing p g this module, ,y you will be able to: Describe the interactions among network devices that support VRRP v2 Describe how multiple spanning tree instances enable two layer 3 switches to share default gateway responsibilities

Lesson 1 Introduction: 1
The source and destination IP addresses do not change as packets make their way to the Server. Source and destination MAC addresses change with every router hop.

Server Router_x Dest. Source MAC header

Host1 Server Source Dest. IP header

Payload

10 119215 10.1.192.15

While the Layer 3 header on the packets from Host1 to the Server contains the actual source and destination IP addresses, the Layer 2 header indicates that traffic is destined for the Host1s default gateway, Router1.

All destinations outside 10.1.10.0/24

Router1

10.1.10.1/24
Router1 Host1 Dest. Source MAC header Host1 Server Source Dest. IP header Payload

Switch

Host 1 10.1.10.100/24 Gateway: 10.1.10.1

All IP hosts require a gateway in their local address range to reach non-local destinations.

Rev. 10.41

2-1

HP Switching and Routing Technologies

Providing Redundant Links and Gateways

Lesson 1 Introduction: 2
If this router, or the path between the host and the router, becomes unavailable, the hosts open sessions terminate. Even if an alternate path to remote destinations is available, the host may be unable to detect it. Regardless of the IP address assigned to the second router interface, its physical MAC address is different from that of the failed router interface. i t f The host will need to reconfigure its default gateway and establish new sessions. The replacement router interface cannot assume forwarding responsibility for open sessions. The Virtual Router Redundancy Protocol (VRRP) may be used to establish an active/standby model for default gateways, enabling the standby to resume forwarding responsibilities for existing sessions and those established subsequent to failure of the active gateway.
Switch Router1
All destinations outside 10.1.10.0/24

10 119215 10.1.192.15

Router2

10.1.10.2/24 Host 1 10.1.10.100/24 Gateway: 10.1.10.1

VRRP Terminology
Version 2 of the Virtual Router Redundancy Protocol (VRRP) , which is specified in RFC 3768, provides an industry standard for automatic default gateway failover. A VRRP virtual router is a set of router interfaces on the same network with a common: Virtual Router Identifier (VRID) Virtual IP Address The Owner is the router interface whose actual IP address matches the virtual IP address. Owner (Master)
Actual IP address: VLAN 10: 10.1.10.1/24
Router1

Non-owner (Backup)
Actual IP address: VLAN 10: 10.1.10.2/24
Router1

10.1.10.1

VLAN 10 - Virtual Router ID: 1 Virtual IP address: 10.1.10.1

10.1.10.1

VLAN 10 Host: 10.1.10.10/24 Default gateway: 10.1.10.1

Switch1

Rev. 10.41

2-2

HP Switching and Routing Technologies

Providing Redundant Links and Gateways

VRRP Virtual MAC Address


In addition to a virtual IP address, a virtual MAC address is assigned to each virtual router. The VRRP Master broadcasts a gratuitous ARP request that causes hosts on the VLAN to create an ARP cache entry associating the virtual IP address with the virtual MAC address.

00:00:5e:00:01:01 First 40 bits specified in RFC 3768 Last 8 bits = Virtual Router ID Non-owner (Backup)
Actual IP address: VLAN 10: 10.1.10.2/24
Router1

Owner (Master)
Actual IP address: VLAN 10: 10.1.10.1/24
Router1

10.1.10.1

VLAN 10 - Virtual Router ID: 1 Virtual IP address: 10.1.10.1 Virtual MAC: 00:00:5e:00:01:01

10.1.10.1

VLAN 10 Host: 10.1.10.10/24 Default gateway: 10.1.10.1

Switch1

Gratuitous ARP Request

Ethernet header: Destination: Broadcast ff:ff:ff:ff:ff:ff) Source: IETF-VRRP-Virtual-Router-VRID-01 IETF VRRP Virtual Router VRID 01 (00:00:5e:00:01:01) Type: ARP (0x0806) Address Resolution Protocol header: Virtual Router ID Hardware type: Ethernet Protocol type: IP Sender MAC Address: IETF-VRRP-Virtual-Router-VRID-01 (00:00:5e:00:01:01) Sender IP Address: 10.1.10.1 Target MAC Address: Broadcast (ff:ff:ff:ff:ff:ff) The defining characteristic of a Gratuitous ARP message is the Target IP Address: 10.1.10.1 combination of broadcast as the Target MAC address, and
Virtual IP Address

matching values for Source and Target IP address. address The message causes each host in this network to add the following association to its ARP cache: IP Address 10.1.10.1 = MAC Address 00:00:5e:00:01:01

Rev. 10.41

2-3

HP Switching and Routing Technologies

Providing Redundant Links and Gateways

VRRP Advertisements
The VRRP Master indicates its availability by sending periodic advertisements to the VRRP multicast address, which is 224.0.0.18. The VRRP Master broadcasts a gratuitous ARP request that causes hosts on the VLAN to create an ARP cache entry associating the virtual IP address with the virtual MAC address.

Master VLAN 10: 10.1.10.1/24


Router1

Backup VLAN 10: 10.1.10.2/24


Router1

VLAN 10 VRRP Advertisement


Switch1

VLAN 10 Host: 10.1.10.10/24 Default gateway: 10.1.10.1

VLAN 10 VRRP Advertisement

Ethernet header: Destination: 01:00:5e:00:00:12 Source: 00:00:5e:00:01:01 Type: IP (0x0800) IP datagram header: Protocol: VRRP (0x70) Source: 10.1.10.1 Destination: 224.0.0.18 Virtual Router Redundancy Protocol header: Version: 2 Packet type: Advertisement (1) Virtual Router ID: 1 P i it 255 Priority: Count IP Addrs: 1 Auth Type: No authentication (0) Advertisement Interval: 1 (sec) IP Address: 10.1.10.1
This advertisement is sent to the multicast address assigned to VRRP in RFC 3768

This priority level indicates that the originator of this message is the owner of the Virtual IP Address. A copy if this advertisement is sent once per second.

Rev. 10.41

2-4

HP Switching and Routing Technologies

Providing Redundant Links and Gateways

Load Sharing
VRRP routers often support multiple VRIDs. In this implementation shown in the diagram, either router can be Owner of any of the VRIDs. While the VRRP Backup for a given VLAN does not act as gateway for its hosts, the router interface is fully functional. Traffic that enters a router through a VRRP Master interface can be forwarded onto a different VLAN through a Backup interface.

VLAN 10: 10.1.10.1/24 (Owner) VLAN 20: 10.1.20.2/24 (Backup)


Router1

VLAN 10: 10.1.10.2/24 (Backup) VLAN 20: 10.1.20.1/24 (Owner)


Router2

10 110 1 10.1.10.1 10.1.20.1

VLAN 10 - VRID: 1: 10.1.10.1 Virtual MAC: 00:00:5e:00:01:01 VLAN 20 : VRID 2: 10.1.20.1 Virtual MAC: 00:00:5e:00:01:02

10 110 1 10.1.10.1 10.1.20.1

VLAN 10 Host: 10.1.10.10/24 Default gateway: 10.1.10.1

Switch1

VLAN 20 Host: 10.1.20.10/24 Default gateway: 10.1.20.1

VRRP Master Failover: 1


Router interfaces that are part of the same virtual router negotiate for the Master and Backup roles based on their priority settings. The Owner has the highest possible priority (255) and will always assume the role of Master. In the example below, Router1 is the Master for VLAN 10, and sends VRRP advertisements over that VLAN. Router2 is the Master for VLAN 20. VRRP Backup k routers l listen f for advertisements. d If f the h Master stops sending d advertisements, d the h Backup k assumes the Master role.
VLAN 10: 10.1.10.1/24 (Master) VLAN 20: 10.1.20.2/24 (Backup)
Router1

VLAN 10: 10.1.10.2/24 (Backup) VLAN 20: 10.1.20.1/24 (Master)


Router2

VLAN 10 Host: 10.1.10.10/24 Default gateway: 10.1.10.1

Switch1

VLAN 20 Host: 10.1.20.10/24 Default gateway: 10.1.20.1

Rev. 10.41

2-5

HP Switching and Routing Technologies

Providing Redundant Links and Gateways

VRRP Master Failover: 2


Router interfaces that are part of the same virtual router negotiate for the Master and Backup roles based on their priority settings. The Owner has the highest possible priority (255) and will always assume the role of Master. In the example below, Router1 is the Master for VLAN 10, and sends VRRP advertisements over that VLAN. Router2 is the Master for VLAN 20. VRRP Backup k routers l listen f for advertisements. d If f the h Master stops sending d advertisements, d the h Backup k assumes the Master role.
VLAN 10: 10.1.10.2/24 (Master) VLAN 20: 10.1.20.1/24 (Master)
Router1 Router2

VLAN 10 Host: 10.1.10.10/24 Default gateway: 10.1.10.1

Switch1

VLAN 20 Host: 10.1.20.10/24 Default gateway: 10.1.20.1

Lesson 2 Introduction
To enhance default gateway availability for client PCs, network designers often specify the use of redundant uplinks from edge switches to routers. Hosts in two VLANs are distributed over two edge switches. The edge switches have redundant uplinks to a pair of routing switches that will support VRRP. All switch-to-switch links are members of both user VLANs. This lesson will describe some challenges and solutions that arise when VRRP and the Spanning Tree Protocol (STP) are combined within the same domain.
VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 Bridge Priority 0 (Root) Router1
Tagged 10 20 10 10 20 20

VLAN 10: 10.1.10.2/24 VLAN 20: 10.1.20.2/24 Bridge Priority 4096 (Backup Root) Router2

Tagged

10 20 Tagged

Tagged

10 20

Tagged

Switch1 VLAN 10 Hosts: 10.1.10.0/24 VLAN 20 Hosts: 10.1.20.0/24 VLAN 10 Hosts: 10.1.10.0/24

Switch2

VLAN 20 Hosts: 10.1.20.0/24

Rev. 10.41

2-6

HP Switching and Routing Technologies

Providing Redundant Links and Gateways

VRRP Advertisements and Spanning Tree


The routing switch configured as Spanning Tree Root should be configured as VRRP Owner. The Master sends VRRP advertisements over each of link for each VLAN. When all links are up, the direct link between Master and Backup is the primary path for VRRP advertisements. If the path between the VRRP Master and Backup is disrupted, the Backup will assert itself as the Master and this will prevent proper VRRP operation. The h edge d switches, h Switch1 S h and d Switch2, S h2 cannot forward f d the h VRRP advertisements d toward d the h Backup k because their uplinks to the Backup are in the Spanning Tree Blocking state. For this reason, the direct Master-Backup link must carry all of the VLANs in this domain. Should this link become unavailable, the remaining links must carry the advertisements for all VLANs.
VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 Bridge Priority 0 (Root) Router1 VLAN 10: 10.1.10.2/24 VLAN 20: 10.1.20.2/24 Bridge Priority 4096 (Backup Root) Router2

B Switch1

B Switch2

Gateway Load Sharing in a Single Spanning Tree: 1


In a single Spanning Tree environment, a single active path carries traffic for all configured VLANs. For the efficiency of traffic flow, the Root of the tree should be the VRRP Master for all VLANs whose traffic is carried by the links in the tree. Because interfaces on Router1 serve as default gateway for both hosts, their traffic uses the same set of links in either direction.

VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 Bridge Priority 0 (Root)

Router1

HostB Router1 Dest. Source MAC header

HostA HostB Source Dest. IP header

Payload

VLAN 10: 10.1.10.2/24 VLAN 20: 10.1.20.2/24 Bridge Priority 4096 (Backup Root)

Router2

Router1 HostA Dest. Source MAC header

HostA HostB Source Dest. IP header

Payload

Router1 delivers the packet directly to Host B.

Because Router1 is Host As gateway, its MAC address appears in the packets Layer 2 header.

B Switch1 Host A: 10.1.10.10/24 Gateway: 10.1.10.1

B Switch2 Host B: 10.1.20.10/24 Gateway: 10.1.20.1

Rev. 10.41

2-7

HP Switching and Routing Technologies

Providing Redundant Links and Gateways

Gateway Load Sharing in a Single Spanning Tree: 2


In this load-sharing configuration, the VRRP Master for VLAN 20 does not correspond with the Spanning Tree Root. Consequently, the uplink between Switch2 and its default gateway (Router2) is blocked by Spanning Tree. Traffic between Host B and its default gateway must first be forwarded at Layer 2 through Router1 before reaching Router2. Router1 forwards the packet at Layer 2 because the destination MAC address is not its own address.

VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 Bridge Priority 0 (Root)

VLAN 10: 10.1.10.2/24 VLAN 20: 10.1.20.2/24 Bridge Priority 4096 (Backup Root)

Router1

Router2

HostA Router2 Dest. Source MAC header

HostB HostA Source Dest. IP header

Payload

Router1 forwards the packet to Router2 at Layer 2.

B Switch1 Host A: 10.1.10.10/24 Gateway: 10.1.10.1

HostA Router2 Dest. Source MAC header

HostB HostA Source Dest. IP header

Payload

Router2 is the default gateway for Host B. However, the uplink from Switch 2 to Router 2 is in Blocking state.

B Switch2 Host B: 10.1.20.10/24 Gateway: 10.1.20.1

Gateway Load Sharing in a Single Spanning Tree: 3


The link between Router2 and Switch1 is blocked by Switch1. However, Router2s interface to this network is in the Forwarding state, and this enables Router2 to forward the packet directly to Host A.

VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 Bridge Priority 0 (Root)

VLAN 10: 10.1.10.2/24 VLAN 20: 10.1.20.2/24 Bridge Priority 4096 (Backup Root)

Router1

Router2

HostA Router2 Dest. Source MAC header

HostB HostA Source Dest. IP header

Payload

Router2 forwards the packet to Host A through Switch1.

B Switch1 Host A: 10.1.10.10/24 Gateway: 10.1.10.1

B Switch2 Host B: 10.1.20.10/24 Gateway: 10.1.20.1

Rev. 10.41

2-8

HP Switching and Routing Technologies

Providing Redundant Links and Gateways

VRRP and Multiple Spanning Tree


The Multiple Spanning Tree Protocol (MSTP) enables definition of multiple spanning tree instances. Each Multiple Spanning Tree (MST) Instance can support a unique set of VLANs. Spanning Tree parameters are separately configured for each instance, enabling definition of a Root Bridge for each instance. g switches to share g gateway y responsibilities p for a set of VLANs. MSTP enables a set of routing
MST Instance 1: VLAN 10 Bridge Priority: 0 (Root) MST Instance 2: VLAN 20 Bridge Priority: 4096 (Backup Root) MST Instance 1: VLAN 10 Bridge Priority: 4096 (Backup Root) MST Instance 2: VLAN 20 Bridge Priority: 0 (Root)

Router1

Router2

B Switch1 Host A: 10.1.10.10/24 Gateway: 10.1.10.1

B Switch2 Host B: 10.1.20.10/24 Gateway: 10.1.20.1

Module 2 Summary
In this module, you learned the elements involved in the configuration of VRRP and MSTP. Topics included: The roles of Master and Backup routers in transmitting and receiving VRRP v2 advertisements Interactions I t ti among VRRP advertisements d ti t and d links li k blocked bl k d b by S Spanning i T Tree How the configuration of Multiple Spanning Tree instances enables routers to share gateway responsibilities

Rev. 10.41

2-9

HP Switching and Routing Technologies

IP Routing

Module 3: IP Routing
Objectives
A routing switch forwards traffic between its interfaces to enable communication among any combination of local and remote networks. After completing this module, you will be able to: Categorize the possible sources of routing information. information Describe how an IP router makes a forwarding decision when a packets destination matches with multiple route table entries. List the differences between automatic and manual summarization of remote IP address space. Describe how a router determines which route to place in its route table when the same address range is advertised by different routing protocols or methods.

Lesson 1 Introduction
While Layer 2 switches enable connectivity among devices within a network, the function of a router or Layer 3 switch is to interconnect networks. It uses a packets Layer 3 information to determine which of its interfaces leads to the destination, and creates a new Layer 2 header for each packet it forwards forwards. Routers may pass traffic between a pair of hosts located on directly connected networks. The packets Layer 2 header contains the MAC address of the interface that provides default gateway service for Network 1. The router removes the existing Layer 2 header and creates a new header with HostBs MAC address as the destination. A router may participate in forwarding traffic destined for remote hosts. The new Layer 2 header contains the MAC address of the next router on the path to the destination host.
RouterA

S it h2 Switch2

HostB: Network 2

Network 3 Switch1 RouterA

HostA: Network 1

HostC: Network 4

Rev. 10.41

3-1

HP Switching and Routing Technologies

IP Routing

Local Networks and the IP Route Table


Router interfaces are configured with an IP address and mask. When the router boots, it derives the range of addresses on its connected networks by applying the configured mask to each interface address. The mask 255.255.255.0 indicates that the first 24 bits of the IP address represent the network portion. The last 8 bits represent the host portion of the address. For each interface whose state is up, p, the router p places its network address range g into the IP route table.

A router forwards traffic destined for local networks using the interface indicated in the IP route table. The router drops traffic destined for address ranges not in the table.

Router interface 1: IP address: 10.1.10.1/24 Subnet mask: 255.255.255.0 Hosts in the range: 10.1.20.0/24

R RouterA A

Router interface 2: IP address: 10.1.20.1/24 Subnet mask: 255.255.255.0 Hosts in the range: 10.1.20.0/24

Router Interface Types


Routers often support a variety of interface types in addition to the port-based interfaces shown on the previous screen. These may include: VLAN interfaces, which are considered up if at least one port member of the VLAN is active Loopback interfaces, which are always considered up because they are not bound to any physical interfaces
VLAN 10 interface: 10.1.10.1/24 VLAN 20 interface: 10.1.20.1/24

Loopback 0: 10.1.0.25

RouterA

Switch1

Hosts in the range 10.1.20.0/24

Hosts in the range 10.1.10.0/24

Rev. 10.41

3-2

HP Switching and Routing Technologies

IP Routing

Dynamic Routing Protocols


A router can learn about the existence of remote networks through dynamic interaction with neighboring routers. Routers that share information must follow a common protocol, which is set of rules for exchanging routing information. gp y specify: p y Routing protocols may Procedures for establishing neighbor relationships The format of messages exchanged between neighbors Conditions or events that require the routers to send updated information

VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10 10.1.100.1/24 1 100 1/24 Loop 0: 10.1.0.25/32

RouterA

10.1.10.0/24 10.1.20.0/24 10.1.0.25/32

10.1.30.0/24 10.1.40.0/24 10.1.0.26/32 VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 Loop 0: 10.1.0.26/32

RouterB

Static Route Configuration


Routers can also learn about remote networks by static configuration. In this example, two VLANs are directly connected to each router. The routers are connected by the network 10.1.100.0/24. An administrator specifies the remote address range and the next hop toward the destination. ip route 10.1.30.0/24 10.1.100.2 1
This command, issued at the CLI of RouterA, provides information the router will use to forward traffic toward the destination network 10.1.30.0/24
VLAN 10: 10 10.1.10.1/24 1 10 1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 Loop 0: 10.1.0.25/32

RouterA

VLAN 100: 10.1.100.1/24

This command, Th d issued d at the h CLI of f RouterB, R B provides d information the router will use to forward traffic toward the destination network 10.1.10.0/24

ip route 10.1.10.0/24 10.1.100.1 1 Network topology, including Internet and intranet connectivity, determine appropriate methods for each situation.

VLAN 100: 10.1.100.2/24 VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 Loop 0: 10.1.0.26/32

RouterB

Rev. 10.41

3-3

HP Switching and Routing Technologies

IP Routing

Routing Protocol Categories


Dynamic interaction between routers falls into two basic categories. 1. Interior Gateway Protocols (IGP) facilitate the exchange of information among routers under the same organizational control; that is, within the same Autonomous System (AS). Common examples of standard IGPs include: 2. Routing Information Protocol (RIP) Open Shortest Path First (OSPF)
AS 200 ABC Corp BGP/ IS-IS OSPF AS 100 ABC Corp - Europe

BGP

Exterior Gateway Protocols (EGP) facilitate the exchange of route information among routers in different Autonomous Systems. Border Gateway Protocol version 4 (BGP4) is i the h current standard d d EGP for Internet connectivity Internet Service Providers often use an IGP, such as IS-IS, within their own networks to enable connectivity among BGP routers.

BGP

RIP AS 300 ABC Corp - Japan

Standard Interior Gateway Protocols: 1


Standard Interior Gateway Protocols include: 1. Routing Information Protocol (RIP) is a distance vector protocol. Each router sends periodic updates, based on its own route table. table Information about remote networks is passed from router to router, with costs incrementing with each hop.
Network 1 cost 1 Network 2 cost 1
Network 3

Network k 1 cost 2 Network 2 cost 2 Network 3 cost 1


Network 4

Route table Destination D ti ti C t Next Cost N th hop Network 1 3 Router2 Network 2 3 Router2 Network 3 2 Router2 Network 4 1 connected

Rev. 10.41

3-4

HP Switching and Routing Technologies

IP Routing

Standard Interior Gateway Protocols: 2


Standard Interior Gateway Protocols include: 1. Routing Information Protocol (RIP) is a distance vector protocol. Each router sends periodic updates, based on its own route table. table Information about remote networks is passed from router to router, with costs incrementing with each hop. 2. Open Shortest Path First (OSPF) is a link state protocol. Each router reports to its neighbors the characteristics of its active connections to local networks networks. Updates are flooded, unchanged, to all routers within an administratively defined area, and the routers store the information. Each router uses this first-hand information to calculate its shortest path to each address range.
Link-state database Router Networks R1 Network 1 Network 2 R2 Network 3 R3 Network 4 R1 advertisement
Network 3

R1 advertisement
Network 4

Link-state algorithm runs on database contents, producing IP route table entries.

Lesson 2 Introduction
The Routing Information Protocol (RIP) is easy to configure, and is suitable for small- to medium-sized networks. Each router reports its known routes and their cost, to its neighbors The information is passed from one router to neighbors. another, with costs incrementing at every hop. RIPs main disadvantage is slow convergence. Changes in routing topology may propagate slowly because the information is acquired from routers that may be as many as 15 hops away. In this lesson, you will learn RIPs rules and how to p RIP routes as they y appear pp in the route table. interpret

Rev. 10.41

3-5

HP Switching and Routing Technologies

IP Routing

RIP Advertisements: 1
The Routing Information Protocol (RIP) uses a distancevector algorithm to determine the best path to each destination. Routers periodically advertise their route table entries g , or p peers. to RIP neighbors, The advertisements contain a list of known address ranges (vectors), each of which is paired with the cost (distance) of the entire path to the address range.
VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 Loop 0: 10.1.0.25/32

RouterA

10.1.100.1/24

10.1.100.2/24 VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 Loop 0: 10.1.0.26/32

RouterB

RIP Advertisements: 2
VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 Loop 0: 10.1.0.25/32

Ethernet header: Dest: 01005e-000009 Source: <RouterA MAC> IP datagram d t h header: d Protocol: UDP Source: 10.1.100.1 Dest: 224.0.0.9 UDP header: Source: 520 (RIP) Dest: 520 (RIP)
RIP v2 updates are sent to a reserved multicast address

RouterA

10.1.100.1/24
R I P

Routing Information Protocol: Command: Response (2) Version: RIPv2 (2) Network: 10.1.0.25 Mask: 255.255.255.255 Metric: 1 Network: 10.1.10.0 Mask: 255.255.255.0 Metric: 1 Network: 10.1.20.0 Mask: 255.255.255.0 Metric: 1 Ethernet trailer: <Checksum value>

This router is configured to use split horizon loop prevention. It does not include 10.1.100.0/24, which is the address range associated with the network that carries this RIP update.

U D P I P M A C

10.1.100.2/24 VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 Loop 0: 10.1.0.26/32

RouterB

Rev. 10.41

3-6

HP Switching and Routing Technologies

IP Routing

Updating the Route Table


Before RouterB receives the RIP advertisement from RouterA, its route table contains only directly connected networks. When it receives RouterAs RIP advertisement, RouterB integrates the address ranges into its route table, and increments the advertised i t th d ti d costs. t
IP Route Table: RouterB Destination 10.1.0.25/32 10.1.0.26/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10 1 100 0/24 10.1.100.0/24 Gateway 10.1.100.1 lo0 10.0.100.1 10.0.100.1 VLAN30 VLAN40 VLAN100 100 VLAN 100 100 100 30 40 100 Type rip connected rip rip connected connected connected d Metric 2 1 2 2 1 1 1 VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 Loop 0: 10.1.0.25/32

RouterA

10.1.100.1/24

These networks were advertised with a cost of 1.

10.1.100.2/24 VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 Loop 0: 10.1.0.26/32

RouterB

Generating RIP Advertisements:1


The router generates a unique advertisement to send over each of its RIP interfaces, based on the content of its route table. The advertisement RouterB sends to RouterC includes its own connected networks and those it learned from RouterA.
RouterA

10.1.100.1/24

IP Route Table: RouterB


Destination 10.1.0.25/32 10.1.0.26/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 0. . 00.0/ 10.1.100.0/24 Gateway 10.1.100.1 lo0 10.0.100.1 10.0.100.1 VLAN30 VLAN40 VLAN100 00 VLAN 100 100 100 30 40 100 00 Type rip connected rip rip connected connected co connected ected Metric 2 1 2 2 1 1 1

Connected networks: VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 Loop 0: 10.1.0.27/32

10.1.100.2/24

RouterC

.1

10.1.101.0/24

.2

RouterB

Rev. 10.41

3-7

HP Switching and Routing Technologies

IP Routing

Generating RIP Advertisements: 2


The router generates a unique advertisement to send over each of its RIP interfaces, based on the content of its route table. The advertisement RouterB sends to RouterC includes its own connected RIP advertisement : RouterB - VLAN 101 interface -10.1.101.2 networks and those it learned from RouterA.
Ethernet header: Dest: 01005e-000009 Source: <RouterB MAC> IP datagram header: Protocol: UDP IP Route Table: RouterB Source: 10.1.101.2 Dest: 224.0.0.9 Destination VLAN Type Metric UDP header: Gateway 10.1.0.25/32 10.1.100.1 100 rip 2 Source: 520 (RIP) Dest: 520 (RIP) 10.1.0.26/32 lo0 connected 1 Routing Information Protocol: 10.1.10.0/24 10.0.100.1 100 rip 2 Command: Response (2) Version: RIPv2 rip (2) 10.1.20.0/24 10.0.100.1 100 2 Network: 10.1.0.25 Mask: 255.255.255.255 Metric: 21 10.1.30.0/24 VLAN30 30 connected Network: 10.1.0.26 Mask: 255.255.255.255 Metric: 11 10.1.40.0/24 VLAN40 40 connected Network: 10.1.10.0 Mask: 255.255.255.0 Metric: 2 1 / 10.1.100.0/24 VLAN100 100 connected Network: 10.1.20.0 Mask: 255.255.255.0 Metric: 2 Network: 10.1.30.0 Mask: 255.255.255.0 Metric: 1 Network: 10.1.40.0 Mask: 255.255.255.0 Metric: 1 Network: 10.1.100.0 Mask: 255.255.255.0 Metric: 1 Connected networks:
VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 Loop 0: 10.1.0.27/32

RouterA

10.1.100.1/24

10.1.100.2/24

RouterC

.1

10.1.101.0/24

.2

RouterB

Adding RIP Routes to the Table


RouterC integrates the advertised address ranges into its route table, incrementing the costs.
RouterA
IP Route Table: RouterC Destination 10.1.0.25/32 10.1.0.26/32 10.1.0.27/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.50.0/24 10.1.60.0/24 10.1.100.0/24 10.1.101.0/24 Gateway 10.1.101.2 l0.1.101.2 lo0 10.1.101.2 10.0.101.2 10.0.101.2 10.0.101.2 VLAN50 VLAN60 10.0.101.2 VLAN101 VLAN 100 100 100 100 100 100 50 60 100 101 Type rip rip connected rip rip rip rip connected connected rip connected Metric 3 2 1 3 3 2 2 1 1 2 1 10.1.100.1/24

Connected networks: VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 Loop 0: 10.1.0.27/32

10.1.100.2/24

RouterC

.1

10.1.101.0/24

.2

RouterB

Rev. 10.41

3-8

HP Switching and Routing Technologies

IP Routing

Adding a Redundant Routed Link


When another link is added, RouterC receives RIP updates from RouterA that advertise a shorter path to some destinations. The router increments the advertised cost of each network within the update, and compares this value with the cost associated with the network in the route table.
IP Route Table: RouterC
Destination 10.1.0.25/32 10.1.0.26/32 10.1.0.27/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.50.0/24 10.1.60.0/24 10.1.100.0/24 10.1.101.0/24 Gateway 10.1.101.2 l0.1.101.2 lo0 10.1.101.2 10.0.101.2 10.0.101.2 10.0.101.2 VLAN50 VLAN60 10.0.101.2 VLAN101 VLAN 100 100 100 100 100 100 50 60 100 101 Type rip rip connected rip rip rip rip connected connected rip connected Metric 3 2 1 3 3 2 2 1 1 2 1

RouterA

.2

.1

Connected networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 VLAN 102 102: 10 10.1.102.2/24 1 102 2/24 Loop 0: 10.1.0.25/32

10.1.102.0/24 10.1.100.0/24

.1

.2

Connected networks: VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 VLAN 102: 10.1.102.1/24 Loop 0: 10.1.0.27/32

RouterC
.1

RouterB
10.1.101.0/24
.2

Connected networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 VLAN 101: 10.1.101.2/24 Loop 0: 10.1.0.26/32

Replacing Route Table Entries: 1


The router replaces entries whose calculated cost is lower than the cost for that network in the route table. When replacing route table entries, the router updates the value in the Gateway field to match the Source address field in the IP datagram header.
IP Route Table: RouterC
Destination 10.1.0.25/32 10.1.0.26/32 10.1.0.27/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.50.0/24 10.1.60.0/24 10.1.100.0/24 10.1.101.0/24 Gateway 10.1.101.2 l0.1.101.2 lo0 10.1.101.2 10.0.101.2 10.0.101.2 10.0.101.2 VLAN50 VLAN60 10.0.101.2 VLAN101 VLAN 100 100 100 100 100 100 50 60 100 101 Type rip rip connected rip rip rip rip connected connected rip connected Metric 3 2 1 3 3 2 2 1 1 2 1

RouterA

.2

.1

Connected networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 VLAN 102 102: 10 10.1.102.2/24 1 102 2/24 Loop 0: 10.1.0.25/32

10.1.102.0/24 10.1.100.0/24

.1

.2

Connected networks: VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 VLAN 102: 10.1.102.1/24 Loop 0: 10.1.0.27/32

RouterC
.1

RouterB
10.1.101.0/24
.2

Connected networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 VLAN 101: 10.1.101.2/24 Loop 0: 10.1.0.26/32

Rev. 10.41

3-9

HP Switching and Routing Technologies

IP Routing

Replacing Route Table Entries: 2


The router replaces entries whose calculated cost is lower than the cost for that network in the route table. When replacing route table entries, the router updates the value in the RouterA Gateway field to match the Source address field in the IP IP datagram header: Protocol: UDP datagram header.
IP Route Table: RouterC
Destination 10.1.0.25/32 10.1.0.26/32 10.1.0.27/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.50.0/24 10.1.60.0/24 10.1.100.0/24 10.1.101.0/24 Gateway 10.1.102.2 l0.1.101.2 lo0 10.1.102.2 10.0.102.2 10.0.101.2 10.0.101.2 VLAN50 VLAN60 10.0.101.2 VLAN101 VLAN 102 100 102 100 100 100 50 60 100 101 Type rip rip connected rip rip rip rip connected connected rip connected Metric 2 2 1 2 2 2 2 1 1 2 1

Connected networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 Source: 10.1.102.2 Dest: 224.0.0.9 VLAN 102 102: 10 10.1.102.2/24 1 102 2/24 UDP header: .2 (RIP) .1 Loop Source: 520 Dest: 520 (RIP) 0: 10.1.0.25/32
Routing Information Protocol: Network: 10.1.0.25 Mask: 255.255.255.255 Metric: 1 Network: 10.1.0.26 Mask: 255.255.255.255 Metric: 2 Network: 10.1.0.27 Mask: 255.255.255.255 Metric: 3 Network: 10.1.10.0 Mask: 255.255.255.0 Metric: 1 Network: 10.1.20.0 Mask: 255.255.255.0 Metric: 1 Network: 10.1.30.0 Mask: 255.255.255.0 Metric: 2 Network: 10.1.40.0 Mask: 255.255.255.0 Metric: 2 10.1.100.0/24 Network: 10.1.50.0 Mask: 255.255.255.0 Metric: 3 Network: 10.1.60.0 Mask: 255.255.255.0 Metric: 3 Network: 10.1.100.0 Mask: 255.255.255.0 Metric: 1 Network: 10.1.101.0 Mask: 255.255.255.0 Metric: 2

RIP advertisement : RouterA int 10.1.102.2

.1

.2

Connected networks: VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 VLAN 102: 10.1.102.1/24 Loop 0: 10.1.0.27/32

RouterC
.1

RouterB
10.1.101.0/24
.2

Connected networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 VLAN 101: 10.1.101.2/24 Loop 0: 10.1.0.26/32

Split Horizon Loop Protection: 1


Following Split Horizon rules, RouterCs subsequent RIP advertisements to RouterA will omit the routes it has learned through its connection to RouterA.
RouterA
Connected networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 VLAN 102 102: 10 10.1.102.2/24 1 102 2/24 Loop 0: 10.1.0.25/32

IP Route Table: RouterC


Destination 10.1.0.25/32 10.1.0.26/32 10.1.0.27/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.50.0/24 10.1.60.0/24 10.1.100.0/24 10.1.101.0/24 Gateway 10.1.102.2 l0.1.101.2 lo0 10.1.102.2 10.0.102.2 10.0.101.2 10.0.101.2 VLAN50 VLAN60 10.0.101.2 VLAN101 VLAN 102 100 102 100 100 100 50 60 100 101 Type rip rip connected rip rip rip rip connected connected rip connected Metric 2 2 1 2 2 2 2 1 1 2 1

.2

.1

10.1.102.0/24 10.1.100.0/24

.2

Connected networks: VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 VLAN 102: 10.1.102.1/24 Loop 0: 10.1.0.27/32

RouterC
.1

.1 10.1.101.0/24 .2

RouterB

Connected networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 VLAN 101: 10.1.101.2/24 Loop 0: 10.1.0.26/32

Rev. 10.41

3 - 10

HP Switching and Routing Technologies

IP Routing

Split Horizon Loop Protection: 2


Following Split Horizon rules, RouterCs subsequent RIP advertisements to RouterA will omit the routes it has learned through its connection to RouterA. Split Horizon can decrease convergence time in a meshed topology.
IP Route Table: RouterC
Destination 10.1.0.25/32 10.1.0.26/32 10.1.0.27/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.50.0/24 10.1.60.0/24 10.1.100.0/24 10.1.101.0/24 Gateway 10.1.102.2 l0.1.101.2 lo0 10.1.102.2 10.0.102.2 10.0.101.2 10.0.101.2 VLAN50 VLAN60 10.0.101.2 VLAN101 VLAN 102 100 102 100 100 100 50 60 100 101 Type rip rip connected rip rip rip rip connected connected rip connected Metric 2 2 1 2 2 2 2 1 1 2 1

RouterA

.2

.1

Connected networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 VLAN 102 102: 10 10.1.102.2/24 1 102 2/24 Loop 0: 10.1.0.25/32

10.1.102.0/24 10.1.100.0/24

RIP advertisement : RouterC int 10.1.102.1

Connected networks: VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 VLAN 102: 10.1.102.1/24 Loop 0: 10.1.0.27/32

RouterC
.1

.1

Network: 10.1.0.26 Mask: 255.255.255.255 Metric: 2 Network: 10.1.0.27 Mask: 255.255.255.255 Metric: 1 .2 Network: 10.1.30.0 Mask: 255.255.255.0 Metric: 2 Network: 10.1.40.0 Mask: 255.255.255.0 Metric: 2 Connected networks: RouterB Network: 10.1.50.0 Mask: 255.255.255.0 1 VLAN Metric: 30: 10.1.30.1/24 10.1.101.0/24 Network: 10.1.60.0 Mask: 255.255.255.0 Metric: 1 VLAN 40: 10.1.40.1/24 .2 Network: 10.1.100.0 Mask: 255.255.255.0 Metric: 2 VLAN 100: 10.1.100.2/24 Network: 10.1.101.0 Mask: 255.255.255.0 Metric: 1 VLAN 101: 10.1.101.2/24 Loop 0: 10.1.0.26/32

Poisoned Reverse Loop Protection: 1


Poisoned reverse is a variation on split horizon. Instead of omitting routes it learned from a neighbor, the RIP updates advertise these routes are advertised with a cost of 16, which means unavailable.
RouterA
Connected networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 VLAN 102 102: 10 10.1.102.2/24 1 102 2/24 Loop 0: 10.1.0.25/32

.2

.1

IP Route Table: RouterC


Destination 10.1.0.25/32 10.1.0.26/32 10.1.0.27/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.50.0/24 10.1.60.0/24 10.1.100.0/24 10.1.101.0/24 Gateway 10.1.102.2 l0.1.101.2 lo0 10.1.102.2 10.0.102.2 10.0.101.2 10.0.101.2 VLAN50 VLAN60 10.0.101.2 VLAN101 VLAN 102 100 102 100 100 100 50 60 100 101 Type rip rip connected rip rip rip rip connected connected rip connected Metric 2 2 1 2 2 2 2 1 1 2 1 10.1.102.0/24 10.1.100.0/24

.2

Connected networks: VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 VLAN 102: 10.1.102.1/24 Loop 0: 10.1.0.27/32

RouterC
.1

.1 10.1.101.0/24 .2

RouterB

Connected networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 VLAN 101: 10.1.101.2/24 Loop 0: 10.1.0.26/32

Rev. 10.41

3 - 11

HP Switching and Routing Technologies

IP Routing

Poisoned Reverse Loop Protection: 2


Poisoned reverse is a variation on split horizon. Instead of omitting routes it learned from a neighbor, the RIP updates advertise these routes are advertised with a cost of 16, which means unavailable. RouterC poisons the routes it has learned from RouterA only within the advertisements it sends to RouterA. The updates RouterC sends to RouterB will advertise these routes with actual costs from its route table. In certain I t i meshed h dt topologies, l i poisoned i d reverse can i improve convergence speed when compared with split horizon.
IP Route Table: RouterC
Destination 10.1.0.25/32 10.1.0.26/32 10.1.0.27/32 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.50.0/24 10.1.60.0/24 10.1.100.0/24 10.1.101.0/24 Gateway 10.1.102.2 l0.1.101.2 lo0 10.1.102.2 10.0.102.2 10.0.101.2 10.0.101.2 VLAN50 VLAN60 10.0.101.2 VLAN101 VLAN 102 100 102 100 100 100 50 60 100 101 Type rip rip connected rip rip rip rip connected connected rip connected Metric 2 2 1 2 2 2 2 1 1 2 1

RouterA

.2

.1

Connected networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 100: 10.1.100.1/24 VLAN 102 102: 10 10.1.102.2/24 1 102 2/24 Loop 0: 10.1.0.25/32

RIP advertisement : RouterC int 10.1.102.1 Network: 10.1.0.26 Mask: 255.255.255.255 Metric: 16 10.1.102.0/24 Network: 10.1.0.26 Mask: 255.255.255.255 Metric: 2 Network: 10.1.0.27 Mask: 255.255.255.255 Metric: 1 Network: 10.1.10.0 Mask:10.1.100.0/24 255.255.255.0 Metric: 16 Network: 10.1.20.0 Mask: 255.255.255.0 Metric: 16 Network: 10.1.30.0 Mask: 255.255.255.0 Metric: 2 N t Network: k 10 10.1.40.0 1 40 0 M Mask: k 255 255.255.255.0 255 255 0 M Metric: ti 2 Network: 10.1.50.0 Mask: 255.255.255.0 Metric: 1 Network: 10.1.60.0 Mask: 255.255.255.0 Metric: 1 Network: 10.1.100.0 Mask: 255.255.255.0 Metric: 2 Network: 10.1.101.0 Mask: 255.255.255.0 Metric: 1 .2

Connected networks: VLAN 50: 10.1.50.1/24 VLAN 60: 10.1.60.1/24 VLAN 101: 10.1.101.1/24 VLAN 102: 10.1.102.1/24 Loop 0: 10.1.0.27/32

RouterC
.1

.1 10.1.101.0/24 .2

RouterB

Connected networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 100: 10.1.100.2/24 VLAN 101: 10.1.101.2/24 Loop 0: 10.1.0.26/32

RIP Automatic Summarization: 1


Routers A, B, and C are connected to another set of routers whose network addresses are within a different classful network." Router D has interfaces in both classful networks, so its route table shows individual subnets within each of the networks. Router D summarizes all of the address space within 172.16.0.0/16 in the RIP updates it sends over VLAN 100. It advertises individual networks within the 10.0.0.0/8 range because the address associated with the VLAN 100 is within that range.
Loop 0: 172.16.0.26/32 VLAN 30: 172.16.30.1/24 VLAN 40: 172.16.40.1/24 VLAN 101: 172.16.101.1/24 VLAN 102: 172.16.102.2/24 RouterD 172.16.102.0/24 Loop 0: 172.16.0.27/32 VLAN 50: 172.16.50.1/24 VLAN 102: 172.16.102.1/24 RouterA

172.16.101.0/24

Loop 0: 172.16.0.25/32 VLAN 10: 172.16.10.1/24 VLAN 20: 172.16.20.1/24 VLAN 100: 10.0.100.1/24 VLAN 101: 172.16.101.2/24

RouterD

RouterA

RIP advertisement : RouterC int 10.1.102.1 Network: 10.0.100.0 Mask: 255.255.255.0 Metric: 16 Network: 10.1.0.25 Mask: 255.255.255.255 Metric: 16 Network: 10.1.0.26 Mask: 255.255.255.255 Metric: 16 Network: 10.1.0.27 Mask: 255.255.255.255 Metric: 16 Network: 10.1.10.0 Mask: 255.255.255.0 Metric: 16 Network: 10.1.20.0 Mask: 255.255.255.0 Metric: 16 Network: 10.1.101.0 Mask: 255.255.255.0 Metric: 16 Network: 172.16.0.0 Mask: 255.255.0.0 Metric: 1

.1 10.0.100.0/24

RouterC

RouterB

Rev. 10.41

3 - 12

HP Switching and Routing Technologies

IP Routing

RIP Automatic Summarization: 2


Routers A, B, and C are connected to another set of routers whose network addresses are within a different classful network." Router D has interfaces in both classful networks, so its route table shows individual subnets within each of the networks. Router D summarizes all of the address space within 172.16.0.0/16 in the RIP updates it sends over VLAN 100. It advertises individual networks within the 10.0.0.0/8 range because the address associated with the VLAN 100 is within that range.
Loop 0: 172.16.0.26/32 VLAN 30: 172.16.30.1/24 VLAN 40: 172.16.40.1/24 VLAN 101: 172.16.101.1/24 VLAN 102: 172.16.102.2/24 RouterD 172.16.102.0/24 Loop 0: 172.16.0.27/32 VLAN 50: 172.16.50.1/24 VLAN 102: 172.16.102.1/24 RouterA

172.16.101.0/24 .2 RouterD RouterA

Loop 0: 172.16.0.25/32 VLAN 10: 172.16.10.1/24 VLAN 20: 172.16.20.1/24 VLAN 100: 10.0.100.1/24 VLAN 101: 172.16.101.2/24

When it sends RIP updates over VLAN 101, 101 Router D uses a single advertisement to summarize the address space within 10.0.0.0/8. It advertises individual networks within the 172.16.0.0/16 range because the address associated with the VLAN 101 is within that range.

RIP advertisement : RouterC int 172.16.101.2 172 16 101 2


10.0.100.0/24 Network: 10.0.0.0 Mask: 255.0.0.0 Metric: 1 Network: 172.16.0.25 Mask: 255.255.255.255 Metric: 1 Network: 172.16.0.26 Mask: 255.255.255.255 Metric: 16 Network: 172.16.0.27 Mask: 255.255.255.255 Metric: 16 Network: 172.16.10.0 Mask: 255.255.255.0 Metric: RouterC RouterB 1 Network: 172.16.20.0 Mask: 255.255.255.0 Metric: 1 Network: 172.16.30.0 Mask: 255.255.255.0 Metric: 16 Network: 172.16.102.0 Mask: 255.255.255.0 Metric: 16

Lesson 3 Introduction
Dynamic routing protocols may need to be selectively enabled to control the flow of routing updates. Static routes may be selectively used in place of dynamic updates to minimize unnecessary overhead. In this lesson, you will learn how to summarize contiguous address space using static routes.

Rev. 10.41

3 - 13

HP Switching and Routing Technologies

IP Routing

Dynamic Route Exchange


This diagram illustrates a hierarchical topology that requires all traffic between locations to transit the core. Routers at locations A, B, and C advertise each of their networks to neighbor routers in the intranet core. Routers in the intranet core advertise to each location the networks in all other locations. Without further RIP configuration, each router will need to support up to 1,024 route table entries.
RIP updates

Intranet core range: 10.0.0.0/16

Location C range: 10.3.0.0/16

Location A range: 10.1.0.0/16

Location B range: 10.2.0.0/16

The Effect of Large IP Route Tables


Dynamic routing updates have the benefit of providing routers with the information they need to find the best path to a given destination. However, the unrestricted flow of a large number of dynamic routing updates can impact performance in two important ways: 1 A large number of RIP update packets sent at frequent 1. intervals can impact network performance. Each RIP update interval (default: 30 seconds) may require several update packets to contain all of the networks to be advertised. 2. A large number of route table entries can impact router performance. Modern router architecture typically relies on packet q to minimize occasions when cache and other techniques packets must be submitted to the entire route table for lookup. However, when the router performs a lookup on the first packet in a flow, a smaller route table is more desirable.
0101 0110 0101 0001 0111 1101 0001 0111 0011 1101 0 1 0 1 0 0 1 0 1 0 010 110 010 010 000 010 010 010 010 010 010 000 010 010 110 000 110 011 110 000 101 111 101 101 101 101 101 101 101 101 010 010 110 010 000 010 010 010 010 010 0101 0 010 010 101 010

Rev. 10.41

3 - 14

HP Switching and Routing Technologies

IP Routing

Using a Default Static Route


There is another important reason to restrict dynamic routing updates between each location and the intranet core in this scenario: Locations A, B, and C use a single pointto-point link to reach all remote destinations This fact makes it destinations. unnecessary to maintain details regarding the networks at other locations. All 4 billion addresses in the IP address space may be summarized as the default route: 0.0.0.0/0.
This router interface provides the next hop for the static default route.

Intranet core range: 10.0.0.0/16

Networks 10.3.0.0/24 10.3.0.255.0/24

Define static default route here

Location A range: 10.1.0.0/16

Location B range: 10.2.0.0/16

Summarization by Location
The intranet core routers in this example can also use a static routes to summarize remote address space. Routers in the intranet core will be configured with a static route for each address range. The next hop for each range will be a neighboring router interface at the remote location. Network summarization requires that all networks within the summarized range must be reachable through the next hop router interface.

Intranet core range: 10 0 0 0/16 10.0.0.0/16

RC

Location C range: 10.3.0.0/16

RA

RB

Location A range: 10 1 0 0/16 10.1.0.0/16

Location B range: 10 2 0 0/16 10.2.0.0/16

Rev. 10.41

3 - 15

HP Switching and Routing Technologies

IP Routing

Redundant Static Routes


Many routers and routing switches support configuration of multiple static routes that specify the same destination. If static routes are defined with different costs, the router will send all traffic to the next hop defined in the lowest lowest-cost cost route route. Higher-cost routes will be used only after failure of lower cost routes. A routers use of equal-cost static routes will depend on whether it supports a feature typically referred to as ECMP, or Equal-Cost MultiPath. HP Networking E-series routing switches support load sharing for equal-cost static routes.
RA1 RA2 RB1

Intranet core range: 10.0.0.0/16

RC2 RC1

Location C range: 10.3.0.0/16

RB2

Location A range: 10.1.0.0/16

Location B range: 10.2.0.0/16

Most Specific Route Table Match


Route table entries specify a range of addresses that are defined using a starting address and mask. Some entries represent a single network, a VLAN or broadcast domain. Other entries may specify an address range that corresponds with a larger range of addresses. When a packet is submitted for lookup, its destination address is compared with the contents of the route y match with multiple p entries. table. It may When a packet matches with multiple route table entries, it is forwarded using the gateway associated with the entry that has the longest mask. This is also referred to as the most specific match. All destinations match with the default route (0.0.0.0/0). The router discards packets that do not match any entries.
Th Three entries in this h route table bl match with the destination 10.1.1.15. IP Route Table
Destination 0.0.0.0 10.0.100.0/24 10.1.0.0/16 10.1.1.0/24 10.1.2.0/24 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.64.0/24 10.2.0.0/16 Gateway 10.0.100.100 VLAN100 10.0.102.1 VLAN1 VLAN2 10.1.64.2 10.1.64.2 VLAN30 VLAN40 VLAN64 10.0.100.2 VLAN 100 100 102 1 2 64 64 30 40 64 100 Type static connected static connected connected rip rip connected connected connected static Metric 1 1 1 1 1 3 3 1 1 1 1 Distance 1 0 1 0 0 120 120 0 0 0 1

This is the most specific match for the destination 10.1.1.15.

Rev. 10.41

3 - 16

HP Switching and Routing Technologies

IP Routing

Administrative Distance
Each routing protocol applies its own interpretation to the metric value. Administrative distance provides a way for administrators to assign preference to one source of routing information over another. Administrative distances may be modified from the system defaults.
IP Route Table
Destination 0.0.0.0 10.0.100.0/24 10.1.0.0/16 10.1.1.0/24 10.1.2.0/24 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 10.1.64.0/24 10.2.0.0/16 Gateway 10.0.100.100 VLAN100 10.0.102.1 VLAN1 VLAN2 10.1.64.2 10.1.64.2 VLAN30 VLAN40 VLAN64 10.0.100.2 VLAN 100 100 102 1 2 64 64 30 40 64 100 Type static connected static connected connected rip rip connected connected connected static Metric 1 1 1 1 1 3 3 1 1 1 1 Distance 1 0 1 0 0 120 120 0 0 0 1

Default administrative distances for this router: Directly connected networks: 0 Static routes: 1 RIP-learned routes: 120 OSPF-learned OSPF learned routes: 1 10

Static Route Redistribution into RIP


In the example, the static route is defined on Router A1, which is the router whose neighbor leads to the remote address range 10.0.0.0/16. Router A1 will advertise static routes within h its RIP update d messages if f RIP redistribution is enabled.
Router A1: IP Route Table
Destination 0.0.0.0 10.1.1.0/24 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10 1 40 0/24 10.1.40.0/24 ... 10.1.64.0/24 Gateway 10.0.100.100 VLAN1 10.1.64.2 10.1.64.2 VLAN30 VLAN40 VLAN64 VLAN 100 1 64 64 30 40 64 Type static connected rip rip connected connected connected Metric 1 1 3 3 1 1 1 Distance 1 0 120 120 0 0 0

Address range: 10.0.0.0/16

Static route was defined here: ip route 0.0.0.0/0 10.0.100.100 Router A2: IP Route Table
Destination 0.0.0.0 10.1.1.0/24 10.1.10.0/24 10.1.20.0/24 10.1.30.0/24 10.1.40.0/24 ... 10.1.64.0/24 Gateway 10.1.64.1 VLAN1 VLAN10 VLAN20 10.1.64.1 10.1.64.1 VLAN64 VLAN 64 1 64 64 64 64 64 Type rip connected rip rip rip connected connected Metric 2 1 3 3 2 1 1 Distance 120 0 120 120 120 0 0

A1

A3

Address range: 10.1.0.0/16


A5

A2 A4

Rev. 10.41

3 - 17

HP Switching and Routing Technologies

IP Routing

Module 3 Summary
This module described basic IP routing concepts as they apply to forwarding among local and remote networks. Topics included: IP route table interpretation The categories of IP routing protocols RIP advertisements Using static routes to summarize address space

Rev. 10.41

3 - 18

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Module 4: Open Shortest Path First (OSPF)


Objectives
An intranet with redundant routed links will make the best use of the resilient design when it uses the OSPF routing protocol, which can quickly respond to changes in link states. After completing this module, you will be able to: Describe OSPF characteristics that make it suitable to resilient resilient, large-scale intranets intranets. Describe how routing information propagates throughout an OSPF domain. List OSPF router roles and the significance each has to sharing routing information. Explain the functions of the OSPF message types. Describe the OSPF area types and their proper uses. Describe how remote address space is summarized within an OSPF domain.

Lesson 1 Introduction
OSPF has several advantages over RIP. 1. OSPF scales to larger intranets. OSPF interfaces may be assigned metrics that are sensitive to the supported bandwidth. E h router Each t i is able bl t to consider id li link k speed d when h selecting the shortest path to a given destination. OSPF does not place a specific limit on network diameter. 2. OSPF router advertisements are more reliable. An OSPF router advertisement describes the type, cost, and network address associated with its connected networks. An OSPF router floods advertisements from its neighbors to all other neighbors intact, without changing the contents of the advertisements.
Network B Cost 10 Network C Cost 100

R1

Network N t kA Cost 100

Rev. 10.41

4-1

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

OSPF Hierarchy: Routers and Networks


OSPF routers: Are uniquely identified by a 32-bit dotted decimal value. Establish a formal relationship, known as adjacency, with neighbors OSPF networks are identified by a starting address and mask.
10.0.100.0/24

OSPF Router 10.0.0.32 VLAN 100: 10.1.100.1 p 0: 10.0.0.32 Loop


10.0.0.32

All five routers are neighbors on this network.

OSPF Router 10.1.0.32 VLAN 100: 10.0.100.2 Loop 0: 10.1.0.32/32

10.1.0.32

10.2.0.32

OSPF Router 10.2.0.32 VLAN 100: 10.0.100.4 Loop 0: 10.2.0.32/32

OSPF Router 10.1.0.33 VLAN 100: 10.0.100.3 Loop 0: 10.1.0.33/32

10.1.0.33

10.2.0.33

OSPF Router 10.2.0.33 VLAN 100: 10.0.100.5 Loop 0: 10.2.0.33/32

OSPF Network Types and Adjacency


Adjacency is a two-way relationship between a pair of OSPF routers that enables them to share routing information. For the purposes of forming adjacency, an OSPF network is classified by the number of neighbors it will support. A point-to-point network can support at most two router interfaces. The routers will form an adjacency. A multi-access network, such as Ethernet, can support more than two router interfaces. The q to create a full number of connections required mesh of point-to-point adjacencies increases significantly as neighbors are added.
A full mesh would require 10 point-topoint adjacencies N * (N 1)/2

Rev. 10.41

4-2

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Designated Router and Backup Designated Router


OSPF routers with interfaces on multiaccess networks may not always form a full adjacency with all neighbors. A Designated Router (DR) is elected for each multi-access network. The DR forms an adjacency with all neighbors on the network. An elected Backup Designated Router (BDR) also becomes adjacent with all neighbors on the network. Non-DRs are adjacent to the DR and BDR, but do not become adjacent to each other.
DR BDR

OSPF Hierarchy: Areas


The next level of OSPF hierarchy is the area. Areas are identified by a dotted decimal number. OSPF area boundaries define the scope of certain types of link state advertisements. IP address space may be summarized at area boundaries. Each network can belong to only one area. The router interfaces connected to a given network can form adjacencies only if they agree on its Area ID ID. The highest level in the hierarchy is the Autonomous System (AS), which is a collection of OSPF areas under common administration.
Area ea 1.0.0.0 .0.0.0 OSPF Autonomous System (AS) Area 0.0.0.0

Area ea 2.0.0.0 .0.0.0

Rev. 10.41

4-3

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Area Border Routers (ABR): 1


OSPF areas are interconnected by area border routers (ABR). Area border routers are configured with at least one interface in the Autonomous System backbone backbone area, which interconnects all other areas and uses the reserved ID 0.0.0.0.
OSPF Autonomous System (AS) Area 0.0.0.0

Area 1.0.0.0

Area ea 2.0.0.0 .0.0.0

Area Border Routers (ABR): 2


ABRs maintain adjacencies with neighbors in two different areas.
10.0.100.0/24 / 10.0.100.0/24 /

OSPF Router 10.1.0.32 Area 0.0.0.0 Networks: VLAN 100: 10.0.100.2/24 / Area 1.0.0.0 Networks: Loop 0: 10.1.0.32/32 VLAN 64: 10.1.64.1/24 VLAN 65: 10.1.65.1/24 VLAN 67: 10.1.67.1/24

10.1.64.0/24 10.1.67.0/24 10.1.65.0/24 10.1.66.0/24 10.1.68.0/24

OSPF Router 10.1.0.33 Area 0.0.0.0 Networks: VLAN 100: 10.0.100.3/24 / Area 1.0.0.0 Networks: Loop 0: 10.1.0.33/32 VLAN 64: 10.1.64.2/24 VLAN 66: 10.1.66.1/24 VLAN 68: 10.1.68.1/24

OSPF Router 10.1.0.34 Area 1.0.0.0 Networks: p 0: 10.1.0.34/32 / Loop VLAN 65: 10.1.65.2/24 VLAN 68: 10.1.68.2/24 VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24

10.1.10.0/24 10.1.20.0/24

All interfaces of each non-ABR are located within the same area.

10.1.30.0/24 10.1.40.0/24

OSPF Router 10.1.0.35 Area 1.0.0.0 Networks: oop 0: 10.1.0.35/32 0. .0.35/3 Loop VLAN 66: 10.1.66.2/24 VLAN 67: 10.1.67.2/24 VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24

Rev. 10.41

4-4

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

OSPF Router Startup


When OSPF is activated on a router, it generates a link state advertisement (Router LSA) that describes the characteristics of its connected networks. This advertisement, which is indexed by the unique Router , is stored in a database and transmitted to the routers ID, neighbors after they have begun to form an adjacency. Most routers enable static configuration of a Router ID. In the absence of static configuration, many routers will choose an address associated with the routers loopback interface.
Router ID: 10.1.0.25 Area 1.0.0.0 Link State Database Router LSA (1) Link State Advertisement Type: Link State ID: 10.1.0.25 Advertising g Router: 10.1.0.25 Number of Links: 4 Type: Stub ID: 10.1.0.25 Type: Stub ID: 10.1.10.0 Type: Stub ID: 10.1.20.0 Type: Stub ID: 10.1.64.0
OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 RouterA
ID: 10.1.0.25

Data: 255.255.255.255 Metric: 1 Data: 255.255.255.0 Metric: 1 Data: 255.255.255.0 Metric: 1 Data: 255.255.255.0 Metric: 1

ID: 10.1.0.26

RouterB

The networks are considered Stub type because the router has no adjacent neighbors on these networks.

Exchanging Hello Messages: 1


Link state advertisements can flow only over adjacencies. This makes adjacency establishment an important initial goal for each OSPF interface. The Hello message is the first step in establishing adjacency. In the example, RouterA has four connected g over all networks. The router will send Hello messages active interfaces.
Ethernet header: Dest: 01005e-000005 Source: <RouterA MAC> IP datagram header: Protocol: 89 (OSPF) Source: 10.1.64.1 Dest: 224.0.0.5
OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 RouterA
ID: 10.1.0.25

O S P F I P M A C

OSPF Hello messages are sent to a reserved multicast address

OSPF Header: OSPF Version: 2 Message Type: Hello packet (1) Source OSPF Router: 10.1.0.25 Area: 1.0.0.0 OSPF Hello Packet Header: Network Mask: 255.255.255.0 This router has no Hello interval: 10 seconds neighbors on this Router Priority: 1 network. It assumes the Router Dead Interval: 40 seconds role of Designated Router. Designated Router: 10.1.64.1 Backup Designated Router: 0.0.0.0

ID: 10.1.0.26

RouterB

Rev. 10.41

4-5

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Exchanging Hello Messages: 2


Link state advertisements can flow only over adjacencies. This makes adjacency establishment an important initial goal for each OSPF interface. The Hello message is the first step in establishing adjacency. In the example, RouterA has four connected g over all networks. The router will send Hello messages active interfaces. RouterA continues sending periodic Hello packets indefinitely, regardless of whether any neighboring routers reply with Hello packets. When OSPF is enabled on RouterB, it begins sending Hello messages as well.
OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 RouterA
ID: 10.1.0.25

O S P F I P M A C

ID: 10.1.0.26

RouterB

Synchronizing Link State Databases


Link state advertisements can flow only over adjacencies. This makes adjacency establishment an important initial goal for each OSPF interface. The Hello message is the first step in establishing adjacency. In the example, RouterA has four connected networks The ro networks. router ter will send Hello messages over o er all active interfaces. RouterA continues sending periodic Hello packets indefinitely, regardless of whether any neighboring routers reply with Hello packets. When OSPF is enabled on RouterB, it begins sending Hello messages as well.
OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 RouterA
ID: 10.1.0.25

O S P F I P M A C

ID: 10.1.0.26

RouterB

Rev. 10.41

4-6

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Synchronizing Link State Databases: 1


A goal of adjacency is the initial synchronization of the contents of the two neighbors link state databases. In the next phase of adjacency formation, each router describes the contents of its link state database by sending the headers of its stored link state advertisements (LSA) within Database Description packets. packets RouterA sends its LSA headers, and RouterB compares the neighbors headers with those in its own database.
OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 RouterA
ID: 10.1.0.25

Database Description Packet

OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 Loop 0: 10.1.0.26/32

ID: 10.1.0.26

RouterB

Synchronizing Link State Databases: 2


A goal of adjacency is the initial synchronization of the contents of the two neighbors link state databases. In the next phase of adjacency formation, each router describes the contents of its link state database by sending the headers of its stored link state advertisements (LSA) within Database Description packets. packets RouterA sends its LSA headers, and RouterB compares the neighbors headers with those in its own database.
Ethernet header: Dest: <RouterB MAC> Source: <RouterA MAC> IP datagram header: Protocol: 89 (OSPF) Source: 10.1.64.1 Dest: 10.1.64.2 OSPF Header: OSPF Version: 2 Message Type: DB Descr. (2) Source OSPF Router: 10.1.0.25 Area: 1.0.0.0 Database Description Header: LSA Type: Router LSA (1) Link State ID: 10.1.0.25 Advertising Router: 10.1.0.25 LS Sequence Number: 80000000 OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 RouterA
ID: 10.1.0.25

Database Description Packet

Database Description packets are sent to the neighbors unicast IP address.

These items identify this message as the first instance of the Router LSA advertised by Router ID 10.1.0.25.

OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 Loop 0: 10.1.0.26/32

ID: 10.1.0.26

RouterB

Rev. 10.41

4-7

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Synchronizing Link State Databases: 4


A goal of adjacency is the initial synchronization of the contents of the two neighbors link state databases. In the next phase of adjacency formation, each router describes the contents of its link state database by sending the headers of its stored link state advertisements (LSA) within Database Description packets. packets RouterA sends its LSA headers, and RouterB compares the neighbors headers with those in its own database. RouterB sends a Link State Request packet, requesting LSAs that are not in its own database, and RouterA sends a Link State Update packet containing its own self-originated Router LSA.
Link-state R Request t Packet OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 Loop 0: 10.1.0.26/32
ID: 10.1.0.26

OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32

RouterA
ID: 10.1.0.25

Link-state Update Packet

RouterB

Synchronizing Link State Databases: 5


Link State Request Packet

Ethernet header: Dest: <RouterA MAC> Source: <RouterB MAC> IP datagram header: Protocol: 89 (OSPF) Source: 10.1.64.2 Dest: 10.1.64.1 OSPF Header: OSPF Version: 2 Message Type: LS Request (3) Source OSPF Router: 10.1.0.26 Area: 1.0.0.0 Link State Request Header: LSA Type: Router LSA (1) Link State ID: 10.1.0.25 10 1 0 25 Advertising Router: 10.1.0.25 LS Sequence Number: 80000000

RouterB includes header information for the LSAs required to synchronize its database with RouterA.

Rev. 10.41

4-8

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Synchronizing Link State Databases: 6


Link State Update Packet
Ethernet header: Dest: <RouterB MAC> Source: <RouterA MAC> IP datagram header: Protocol: 89 (OSPF) Source: 10.1.64.1 10 1 64 1 Dest: 10.1.64.2 10 1 64 2 OSPF Header: OSPF Version: 2 Message Type: LS Update (4) Source OSPF Router: 10.1.0.25 Area: 1.0.0.0 LS Update Packet: Number of LSAs: 1 LS Type: Router-LSA Link State ID: 10.1.0.25 Advertising Router: 10.1.0.25 10 1 0 25 LS Sequence Number: 80000000 Number of Links: 4 Type: Stub ID: 10.1.0.25 Type: Stub ID: 10.1.10.0 Type: Stub ID: 10.1.20.0 Type: Stub ID: 10.1.64.0

While the Database Description and Link State Request packets include only LSA headers, the Link State Update packet provides detail about the advertising routers connected networks.

Data: Data: Data: Data:

255.255.255.255 255.255.255.0 255.255.255.0 255.255.255.0

Metric: 1 Metric: 1 Metric: 1 Metric: 1

Synchronizing Link State Databases: 7


A goal of adjacency is the initial synchronization of the contents of the two neighbors link state databases. In the next phase of adjacency formation, each router describes the contents of its link state database by sending the headers of its stored link state advertisements (LSA) within Database Description packets. packets RouterA sends its LSA headers, and RouterB compares the neighbors headers with those in its own database. RouterB sends a Link State Request packet, requesting LSAs that are not in its own database, and RouterA sends a Link State Update packet containing its own self-originated Router LSA. Database synchronization occurs concurrently in both directions during adjacency formation. RouterB describes its database contents to RouterA. RouterA RouterA requests LSAs LSAs, and RouterB provides them. After both routers have explicitly acknowledged receipt of the Link State Update packets, adjacency is complete.
OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 Loop 0: 10.1.0.26/32 Link-state Acknowledgment A k l d t Packet
ID: 10.1.0.26

OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32

RouterA
ID: 10.1.0.25

RouterB

Rev. 10.41

4-9

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Synchronizing Link State Databases: 8


Link State Acknowledgment Packet
Ethernet header: Dest: <RouterA MAC> Source: <RouterB MAC> IP datagram header: Protocol: 89 (OSPF) S Source: 10 1 64 2 Dest: 10.1.64.2 D t 10.1.64.1 10 1 64 1 OSPF Header: OSPF Version: 2 Message Type: LS Acknowledge (5) Source OSPF Router: 10.1.0.26 Area: 1.0.0.0 Link State Request Header: LSA Type: Router LSA (1) Link State ID: 10.1.0.25 Advertising Router: 10.1.0.25 LS S Sequence N Number: b 80000000

Like the Link State Request, the acknowledgment contains LSA header information. If RouterA does not receive an acknowledgment, it will retransmit the Link State Update.

The Network LSA: 1


In this example, only two routers are connected over an Ethernet network. However, Ethernet is considered a multiaccess network type, and this requires the election of a Designated Router and Backup Designated Router. You can issue CLI commands that will display the routers role on a multi-access network. This information is also included in Hello messages sent by any neighbor on the network.
Ethernet header: Dest: 01005e-000005 Source: <RouterA MAC> IP datagram header: Protocol: 89 (OSPF) Source: 10.1.64.1 Dest: 224.0.0.5 OSPF Header: OSPF Version: 2 Message g Type: yp Hello p packet (1) ( ) Source OSPF Router: 10.1.0.25 Area: 1.0.0.0 OSPF Hello Packet Header: Network Mask: 255.255.255.0 Hello interval: 10 seconds Router Priority: 1 Router Dead Interval: 40 seconds Designated Router: 10.1.64.1 Backup Designated Router: 10.1.64.2 Active Neighbor: 10.1.0.26
OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 L 0 10 1 0 25/32

RouterA
ID: 10.1.0.25

Hello

Hello OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 Loop 0: 10.1.0.26/32
ID: 10.1.0.26

RouterA is the Designated Router for this network.

RouterB

Rev. 10.41

4 - 10

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

The Network LSA: 2


In this example, only two routers are connected over an Ethernet network. However, Ethernet is considered a multiaccess network type, and this requires the election of a Designated Router and Backup Designated Router. You can issue CLI commands that will display the routers role on a multi-access network. This information is also included in Hello messages sent by any neighbor on the network. As soon as these routers have completed forming their adjacency, the elected Designated Router (DR) generates a second LSA type, known as a Network LSA. Adjacent neighbors must always have synchronized link state databases. This requirement causes the DR to immediately send the new Network LSA to its neighbors.
OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 L 0 10 1 0 25/32

RouterA
ID: 10.1.0.25

OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 Loop 0: 10.1.0.26/32

ID: 10.1.0.26

RouterB

The Network LSA: 3


In this example, only two routers are connected over an Ethernet network. However, Ethernet is considered a multiaccess network type, and this requires the election of a Designated Router and Backup Designated Router.
Area 1.0.0.0 Link State Database OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 L 0 10 1 0 25/32

Router ID: 10.1.0.25

Number of Links: 4 As soon routers have completed forming their Type: Stub as (3) these Link ID: 10.1.0.25 Link Data: 255.255.255.255 Type: Stub (3) the elected Link ID: 10.1.10.0 Link Data: 255.255.255.0 adjacency, Designated Router (DR) generates Type: Stub (3) Link ID: 10.1.20.0 Link Data: 255.255.255.0 a second LSA type, known as a Network LSA. Type: Transit (2) Link ID: 10.1.64.1 Link Data: 10.1.64.1 Router LSA (1)have synchronized link LinkAdjacent State Advertisement Type: neighbors must always Link State ID: 10.1.0.26 state databases. This requirement causes the DR to Advertising Router: 10.1.0.26 immediately Number of Links: 4 send the new Network LSA to its neighbors. Type: Stub (3) Link ID: 10.1.0.26 Link Data: 255.255.255.255 T Type: St Stub b (3) Li k ID Link ID: 10 10.1.30.0 1 30 0 Link Li k D Data: t 255 255.255.255.0 255 255 0 Type: Stub (3) Link ID: 10.1.40.0 Link Data: 255.255.255.0 Type: Transit (2) Link ID: 10.1.64.2 Link Data: 10.1.64.1 Link State Advertisement Type: Network LSA (2) Link State ID: 10.1.64.1 Advertising Router: 10.1.0.25 Netmask: 255.255.255.0 Attached Router: 10.1.0.25 Attached Router: 10.1.0.26

You can issue CLI commands that will display the routers role Link State Advertisement Type: Router LSA (1) a ID: multi-access Linkon 10.1.0.25 State 10 1 0 25 network. This information is also included in Hello messages sent by any neighbor on the network. Advertising Router: 10.1.0.25
Metric: 1 Metric: 1 Metric: 1 Metric: 1

RouterA
ID: 10.1.0.25

Metric: 1 M ti 1 Metric: Metric: 1 Metric: 1 OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 Loop 0: 10.1.0.26/32
ID: 10.1.0.26

RouterB

Rev. 10.41

4 - 11

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Flooding LSAs in a Link State Update Packet: 1


RouterA and RouterB are adjacent, with three LSAs in their synchronized databases. When RouterB detects a new neighbor on one of its OSPF interfaces, the routers begin the exchange of messages that will synchronize their link-state databases.
OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 RouterA
ID: 10.1.0.25

Hello DB Description Link State Request


RouterC
ID: 10.1.0.27 10 1 0 27

Link State Update Li k St Link State t Ack A k

RouterB
ID: 10.1.0.26 10 1 0 26

13
OSPF Area 1.0.0.0 Networks: VLAN 50: 10.1.30.1/24 VLAN 60: 10.1.40.1/24 VLAN 65: 10.1.65.1/24 Loop 0: 10.1.0.26/32

3
OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 VLAN 65: 10.1.65.2/24 Loop 0: 10.1.0.26/32

Flooding LSAs in a Link State Update Packet: 2


RouterA and RouterB are adjacent, with three LSAs in their synchronized databases. When RouterB detects a new neighbor on one of its OSPF interfaces, the routers begin the exchange of messages that will synchronize their link-state databases. g adjacency j y with RouterA requires q RouterBs existing it to encapsulate any new LSAs in a Link State Update packet that it floods immediately over the network they share. RouterA does not request the new LSAs.
Hello DB Description Link State Request
RouterC
ID: 10.1.0.27 10 1 0 27

OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 RouterA
ID: 10.1.0.25

Link-state Update Packet RouterB


ID: 10.1.0.26 10 1 0 26

Link State Update Li k St Link State t Ack A k

16
OSPF Area 1.0.0.0 Networks: VLAN 50: 10.1.30.1/24 VLAN 60: 10.1.40.1/24 VLAN 65: 10.1.65.1/24 Loop 0: 10.1.0.26/32

16
OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 VLAN 65: 10.1.65.2/24 Loop 0: 10.1.0.26/32

Rev. 10.41

4 - 12

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Flooding LSAs in a Link State Update Packet: 3


RouterA and RouterB are adjacent, with three LSAs in their synchronized databases. When RouterB detects a new neighbor on one of its OSPF interfaces, the routers begin the exchange of messages that will synchronize their link-state databases. g adjacency j y with RouterA requires q RouterBs existing it to encapsulate any new LSAs in a Link State Update packet that it floods immediately over the network they share. RouterA does not request the new LSAs. After receipt of the new LSAs, each router updates its link-state database to include them, and acknowledges their receipt.
RouterC
ID: 10.1.0.27 10 1 0 27

OSPF Area 1.0.0.0 Networks: VLAN 10: 10.1.10.1/24 VLAN 20: 10.1.20.1/24 VLAN 64: 10.1.64.1/24 Loop 0: 10.1.0.25/32 RouterA
ID: 10.1.0.25

16

Hello DB Description Link State Request Link State Update Li k St Link State t Ack A k
Link-state Update Packet RouterB
ID: 10.1.0.26 10 1 0 26

16
OSPF Area 1.0.0.0 Networks: VLAN 50: 10.1.30.1/24 VLAN 60: 10.1.40.1/24 VLAN 65: 10.1.65.1/24 Loop 0: 10.1.0.26/32

16
OSPF Area 1.0.0.0 Networks: VLAN 30: 10.1.30.1/24 VLAN 40: 10.1.40.1/24 VLAN 64: 10.1.64.2/24 VLAN 65: 10.1.65.2/24 Loop 0: 10.1.0.26/32

LSA Flooding in a Multi-access Network: 1


When an OSPF router experiences a link state transition, it must originate a new instance of its Router LSA. The router floods the advertisement to adjacent neighbors on point-to-point networks using the reserved multicast address 224.0.0.5 (AllSPFRouters). As each neighbor receives the LSA, it immediately floods to adjacent neighbors using address. Routers dj i hb i the h same multicast li dd R do not flood LSAs onto networks without adjacent neighbors.

Rev. 10.41

4 - 13

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

LSA Flooding in a Multi-access Network: 2


When an OSPF router experiences a link state transition, it must originate a new instance of its Router LSA. The router floods the advertisement to adjacent neighbors on point-to-point networks using the reserved multicast address 224.0.0.5 (AllSPFRouters). As each neighbor receives the LSA, it immediately floods to adjacent neighbors using address. Routers dj i hb i the h same multicast li dd R do not flood LSAs onto networks without adjacent neighbors. The multicast address to which LSAs are flooded on a multiaccess network depends on the state of the router interface flooding the advertisements. A non-Designated Router (non-DR) is adjacent to the DR and Backup DR. It floods LSAs onto the multi-access network g the multicast address 224.0.0.6 (AllDRouters). Only y using the DR and Backup DR process this update.

DR Multi-access Multi access network


NonDR 1

BDR

NonDR 2

NonDR 3

LSA Flooding in a Multi-access Network: 3


When an OSPF router experiences a link state transition, it must originate a new instance of its Router LSA. The router floods the advertisement to adjacent neighbors on point-to-point networks using the reserved multicast address 224.0.0.5 (AllSPFRouters). As each neighbor receives the LSA, it immediately floods to adjacent neighbors using address. Routers dj i hb i the h same multicast li dd R do not flood LSAs onto networks without adjacent neighbors. The multicast address to which LSAs are flooded on a multiaccess network depends on the state of the router interface flooding the advertisements. A non-Designated Router (non-DR) is adjacent to the DR and Backup DR. It floods LSAs onto the multi-access network g the multicast address 224.0.0.6 (AllDRouters). Only y using the DR and Backup DR process this update. The DR is adjacent to all neighbors on the multi-access network. It floods updates to the multicast address 224.0.0.5.

DR Multi-access Multi access network


NonDR 1

BDR

NonDR 2

NonDR 3

Rev. 10.41

4 - 14

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Link State Advertisement Details: 1


OSPF routers run a link-state algorithm against their database entries to create a graph that represents all routers and networks in the local OSPF area. Each networks type is important for graphing purposes. The type of information included in a Router LSA is unique for each type of network. Three of the network types supported by OSPF are illustrated in the graphic. A point-to-point network is represented in the Router LSA as Type 1. A transit network is a multi-access network with two or more connected routers. The Router LSA represents this network as Type 2. A stub link can represent a multi-access multi access network, such as Ethernet, with only one attached router. It is also used to represent the routers loopback interface. The Router LSA represents stub networks as Type 3. The DR for each multi-access transit network originates a Network LSA that lists its connected routers.
Stub network 10.1.128.0/24 Stub network 10.1.0.32/32 Router ID: 10.1.0.32 Int. s1: 10.1.4.1/30 Loop 0: 10.1.0.32/32 Int. e1: 10.1.128.1/24 Point-to-point network 10.1.4.0/30 Router ID: 10.1.0.33 Int. s1: 10.1.4.2/30 Loop 0: 10.1.0.33/32 Int. e1: 10.1.64.1/24 Transit network 10.1.64.0/24 Router ID: 10.1.0.34 Int. e1: 10.1.64.2/24 Loop 0: 10.1.0.34/32 Int. e2: 10.1.129.1/24 Stub network 10.1.129.0/24 Stub network 10.1.0.34/32 Router ID: 10.1.0.35 Int. e1: 10.1.64.3/24 Loop 0: 10.1.0.35/32 Int. e2: 10.1.130.1/24 Stub network 10.1.130.0/24 Stub network 10.1.0.35/32

Stub network 10.1.0.33/32

Link State Advertisement Details: 2


Area 1.0.0.0 Link State Database Router LSA (Type 1) Link State ID: 10.1.0.32 Number of Links: 3 Type: Pt-to-Pt (1) Link ID: 10.1.0.33 Type: Stub (3) Link ID: 10.1.0.32 Type: Stub (3) Link ID: 10.1.128.0 Router LSA (Type 1) Link State ID: 10.1.0.33 Number of Links: 3 Type: Pt-to-Pt (1) Link ID: 10.1.0.32 Type: Transit (2) Link ID: 10.1.64.3 Type: Stub (3) Link ID: 10.1.0.33 Router LSA (Type 1) Link State ID: 10.1.0.34 Number of Links: 3 Type: Transit (2) Link ID: 10.1.64.3 Type: Stub (3) Link ID: 10.1.0.34 Type: Stub (3) Link ID: 10.1.129.0 Router LSA (Type 1) Link State ID: 10.1.0.35 10 1 0 35 Number of Links: 3 Type: Transit (2) Link ID: 10.1.64.3 Type: Stub (3) Link ID: 10.1.0.35 Type: Stub (3) Link ID: 10.1.130.0 Network LSA (Type 2) Link State ID: 10.1.64.3 Network Mask: 255.255.255.0 Attached Router: 10.1.0.35 Attached Router: 10.1.0.33 Attached Router: 10.1.0.34 Advertising Router: 10.1.0.32 Link Data: 10.1.4.1 Link Data: 255.255.255.255 Link Data: 255.255.255.0 Advertising Router: 10.1.0.33 Link Data: 10.1.4.2 Link Data: 10.1.64.1 Link Data: 255.255.255.255 Advertising Router: 10.1.0.34 Link Data: 10.1.64.2 Link Data: 255.255.255.255 Link Data: 255.255.255.0 Advertising Router: 10.1.0.35 10 1 0 35 Link Data: 10.1.64.3 Link Data: 255.255.255.255 Link Data: 255.255.255.0 Advertising Router: 10.1.0.35 Metric: 10 Metric: 1 Metric: 10 Metric: 10 Metric: 1 Metric: 10 Metric: 100 Metric: 10 Metric: 1 Metric: 100 Metric: 1 Metric: 10

Rev. 10.41

4 - 15

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Relationship Between Updates and the IP Route Table


The relationship between OSPF link state updates and the IP route table is indirect. 1. OSPF routers originate link-state advertisements and flood them to adjacent neighbors within link-state update packets, following the rules described earlier. The advertisements are stored in a database. 2 Each router uses the database contents to create a graph that consists of vertices and 2. edges. A vertex may be a router or a multi-access network with two or more connected routers. An edge is a line connecting a pair of vertices. 3. Each router runs the link-state algorithm to create a tree containing all paths to each destination network and router, placing itself at the root. It uses the metrics associated with each path segment to calculate the shortest path to each destination. 4. Having derived the cumulative cost of the shortest path to each destination, the router places the cost and next hop in its IP route table.

Link-State Database

Graph

Shortest-path tree

Route table entries

Graphing Link State Advertisements: 1


Stub link 10.1.128.0/24 Stub link 10.1.0.32/32 Router: 10 1 0 33 10.1.0.33 Stub link 10.1.4.2/32 Router: 10.1.0.32 Stub link 10.1.4.1/32

The graph uses a one-way arrow to represent stub networks. It represents point-to-point networks using two arrows. This router represents its point-to-point link using an arrow that points to th router the t on th the other th side id of f th the link. Router 10.1.0.33 represents its own side of the point-to-point link using an arrow that connects to Router 10.1.0.32. Router 10.1.0.33s loopback interface is shown as a stub network. This router also has a connection to a multi-access transit network.

Network: 10.1.64.3

OSPF does not require that point-to-point links be assigned an IP address. An unnumbered point-to-point network would be graphed as it is currently shown. However, this example does assign address space to the link, link so our graph represents this address space as two stub links links.

Rev. 10.41

4 - 16

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Graphing Link State Advertisements: 2


Stub link 10.1.128.0/24 Stub link 10.1.0.32/32 Router: 10 1 0 33 10.1.0.33 Router: 10.1.0.34 Stub link 10.1.4.2/32 Router: 10.1.0.32 Stub link 10.1.4.1/32

The Designated Router of the multi-access network originates the Network LSA. The graph includes an arrow from the Network vertex to the DRs vertex. The graph uses arrows to represent other routers attached to this network.

Network: 10.1.64.3

Router: 10.1.0.35

Graphing Link State Advertisements: 3


Stub link 10.1.128.0/24 Stub link 10.1.0.32/32 Router: 10 1 0 33 10.1.0.33 Router: 10.1.0.34 Stub link 10.1.4.2/32 Router: 10.1.0.32 Stub link 10.1.4.1/32

The Designated Router of the multi-access network originates the Network LSA. The graph includes an arrow from the Network vertex to the DRs vertex. The graph uses arrows to represent other routers attached to this network. The networks connected to routers 10.1.0.34 and 10.1.0.35 are graphed using the same procedure.

Network: 10.1.64.3

Router: 10.1.0.35

Rev. 10.41

4 - 17

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

OSPF Graph and Link State Database Entries


Routers internal to the same area have synchronized databases, and this causes the routers to create the same graph.
Area 1.0.0.0 Link State Database Area ID 1.0.0.0 1000 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 1.0.0.0 Type Stub link Stub link Stub link Stub link Stub link Stub link Stub link Stub link Stub link Router link Router link Router link Router link Network link Link State ID 10.1.0.32 10 1 0 33 10.1.0.33 10.1.0.34 10.1.0.35 10.1.4.0 10.1.4.0 10.1.128.0 10.1.129.0 10.1.130.0 10.1.0.32 10.1.0.33 10.1.0.34 10.1.0.35 10.1.64.3 Router ID 10.1.0.32 10 1 0 33 10.1.0.33 10.1.0.34 10.1.0.35 10.1.0.32 10.1.0.33 10.1.0.32 10.1.0.34 10.1.0.35 10.1.0.32 10.1.0.33 10.1.0.34 10.1.0.35 10.1.0.35 Sequence 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x80000008 0x80000009 0x80000006 0x80000013 0x80000008

Router and Network entries are directly based on Router and Network link-state advertisements. Sequence numbers reflect the most current instances of each LSA. Stub link entries are derived from information in Router LSAs. No sequence numbers are assigned. While transit networks carry traffic destined for other networks, stub links are analogous to leaves on the shortest-path tree.

Populating the IP Route Table: 1


Each router uses the graph to create a tree, with itself as the root, that specifies the shortest path to each range of IP address space. The router populates its IP route table with the router p interface IP address that serves as the next hop toward each destination.
Router: 10.1.0.32 Network10.1.128.0/24

R t 10.1.0.33 Router: 10 1 0 33 Network10.1.64.0/24 Router: 10.1.0.34 Router: 10.1.0.35

Network10.1.129.0/24

Network10.1.130.0/24

Rev. 10.41

4 - 18

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Populating the IP Route Table: 2

Lesson 2 Introduction
Fast convergence is one of OSPFs main benefits. However, the mechanisms that enable OSPF routers to quickly respond to state changes and maintain current information can negatively affect performance if the scope of router and network link state advertisements is too large. Like intranets that use RIP, those that use OSPF will benefit from the summarization of remote address space. However, OSPF intranets are not limited to the use of static routes for summarization. In this lesson, you will learn the role of multiple OSPF areas in solving these challenges.

Rev. 10.41

4 - 19

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

A Single Area
IP address space in this intranet has been hierarchically assigned to follow its physical topology. If these locations are all within the same OSPF area, routers at Locations B and C will receive the Router and Network LSAs generated due a link state change in Location A. When OSPF routers receive a link-state update which indicates there has been a change in the state of a transit network, they run the link state algorithm and build a new shortest-path tree.

Adjacent neighbors

LSAs Location A address range: 10.1.0.0/16 Location C address range: 10.3.0.0/16 Location B address range: 10.2.0.0/16

LSAs and Remote Locations


As the number of routers that share a synchronized database increases, it becomes more likely that one or more of them could be experiencing link state changes at any given time. Increasing the size and complexity of the shortest-path h h tree is i not, i in i itself, lf a problem. bl OSPF was designed for large and complex intranets. The relative isolation of each location within this intranet makes it unnecessary for routers at one location to have detailed information about the topology of remote locations. Link state changes internal to one location will not change the next p for any y routers at other locations. hop

Rev. 10.41

4 - 20

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

OSPF Router Types:


Area Border Router
OSPF area border routers create boundaries for the Router and Network LSAs that are flooded within an area to maintain database synchronization. One area within a multiple-area OSPF Autonomous System must serve as the backbone. The backbone area has the area ID 0.0.0.0.
Area border router Router connecting a nonbackbone area to the backbone.

Area 0.0.0.0 Area 0.0.0.1

Area 0.0.0.3

A Area 0.0.0.2 0002

OSPF Router Types:


Internal Router
OSPF area border routers create boundaries for the Router and Network LSAs that are flooded within an area to maintain database synchronization. One area within a multiple-area OSPF Autonomous System must serve as the backbone. The backbone area has the area ID 0.0.0.0.
Area border router Internal router Router connecting a nonbackbone area to the backbone. Router with all interfaces in the same area.
A Area 0.0.0.2 0002

Area 0.0.0.0 Area 0.0.0.1

Area 0.0.0.3

Rev. 10.41

4 - 21

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

OSPF Router Types:


Backbone Router
OSPF area border routers create boundaries for the Router and Network LSAs that are flooded within an area to maintain database synchronization. One area within a multiple-area OSPF Autonomous System must serve as the backbone. The backbone area has the area ID 0.0.0.0.
Area border router Internal router Backbone router Router connecting a nonbackbone area to the backbone. Router with all interfaces in the same area. Router R t with ith one or more interfaces in the backbone.
A Area 0.0.0.2 0002

Area 0.0.0.0 Area 0.0.0.1

Area 0.0.0.3

ABR Originates Summary LSAs


An area border router (ABR) has at least one interface in the backbone area, and at least one interface in a non-backbone area. An area may be connected to the backbone by multiple ABRs; however, there must be at least one ABR per area. A ABR maintains An i i adjacencies dj i with i h neighbors i hb i in each h area. These adjacencies enable the ABR to maintain a synchronized copy of the link-state database for each area. This ABR originates a Summary LSA for each network in the backbone, and floods these over adjacencies with neighbors in the non-backbone area, which is Area 0.0.0.2 in this example. The ABR also Th l originates a S Summary LSA f for each h network in the non-backbone area (Area ID 0.0.0.2), and floods these over adjacencies with neighbors in the backbone.. Like all other LSA types, Summary LSAs are encapsulated in Link State Update packets. A Link State Update packet can contain LSAs of multiple types.
Router and Network LSAs flow over adjacencies within the area

ABR

Area 0.0.0.0 Area 0.0.0.2

Router and Network LSAs flow over adjacencies within the area

Rev. 10.41

4 - 22

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Summary LSA Scope


While the scope of Router and Network LSAs is a single area, the scope of Summary LSAs is the entire OSPF autonomous system.

Area 0.0.0.0 Summary LSAs from Area 0.0.0.2 flow through the backbone into all other non-backbone areas. Area 0.0.0.3

ABR

Area 0.0.0.1

ABR

Summary LSAs representing Area 0.0.0.2 networks

ABR

Area 0.0.0.2

Summary LSA Scope


While the scope of Router and Network LSAs is a single area, the scope of Summary LSAs is the entire OSPF autonomous system.

Area 0.0.0.0 Summary LSAs from Area 0.0.0.2 flow through the backbone into all other non-backbone areas. Area 0.0.0.3

ABR

Area 0.0.0.1

ABR

Summary LSAs representing Area 0.0.0.2 networks

ABR

Area 0.0.0.2

Rev. 10.41

4 - 23

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Summary LSAs Encapsulated in Link State Update Packet: 1


In this example, Router 10.1.0.32 is an ABR that connects Area 0.0.0.1 to the backbone. g one Summary y LSA The ABR originates for each network in the non-backbone area and floods them over adjacencies in the backbone area.
Router ID: 10.1.0.32 A Area 0 0 0 0. interface: 0.0.0.0 i t f Int. e2: 10.0.64.1/24 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.32/32 Int. e1: 10.1.128.1/24 Stub network 10.1.128.0/24 Stub network 10.1.0.32/32 0 03 Router ID: 10.1.0.34 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.34/32 Int. e2: 10.1.130.1/24 Stub network 10.1.130.0/24 Stub network 10.1.0.34/32 Router ID: 10.1.0.33 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.33/32 Int. e1: 10.1.129.1/24 Stub network 10.1.129.0/24 Stub network 10.1.0.33/32 Router ID: 10.1.0.35 0 03 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.35/32 Int. e2: 10.1.131.1/24 Stub network 10.1.131.0/24 Stub network 10.1.0.35/32

Area 0.0.0.0

Area 0.0.0.1

Summary LSAs Encapsulated in Link State Update Packet: 2


Area 0.0.0.1 Link State Database Area ID 0.0.0.1 0 0 01 0.0.0.1 0.0.0.1 0.0.0.1 0.0.0.1 0.0.0.1 0.0.0.1 0.0.0.1 0.0.0.1 0.0.0.1 0.0.0.1 0.0.0.1 Type Stub link Stub link Stub link Stub link Stub link Stub link Stub link Stub link Router link Router link Router link Router link Link State ID 10.1.0.32 10 1 0 33 10.1.0.33 10.1.0.34 10.1.0.35 10.1.128.0 10.1.129.0 10.1.130.0 10.1.131.0 10.1.0.32 10.1.0.33 10.1.0.34 10.1.0.35 Router ID 10.1.0.32 10 1 0 33 10.1.0.33 10.1.0.34 10.1.0.35 10.1.0.32 10.1.0.33 10.1.0.34 10.1.0.35 10.1.0.32 10.1.0.33 10.1.0.34 10.1.0.35 Sequence 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x0 0x80000008 0x80000009 0x80000006 0x80000013

Rev. 10.41

4 - 24

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Summary LSAs Encapsulated in Link State Update Packet: 3


Link State Update Packet (flooded into Area 0.0.0.0) OSPF Header Link State Update Packet LSA Type: Summary-LSA (Type 3) Link-State ID: 10.1.0.32 Netmask: 255.255.255.255 LSA Type: yp Summary-LSA y (Type ( yp 3) ) Link-State ID: 10.1.0.33 Netmask: 255.255.255.255 LSA Type: Summary-LSA (Type 3) Link-State ID: 10.1.0.34 Netmask: 255.255.255.255 LSA Type: Summary-LSA (Type 3) Link-State ID: 10.1.0.35 Netmask: 255.255.255.255 LSA Type: Summary-LSA (Type 3) Link State ID: 10.1.128.0 Netmask: 255.255.255.0 255 255 255 0 LSA Type: Summary-LSA (Type 3) Link State ID: 10.1.129.0 Netmask: 255.255.255.0 LSA Type: Summary-LSA (Type 3) Link State ID: 10.1.130.0 Netmask: 255.255.255.0 LSA Type: Summary-LSA (Type 3) Link State ID: 10.1.131.0 Netmask: 255.255.255.0 Number of LSAs: (8) Advertising Router: 10.1.0.32 Advertising Router: 10.1.0.32 Advertising Router: 10.1.0.32 Advertising Router: 10.1.0.32 Advertising Router: 10.1.0.32 Advertising Router: 10.1.0.32 Advertising Router: 10.1.0.32 Advertising Router: 10.1.0.32

Multiple ABRs Each Send Summary LSAs: 1


For added resilience, OSPF areas may be connected to the backbone by more than one area border router. In this example, both ABRs with Router IDs 10.1.0.32 and 10.1.0.33 connect Area 0.0.0.1 to the backbone. Each ABR advertises networks within Area 0.0.0.1 by originating Summary LSAs and flooding them into the backbone area.

Area 0.0.0.0

Router ID: 10.1.0.32 A Area 0 0 0 0. interface: 0.0.0.0 i t f Int. e2: 10.0.64.1/24 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.32/32 Int. e1: 10.1.128.1/24 Stub network 10.1.128.0/24 Stub network 10.1.0.32/32 0 03 Router ID: 10.1.0.34 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.34/32 Int. e2: 10.1.130.1/24 Stub network 10.1.130.0/24 Stub network 10.1.0.34/32

Router ID: 10.1.0.33 A Area 0 0 0 0. interface: 0.0.0.0 i t f Int. e2: 10.0.64.2/24 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.33/32 Int. e1: 10.1.129.1/24 Stub network 10.1.129.0/24 Stub network 10.1.0.33/32 Router ID: 10.1.0.35 0 03 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.35/32 Int. e2: 10.1.131.1/24 Stub network 10.1.131.0/24 Stub network 10.1.0.35/32

Area 0.0.0.1

Rev. 10.41

4 - 25

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Multiple ABRs Each Send Summary LSAs: 2


For added resilience, OSPF areas may be connected to the backbone by more than one area border router. In this example, both ABRs with Router IDs 10.1.0.32 and 10.1.0.33 connect Area 0.0.0.1 to the backbone. Each ABR advertises networks within Area 0.0.0.1 by originating Summary LSAs and flooding them into the backbone area.
Area 0.0.0.0 Link State Database Area ID 0.0.0.0 0.0.0.0 0.0.0.0 0.0.0.0 0.0.0.0 0.0.0.0 0.0.0.0 0.0.0.0 Type Summary Summary Summary Summary Summary Summary Summary Summary Link State ID Router ID 10.1.128.0 10.1.128.0 10.1.129.0 10.1.129.0 10.1.130.0 10.1.130.0 10.1.131.0 10.1.131.0 10.1.0.32 10.1.0.33 10.1.0.32 10.1.0.33 10.1.0.32 10.1.0.33 10.1.0.32 10.1.0.33 Sequence

Area 0.0.0.0

Router ID: 10.1.0.32 A Area 0 0 0 0. interface: 0.0.0.0 i t f Int. e2: 10.0.64.1/24 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.32/32 Int. e1: 10.1.128.1/24 Stub network 10.1.128.0/24 Stub network 10.1.0.32/32

Router ID: 10.1.0.33 A Area 0 0 0 0. interface: 0.0.0.0 i t f Int. e2: 10.0.64.2/24 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.33/32 Int. e1: 10.1.129.1/24 Stub network 10.1.129.0/24 Stub network 10.1.0.33/32 Router ID: 10.1.0.35 0 03 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.35/32 Int. e2: 10.1.131.1/24 Stub network 10.1.131.0/24 Stub network 10.1.0.35/32

0 03 Router ID: 10.1.0.34 0x80000000 Area 0.0.0.1 interfaces: 0x80000000 Int. s1: unnumbered Int. s2: unnumbered 0x80000000 Loop 0: 10.1.0.34/32 0x80000000 Int. e2: 10.1.130.1/24 0x80000000 Stub network 0x80000000 10.1.130.0/24 0x80000000 Stub network 0x80000000 10.1.0.34/32

Area 0.0.0.1

Advertising Address Ranges Within Summary LSAs: 1


Without explicit configuration, ABRs originate Summary LSAs for each network. If IP address space has been assigned hierarchically, following the topology of the OSPF autonomous system, you can minimize the number of Summary LSAs by configuring address range summarization. When an ABR has been configured with address range summarization, it will advertise the entire address range with a single Summary LSA.

Area 0.0.0.0

Router ID: 10.1.0.32 A Area 0 0 0 0. interface: 0.0.0.0 i t f Int. e2: 10.0.64.1/24 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.32/32 Int. e1: 10.1.128.1/24 Stub network 10.1.128.0/24 Stub network 10.1.0.32/32 0 03 Router ID: 10.1.0.34 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.34/32 Int. e2: 10.1.130.1/24 Stub network 10.1.130.0/24 Stub network 10.1.0.34/32

Router ID: 10.1.0.33 A Area 0 0 0 0. interface: 0.0.0.0 i t f Int. e2: 10.0.64.2/24 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.33/32 Int. e1: 10.1.129.1/24 Stub network 10.1.129.0/24 Stub network 10.1.0.33/32 Router ID: 10.1.0.35 0 03 Area 0.0.0.1 interfaces: Int. s1: unnumbered Int. s2: unnumbered Loop 0: 10.1.0.35/32 Int. e2: 10.1.131.1/24 Stub network 10.1.131.0/24 Stub network 10.1.0.35/32

Area 0.0.0.1

Rev. 10.41

4 - 26

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Advertising Address Ranges Within Summary LSAs: 2

Redistributing Non-OSPF Network Information


OSPF routers advertise: Locally connected OSPF networks using Router LSAs and Network LSAs Networks in another area using Summary LSAs Routing information that comes from a source other than OSPF is considered external Examples of external routing information include: Default route to the Internet Static route to portions of the intranet that do not use OSPF g Routes learned from RIP neighbors
Area 1 address range: 10.1.0.0/16

Internet
Area 0 (Backbone) address dd range: 10.0.0.0/16

Area 2 address range: 10.2.0.0/16

RIP domain 172.16.0.0/16

Rev. 10.41

4 - 27

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Autonomous System Boundary Router (ASBR)


An Autonomous System Boundary Router (ASBR) is an OSPF router that has learned routes from a non-OSPF source and redistributes them into the OSPF autonomous system. An ASBR generates one AS External LSA for each non-OSPF network. However, routers support definition of policies that summarize the redistributed address space, which results in a smaller number of AS External LSAs.

Area 0 (Backbone) address dd range: 10.0.0.0/16

Internet ASBR

Area 2 address range: 10.2.0.0/16

ASBR
Area 1 address range: 10.1.0.0/16 RIP domain 172.16.0.0/16

Normal and Stub Area Types


OSPF areas are divided into two main categories: Transit-type areas, such as the backbone area and Area 0.0.0.3 (which may be abbreviated to 3), can carry traffic that whose source or destination is outside the area. One sub-type of transit area is configured as normal. Stub-type areas, such as Area 1 and Area 2, carry only traffic whose source or destination is within the area. The ASBR in the backbone area uses a static route to provide Internet access. It converts the static route into an AS External (Type 5) LSA, and floods it into the backbone area.
Area 0.0.0.1 (Stub) Area 0.0.0.2 (Stub) Area 0.0.0.0 (Normal)

Internet
ASBR

Traffic destined for the RIP domain travels through this area. Area 0.0.0.3 (Normal)
ASBR

The ABR for Area 3 floods the AS External LSAs over adjacencies into Area 3. ABRs for the stub areas (1 and 2) do not flood AS External LSAs into these areas. Instead, each originates a Type 3 Summary LSA that advertises the default route (0.0.0.0/0) and floods it to adjacent neighbors.

RIP domain (172.16.0.0/16)

Rev. 10.41

4 - 28

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

Main Benefit of Stub Area Definition


The benefit of the stub-type area definition becomes most apparent in advertisements of the RIP networks in our example. The ASBR within Area 3 has RIP interfaces and OSPF interfaces. It converts RIP routes from its IP route table into one or more AS External LSAs, and floods them to neighbors within Area 3. h AS External l LSAs are flooded fl d d into the h b backbone. kb The ABRs connecting stub areas, such as Area 1 and Area 2, inject the default route to represent all routes external to OSPF, regardless of their original source.
Area 0 A 0.0.0.0 000 (Normal)

Internet
ASBR

Area 0.0.0.1 (Stub) Area 0.0.0.2 (Stub)

Area 0.0.0.3 (Normal)


ASBR

This technique minimizes unnecessary information in the link-state database and route tables bl of f OSPF routers internal l to the h stub area. In most implementations, ABRs can be configured to withhold advertisements of address space in other areas (Type 3 Summary LSAs), so that the default route represents all destinations outside the area.

RIP domain (172.16.0.0/16)

Not-So-Stubby Area Type


An area that supports an ASBR, such as Area 3, cannot be defined as a stub area type. However, it can have the address summarization benefits of a stub area if it defined as a not-so-stubby area (NSSA). In this example, an ASBR connected to the backbone h several has l static routes to address dd space outside d the h OSPF domain. The ASBR originates Type 5 External LSAs and floods them into the backbone. If Area 3 is defined as a NSSA area type, its ABR will handle Type 5 AS External LSAs the same as ABRs connected t dt to stub t b areas 1 and d2 2. It will ill inject the default route in place of the External LSAs.
Area 0.0.0.1 (Stub) Area 0.0.0.2 (Stub) Non-OSPF domain

Internet
ASBR

Area 0 A 0.0.0.0 000 (Normal)

ASBR

Area 0.0.0.3 (NSSA)


ASBR

RIP domain (172.16.0.0/16)

Rev. 10.41

4 - 29

HP Switching and Routing Technologies

Open Shortest Path First (OSPF)

The NSSA Link State Advertisement


Type 5 AS External LSAs cannot exist within a Stub or NSSA area type. The change in Area 3s status from Normal to NSSA affects the method its ASBR will use to advertise its external RIP routes. The ASBR within Area 3 advertises the non-OSPF networks using a Type 7 NSSA LSA. The ABR that connects Area 3 to the backbone translates the Type 7 LSAs into Type 5 LSAs and floods them into the backbone, at which point they are handled as described earlier.
Area 0.0.0.0 (Normal) ASBR ABR for a NSSA-type area converts Type 7 LSAs to AS External (Type 5) LSAs. Area 0.0.0.3 (NSSA) ASBR within a stub area advertises external routes by originating NSSA (Type 7) LSAs

Internet

Area 0.0.0.1 (Stub) Area 0.0.0.2 (Stub)

ABR

ASBR RIP domain (172.16.0.0/16)

Module 4 Summary
This module described the operation of the OSPF routing protocol, and identified some of the terms associated with it. Topics included: The content and scope of various types of OSPF messages, and the procedures OSPF routers follow when they y receive such messages g The responsibilities associated with various OSPF router roles The effect that area type has on the advertisement of non-OSPF route information

Rev. 10.41

4 - 30

HP Switching and Routing Technologies

IP Multicast Protocols

Module 5: IP Multicast Protocols


Objectives
After completing this module, you will be able to: Articulate the advantages of using IP multicast technology to deliver multimedia traffic streams. Identify the roles of IGMP and PIM in multicast communications, and the scope of each protocol. protocol Describe the operation of PIM Dense and PIM Sparse and their appropriate network deployments.

Lesson 1 Introduction: 1
A server sending video traffic to specific receivers over IP networks has a choice among communication methods. Each method produces a unique result.
Unicast An individual copy of each video frame is sent to each receiver.
10.4.110.145/24 10.4.110.150/24

Multiple copies of each h frame f may increase traffic congestion

10.4.32.50/24

/ 10.4.10.10/24

The server will support a limited number of receivers.


10.4.10.50/24

Rev. 10.41

5-1

HP Switching and Routing Technologies

IP Multicast Protocols

Lesson 1 Introduction: 2
A server sending video traffic to specific receivers over IP networks has a choice among communication methods. Each method produces a unique result.
Unicast Broadcast An individual copy of each video frame is sent to each receiver. A single copy of each video frame is sent to the all hosts broadcast address.
10.4.110.145/24 10.4.110.150/24

10.4.32.50/24

The router drops broadcast traffic, making this a local-only solution.

The layer 2 switch floods broadcast traffic over all links potentially links, overwhelming some hosts with unwanted traffic.
10.4.10.50/24

/ 10.4.10.10/24

Lesson 1 Introduction: 3
A server sending video traffic to specific receivers over IP networks has a choice among communication methods. Each method produces a unique result.
Unicast Broadcast Multicast An individual copy of each video frame is sent to each receiver. A single copy of each video frame is sent to the all hosts broadcast address. A single copy of each video frame is sent to an IP multicast address.
10.4.110.145/24 10.4.110.150/24

10.4.32.50/24

Multicast combines the benefits of the other methods, while eliminating their disadvantages.

Layer 2 and Layer 3 devices, when configured to support IP multicast, will forward the traffic only y toward w receivers. v

/ 10.4.10.10/24

10.4.10.50/24

Rev. 10.41

5-2

HP Switching and Routing Technologies

IP Multicast Protocols

Multicast Addresses

Class D 224-239

Class C 192-223 Class B 128-192 Class A 0-127

Routers and switches recognize multicast traffic by the range of the first octet in its destination IP address. IP Multicast traffic uses the Class D address range: 224.0.0.0 239.255.255.255 Addresses between 224.0.0.0 and 224.0.1.255 are reserved for protocol control. For example: OSPF uses addresses 224.0.0.5 and 224.0.0.6 Network Time Protocol uses 224.0.1.1 The address range used by global content providers is between 224.0.2.0 and 233.255.255.255. Addresses in the highest g p portion of the range g are reserved for p private use within an enterprise: 239.0.0.0 239.255.255.255

Resolving IP Multicast to Ethernet Addresses


IP multicast addresses (224.0.0.0 239.255.255.255) map directly to Ethernet multicast addresses:

Decimal

224.0.0.5

The first 24 bits are always 0x01005e The last 24 bits are composed of the last 23 bits of the IP multicast address, padded with a zero in the most significant position
Binary Hexadecimal

01005e - 00 00 05

0000 0 001 0000 0000 0101 1110

1000 0000 0000 0000 0111 1010 Ethernet stations transmit the bits in each octet in reverse order. The first transmitted bit has the value 1, which indicates broadcast. The first transmitted bit of all unicast MAC addresses has the value 0.

Rev. 10.41

5-3

HP Switching and Routing Technologies

IP Multicast Protocols

Multicast Protocol Scopes: 1


When senders and receivers are located on different networks, IP multicast requires the interaction of at least two protocols.

IGMP

IGMP

IGMP

PIM

IGMP

Multicast Protocol Scopes: 2


When senders and receivers are located on different networks, IP multicast requires the interaction of at least two protocols. The h Internet Group Management Protocol l (IGMP) runs at the network edge. Routers and switches exchange IGMP messages with IP hosts, and direct the multicast stream on to network segments that contain group members. Routers use a multicast routing protocol, such as Protocol Independent Multicast (PIM), to maintain the distribution tree that carries traffic from its source to networks with group members.
Group member

IGMP

IGMP

IGMP

PIM

IGMP

Group members

Source

Rev. 10.41

5-4

HP Switching and Routing Technologies

IP Multicast Protocols

Roles of Multicast-Capable Devices


An IGMP Querier is a device that sends periodic messages to a multicast address. The Querier, which is usually a router, maintains tables that determine which of its interfaces lead to receivers of multicast traffic traffic. Each multicast-enabled broadcast domain must have one active Querier and possibly a backup Querier. An IGMP host is an end station that runs multicast applications, enabling it to respond to the periodic messages sent by the Querier. IGMP messages originated by the host enable it to signal its intention to receive, or stop receiving, a multicast data stream.

IGMP Querier

Router int. 1: 10.1.4.1/24

Router int. 2: 10.1.8.1/24

IGMP hosts
.11 .12 .13 .14 .11 .12 .13 .14

Network 10.1.4.0/24

Network 10.1.8.0/24

IGMP General Query: 1


In its role as the IGMP Querier, this router sends periodic Host Membership Requests through its IGMP-enabled interfaces. The Querier continues to send the General Query regardless of whether any multicast Query, traffic actually being transmitted.

Int. 1: 10.1.4.1/24

Int. 2: 10.1.8.1/24

The Layer 2 switches flood the request through all ports.


.11 .12 .13 .14 .11 .12 .13 .14

Network 10.1.4.0/24

Network 10.1.8.0/24

Rev. 10.41

5-5

HP Switching and Routing Technologies

IP Multicast Protocols

IGMP General Query: 2


Ethernet header: Dest: 01:00:5e:00:00:01 Source: <Router_MAC> Type: IP (0x0800) IP datagram header: Protocol: IGMP (0x02) Source: 10.1.4.1 Destination: 224.0.0.1 Internet Group Management Protocol: IGMP Version: 2 Type: Membership Query (0x1 1) Max Response Time: 10.0 sec Multicast Address: 0.0.0.0
The multicast address 224.0.0.1 includes all IP hosts. h

This is a type of Host Membership Request which is known as a General Query. The default interval between General Queries is 125 seconds.

IGMP Host Membership Report: 1


Hosts originate a Membership Report when an IGMP-compatible multicast receiver application is launched. This message enables the host to join a multicast group. An IGMP host can join a group regardless of whether the source for this group has begun to transmit data.
Querier

There are several ways in which a multicast client application may obtain the appropriate group address, including: Hard-code the multicast address Prompt p the user to p provide the address Dynamically obtain the address from a server

Int. 1: 10.1.4.1/24

Int. 2: 10.1.8.1/24

.11

.12

.13

.14

A set of hosts, routers, and/or switches that send or receive multicast data streams to or from the same source(s).

.11

.12

.13

.14

Network 10.1.4.0/24

Network 10.1.8.0/24

Rev. 10.41

5-6

HP Switching and Routing Technologies

IP Multicast Protocols

IGMP Host Membership Report: 2


Ethernet header: Dest: 01:00:5e:40:0c:2a Source: <Host_MAC> Type: IP (0x0800) IP datagram header: Protocol: IGMP (0x02) Source: 10.1.4.1 1 Dest: 239.192.12.42 Internet Group Management Protocol: IGMP Version: 2 Type: Membership Report (0x16) Max Response Time: 0.0 sec Multicast Address: 239.192.12.42
The IP destination of the Membership Report is the address of f the h multicast li group the h IGMP Host wants to join.

The IGMP host uses this message to signal its intent to receive a specific multicast stream.

Router Forwards Multicast Traffic


On receipt of the Membership Report, the router creates an IGMP table entry associating the multicast group address with Int. 1, which is the port leading toward group members. When the data stream associated with this multicast group begins, the router will forward the traffic through its interface 1.

Int. 3: 10.1.16.1/24 Int. 1: 10.1.4.1/24 Int. 2: 10.1.8.1/24

10.1.16.128/24

.11

.12

.13

.14

.11

.12

.13

.14

Network 10.1.4.0/24

Network 10.1.8.0/24

Rev. 10.41

5-7

HP Switching and Routing Technologies

IP Multicast Protocols

IGMP Snooping
In an environment where Layer 2 and Layer 3 forwarding functionality is performed by separate devices, successful multicast support requires that Layer 2 switches also be IGMP-aware. If the Layer 2 switch is not IGMP aware, it floods the multicast traffic over all ports. If the Layer 2 switch supports IGMP snooping, its initial behavior is the same as a switch without IGMP support. The h switch h eventually ll stops flooding fl d on nonmember ports based on detection of Membership Reports sent by group members in response to Membership Requests. IGMP-snooping switches respond to additional membership reports by forwarding the traffic toward group members.
Querier
Int. 2: 10.1.8.1/24

Int. 1: 10.1.4.1/24

Group members

.11

.12

.13

.14

.11

.12

.13

.14

Network 10.1.4.0/24

Network 10.1.8.0/24

IP Multicast With a Layer 3 Switch


When IGMP runs on a Layer 3 switch that uses VLAN interfaces, IGMP and PIM are enabled within VLAN interfaces. In this example, all members of the multicast group are connected to the same router. The router uses PIM to associate the source of multicast traffic with the group address to which it transmits traffic. The Layer 3 switch filters or forwards the traffic based on messages from IGMP hosts.
VLAN 16 interface: 10.1.16.1/24 IGMP and PIM enabled
10.1.16.128/24 Source of multicast group 239.192.12.42

VLAN 4 interface: 10.1.4.1/24 IGMP and PIM enabled


.11 .12 .13 .14

VLAN 8 interface: 10.1.8.1/24 IGMP and PIM enabled


.11 .12 .13 .14

Members of multicast group 239.192.12.42

Members of multicast group 239.192.12.42

Rev. 10.41

5-8

HP Switching and Routing Technologies

IP Multicast Protocols

Lesson 2 Introduction
Routers use multicast routing protocols to create a loop-free path for IP multicast traffic. End stations use IGMP to join one or more multicast groups. Downstream group presence requires routers to obtain the requested traffic from an upstream source, and forward it onto networks containing group members. Routers are nodes in the tree. The source node is the router connected to the host sending the multicast traffic. Leaf nodes with group presence join the tree by sending messages to upstream neighbors. Intermediate nodes with downstream neighbors send messages upstream to join the tree. Nodes without group presence or downstream neighbors are not part of the distribution tree.

Source

Group members

Group members

Group members

Comparing PIM Dense and Sparse Modes


Like unicast routing protocols, multicast routing protocols exchange period messages with neighbors to build a multicast distribution tree. Dense and sparse mode protocols approach this challenge from opposite perspectives, as outlined in the chart. This lesson provides more information on dense and sparse modes of Protocol Independent Multicast. Use model
PIM Dense Mode (PIM-DM)
Senders and receivers are located in close proximity, or connected by links with plentiful bandwidth. Senders and receivers are separated by distance distance, or connected by lowerbandwidth point-to-point links.

How the distribution tree is built


Multicast traffic is initially flooded to all nodes, who eventually prune themselves from the tree if they have no downstream group members. On protocol startup, one node is identified as the root of the tree tree. Routers explicitly request the stream if they have downstream group members.

Multicast group/distribution tree relationship


Routers dynamically create a distribution tree for each multicast group.

PIM Sparse Mode (PIM SM) (PIM-SM)

Routers define a shared tree that can carry traffic for multiple groups.

Rev. 10.41

5-9

HP Switching and Routing Technologies

IP Multicast Protocols

PIM Neighbor Discovery


Each PIM router begins neighbor detection as soon as the protocol becomes active. It originates a Hello message for each interface and sends it on a configurable interval. PIM routers store neighbor identities in a g table. The format of Hello messages is the same whether originated by PIM dense or sparse mode routers. However, routers that share a network must be using the same mode if they are to become neighbors.
Router 1: Int 1: 10.1.4.1/24 Int 2: 10.1.64.1/24 Int 3: 10.1.65.1/24 Int 4: 10.1.68.1/24
1 1

Refer to next page to view the Hello message Router 1 sends over this link.

2 4

2 4

Router 2: Int 1: 10.1.5.1/24 Int 2: 10.1.64.2/24 Int 3: 10.1.66.1/24 Int 4: 10.1.67.1/24

Router 3: Int 1: 10.1.6.1/24 Int 10.1.65.2/24 I t 2: 2 10 1 65 2/24 Int 3: 10.1.67.2/24

2 3 1 3 1

Router 4: Int 1: 10.1.7.1/24 I 2: Int 2 10 10.1.66.2/24 1 66 2/24 Int 3: 10.1.68.2/24

PIM Neighbor Discovery:


Hello message
Ethernet header: Dest: 01:00:5e:00:00:0d Source: <Router_MAC> Type: IP (0x0800) IP datagram header: Protocol: PIM (0x67) (Decimal: 103) Source: 10.1.64.1 Destination: 224.0.0.13 Protocol Independent Multicast header: Version: 2 Type: Hello PIM parameters: Holdtime: 105 sec
PIM routers are members of the multicast group 224.0.0.13.

PIM routers use Hello messages to discover neighbors and negotiate parameters for their relationship. The Holdtime parameter states the amount of time the neighbor should consider this routers state to be valid.

Rev. 10.41

5 - 10

HP Switching and Routing Technologies

IP Multicast Protocols

PIM Router Initial Flooding


When the server begins sending a multicast stream, source node creates an entry in its PIM route table containing the source and group addresses. The floods Th source node d then h fl d the h stream over all other interfaces. This enables downstream routers to place the appropriate S,G pair in their PIM route tables. Each router floods the stream toward its PIM neighbors. Depending on its IGMP implementation, a router or routing switch may also flood the multicast traffic on to user networks for the benefit of IGMP snooping Layer y 2 switches.
Source: 10.1.5.37/24

R t 1: Router Int 1: 10.1.4.1/24 Int 2: 10.1.64.1/24 Int 3: 10.1.65.1/24 Int 4: 10.1.68.1/24

2 4

2 4

Router 2: Int 1: 10.1.5.1/24 Int 2: 10.1.64.2/24 Int 3: 10.1.66.1/24 Int 4: 10.1.67.1/24

Router 3: Int 1: 10.1.6.1/24 Int 2: 10.1.65.2/24 Int 3: 10.1.67.2/24

2 3 1 3 1

Router 4: Int 1: 10.1.7.1/24 Int 2: 10.1.66.2/24 Int 3: 10.1.68.2/24

PIM Router Initial Flooding:

Router 2 PIM Route Table and IP Route Table


The multicast data stream is uniquely identified by the Source of the multicast traffic and its Group, which is also known as an S,G pair.
PIM Route Table: Router 2 Group Address --------------239.192.12.42 Source Address --------------10.1.5.37 Metric -----------1 Metric Pref ---------------0

The metric in this table corresponds with the metric associated with the source network in the IP route table.

Source = 10.1.5.37 Group = 239.192.12.42


IP Route Table: Router 2 Destination ------------10.1.4.0/24 10.1.5.0/24 10.1.6.0/24 10.1.7.0/24 10.1.64.0/24 10.1.65.0/24 10.1.66.0/24 10.1.67.0/24 10.1.68.0/24 Gateway -----------10.1.64.1 10.1.67.2 10.1.66.2 10.1.64.1 Type ----------ospf connected ospf ospf connected ospf connected connected ospf Metric -------109 1 110 110 1 19 1 1 19 Distance -------110 0 110 110 0 110 0 0 110

10.1.64.1

Rev. 10.41

5 - 11

HP Switching and Routing Technologies

IP Multicast Protocols

PIM Router Initial Flooding:

Router 1 PIM Route Table and IP Route Table


PIM Route Table: Router 1 Group Address --------------239.192.12.42 Source Address --------------10.1.5.37 Metric -----------109 Metric Pref ---------------110

IP Route Table: Router 1 Destination ------------10.1.4.0/24 10.1.5.0/24 10.1.6.0/24 10.1.7.0/24 10.1.64.0/24 10 1 65 0/24 10.1.65.0/24 10.1.66.0/24 10.1.67.0/24 10.1.68.0/24 Gateway -----------10.1.64.2 10.1.65.2 10.1.68.2 Type ----------connected ospf ospf ospf connected connected t d ospf ospf connected Metric -------1 109 110 110 1 1 19 19 1 Distance -------0 110 110 110 0 0 110 110 0

Router 1s upstream PIM neighbor is 10.1.64.2, which is its next hop to reach the source network for this multicast group. This routers upstream interface, or reverse path interface is 10.1.64.1.

10.1.64.2 10.1.64.2

PIM Router Initial Flooding:

Router 3 PIM Route Table and IP Route Table


PIM Route Table: Router 3 Group Address --------------239.192.12.42 Source Address --------------10.1.5.37 Metric -----------110 Metric Pref ---------------110

IP Route Table: Router 3 Destination ------------10.1.4.0/24 10.1.5.0/24 10.1.6.0/24 10.1.7.0/24 10.1.64.0/24 10 1 65 0/24 10.1.65.0/24 10.1.66.0/24 10.1.67.0/24 10.1.68.0/24 Gateway -----------10.1.65.1 10.1.67.1 10.1.65.1 10.1.65.1 10.1.65.1 10.1.65.1 Type ----------ospf ospf connected ospf ospf connected ospf connected ospf Metric -------109 110 1 119 18 1 29 1 19 Distance -------110 110 0 110 110 0 110 0 110

This routers upstream PIM neighbor is 10.1.67.1. Its reverse path interface is 10.1.67.2.

Rev. 10.41

5 - 12

HP Switching and Routing Technologies

IP Multicast Protocols

PIM Router Initial Flooding:

Router 4 PIM Route Table and IP Route Table


PIM Route Table: Router 4 Group Address --------------239.192.12.42 Source Address --------------10.1.5.37 Metric -----------109 Metric Pref ---------------110

IP Route Table: Router 4 Destination ------------10.1.4.0/24 10.1.5.0/24 10.1.6.0/24 10.1.7.0/24 10.1.64.0/24 10 1 65 0/24 10.1.65.0/24 10.1.66.0/24 10.1.67.0/24 10.1.68.0/24 Gateway -----------10.1.66.1 10.1.66.1 10.1.68.1 10.1.66.1 10 1 68 1 10.1.68.1 10.1.66.1 Type ----------ospf ospf ospf connected ospf ospf f connected ospf connected Metric -------110 109 119 1 18 19 29 19 19 Distance -------110 110 110 0 110 110 110 0 110

This routers upstream PIM neighbor is 10.1.66.1. Its reverse path interface is 10.1.66.2.

PIM Loop Prevention 1


PIM-Dense routers obey the rule of Reverse Path Forwarding to prevent loops during the initial flood of multicast traffic. Each router floods multicast traffic that arrives through its reverse path interface. It filters multicast traffic that arrives through other interfaces. As the source node, Router 2 floods the multicast traffic over its PIM-enabled interfaces.
Router 3: Int 1: 10.1.6.1/24 Int 2: 10.1.65.2/24 Int 3: 10.1.67.2/24 Router 1: Int 1: 10.1.4.1/24 Int 2: 10.1.64.1/24 Int 3: 10.1.65.1/24 Int 4: 10.1.68.1/24
1 1

Source: 10.1.5.37/24

2 4

Router 2: Int 1: 10.1.5.1/24 Int 2: 10.1.64.2/24 Int 3: 10.1.66.1/24 Int 4: 10.1.67.1/24

2 3 1 3 1

Router 4: Int 1: 10.1.7.1/24 Int 2: 10.1.66.2/24 Int 3: 10.1.68.2/24 Reverse Path interface Filtered interface

Rev. 10.41

5 - 13

HP Switching and Routing Technologies

IP Multicast Protocols

PIM Loop Prevention 2


Source: 10.1.5.37/24

Router 1 floods the traffic it receives through its interface to the network it shares with Router 2. Routers 3 and 4 flood the multicast traffic they receive through their reverse path interfaces. The routers discard traffic they receive through filtered interfaces. HP networking E-series routing switches that implement Data-Driven IGMP will forward the traffic on to user networks only after IGMP hosts have joined the multicast group.

Router 1: Int 1: 10.1.4.1/24 Int 2: 10.1.64.1/24 Int 10.1.65.1/24 I 3: 3 10 1 65 1/24 Int 4: 10.1.68.1/24

2 4

Router 2: Int 1: 10.1.5.1/24 Int 2: 10.1.64.2/24 Int 10.1.66.1/24 I 3: 3 10 1 66 1/24 Int 4: 10.1.67.1/24

Router 3: Int 1: 10.1.6.1/24 Int 2: 10.1.65.2/24 Int 3: 10.1.67.2/24

2 3 1 3 1

Router 4: Int 1: 10.1.7.1/24 Int 2: 10.1.66.2/24 Int 3: 10.1.68.2/24


Reverse Path interface Filtered interface

Pruning Branches From the Distribution Tree


Populating the PIM route table is the primary reason for the initial flood of multicast traffic. PIM-Dense uses a multicast distribution model known as flood and prune. After the initial flood begins fl d of f traffic, ffi a router b i to prune all ll branches other than those leading to downstream group presence. The routers initially begin by pruning the redundant links.
Router 3: Int 1: 10.1.6.1/24 Int 2: 10.1.65.2/24 Int 3: 10.1.67.2/24 Router 1: Int 10.1.4.1/24 I 1: 1 10 1 4 1/24 Int 2: 10.1.64.1/24 Int 3: 10.1.65.1/24 Int 4: 10.1.68.1/24 Source: 10.1.5.37/24

2 4

Router 2: Int 10.1.5.1/24 I 1: 1 10 1 5 1/24 Int 2: 10.1.64.2/24 Int 3: 10.1.66.1/24 Int 4: 10.1.67.1/24

2 3 1 3 1

Router 4: Int 1: 10.1.7.1/24 Int 2: 10.1.66.2/24 Int 3: 10.1.68.2/24


Reverse Path interface Filtered interface

Rev. 10.41

5 - 14

HP Switching and Routing Technologies

IP Multicast Protocols

Pruning Routers From the Distribution Tree


IGMP Host Membership Report
Source: 10.1.5.37/24

.11

.12

.13

.14

Group members: S: 10.1.5.37 G: 239.192.12.42

Router 1: Int 1: 10.1.4.1/24 Int 2: 10.1.64.1/24 Int 3: 10.1.65.1/24 Int 4: 10.1.68.1/24 3

2 4

Router 2: Int 1: 10.1.5.1/24 Int 2: 10.1.64.2/24 Int 3: 10.1.66.1/24 Int 4: 10.1.67.1/24

PIM Prune message


Router 3: Int 1: 10.1.6.1/24 Int 2: 10.1.65.2/24 Int 3: 10.1.67.2/24 2 2 3 1 3 1 Router 4: Int 1: 10.1.7.1/24 Int 2: 10.1.66.2/24 Int 3: 10.1.68.2/24

In its role as IGMP Querier, each router maintains tables that determine whether its user VLANs contain group members members. Router 1 remains a part of the distribution tree for this multicast group due to downstream group presence.

No group members

No group members

Based on lack of group presence, Routers 3 and 4 each send a PIM Prune message to upstream neighbors.

Pruning Routers From the Distribution Tree:


PIM Prune Message
Ethernet header: Dest: 01:00:5e:00:00:0d Source: <Router_3_MAC> Type: IP (0x0800) IP datagram header: Protocol: PIM (0x67) (Decimal: 103) Source: 10.1.67.2 Destination: 224.0.0.13 Protocol Independent Multicast header: Version: 2 Type: Join/Prune (3) PIM parameters: Upstream Neighbor: 10.1.67.1 Groups: 1 H ld Holdtime: 121 (sec) ( ) Group 0: 239.192.12.42/32 Join: 0 Prune: 1 IP address: 10.1.5.37

The Prune message is sent to the PIM reserved multicast address address. This message format is used for the Prune message as well as a Join message used by PIM Sparse. On a multi-access network, this PIM router may have multiple upstream neighbors. The message specifies the upstream neighbor to which this message applies. This distribution tree carries the data stream for a single multicast group. However, this message could include information relating to multiple groups. The message specifies the multicast source whose data stream should be pruned.

Rev. 10.41

5 - 15

HP Switching and Routing Technologies

IP Multicast Protocols

Graft Based on Downstream Group Presence: 1


Source: 10.1.5.37/24

Group members: S: 10 10.1.5.37 1 5 37 G: 239.192.12.42

.11

.12

.13

.14

Router 2 maintains the prune state for its downstream neighbors, Router 3 and Router 4, until they send a message changing the state. When Router 3s IGMP tables indicate group presence, it sends a PIM Graft message upstream.

Router 1: Int 10.1.4.1/24 I t 1: 1 10 1 4 1/24 Int 2: 10.1.64.1/24 Int 3: 10.1.65.1/24 Int 4: 10.1.68.1/24

1 4

2 4

Router 2: Int 10.1.5.1/24 I t 1: 1 10 1 5 1/24 Int 2: 10.1.64.2/24 Int 3: 10.1.66.1/24 Int 4: 10.1.67.1/24

PIM Graft message


Router 3: Int 1: 10.1.6.1/24 Int 2: 10.1.65.2/24 Int 3: 10.1.67.2/24 1 2 3 3 1 Router 4: Int 1: 10.1.7.1/24 Int 2: 10.1.66.2/24 Int 3: 10.1.68.2/24

IGMP Host Membership Report

.11

.12

.13

.14

Group members: S: 10.1.5.37 G: 239.192.12.42

No group members

Graft Based on Downstream Group Presence: 2


PIM Graft Message
Ethernet header: Dest: <Router_2_MAC> Source: <Router_3_MAC> Type: IP (0x0800) IP datagram header: Protocol: PIM (0x67) (Decimal: 103) Source: 10.1.67.2 Destination: 10.1.67.1 Protocol Independent Multicast header: Version: 2 Type: Graft (6) PIM parameters: Upstream Neighbor: 10.1.67.1 Groups: 1 Holdtime: 0 (sec) G Group 0: 0 239.192.12.42/32 239 192 12 42/32 Join: 1 IP address: 10.1.5.37 Prune: 0

The target of a PIM Graft message is a specific neighbor instead of the PIM reserved multicast address. dd

A PIM Graft message sets the Join field at 1 and the Prune field at 0. Like the Prune message, it specifies the distribution trees source and group addresses.

Rev. 10.41

5 - 16

HP Switching and Routing Technologies

IP Multicast Protocols

Graft Based on Downstream Group Presence: 3


Source: 10.1.5.37/24

Group members: S: 10 10.1.5.37 1 5 37 G: 239.192.12.42

.11

.12

.13

.14

Router 2 maintains the prune state for its downstream neighbors, Router 3 and Router 4, until they send a message changing the state. When Router 3s IGMP tables indicate group presence, it sends a PIM Graft message upstream. Router 2 acknowledges th G the Graft ft message.
IGMP Host Membership Report

Router 1: Int 10.1.4.1/24 I t 1: 1 10 1 4 1/24 Int 2: 10.1.64.1/24 Int 3: 10.1.65.1/24 Int 4: 10.1.68.1/24 3

2 4

Router 2: Int 10.1.5.1/24 I t 1: 1 10 1 5 1/24 Int 2: 10.1.64.2/24 Int 3: 10.1.66.1/24 Int 4: 10.1.67.1/24

Router 3: Int 1: 10.1.6.1/24 Int 2: 10.1.65.2/24 Int 3: 10.1.67.2/24

PIM Graft Acknowledgment


2 2 3 1 3 1

Router 4: Int 1: 10.1.7.1/24 Int 2: 10.1.66.2/24 Int 3: 10.1.68.2/24

.11

.12

.13

.14

Group members: S: 10.1.5.37 G: 239.192.12.42

No group members

Graft Based on Downstream Group Presence: 4


PIM Graft Acknowledgment

Ethernet header: Dest: <Router_3_MAC> Source: <Router_2_MAC> Type: IP (0x0800) IP datagram header: Protocol: PIM (0x67) (Decimal: 103) Source: 10.1.67.1 Destination: 10.1.67.2 Protocol Independent Multicast header: Version: 2 Type: Graft-Ack (7) PIM parameters: Groups: 0

The e router ou e receiving ece v g a PIM MG Graft a message essage from o a downstream neighbor sends a Graft Acknowledgment before sending the data stream.

Rev. 10.41

5 - 17

HP Switching and Routing Technologies

IP Multicast Protocols

PIM Prune Based on Loss of Group Presence: 1


Source: 10.1.5.37/24

Group members: S: 10.1.5.37 G: 239.192.12.42

.11

.12

.13

.14

Router 1 and Router 3 remain on the distribution tree as long as each has at least one group member on its user network.

Router 1: R Int 1: 10.1.4.1/24 Int 2: 10.1.64.1/24 Int 3: 10.1.65.1/24 Int 4: 10.1.68.1/24 3

2 4

Router 2: R Int 1: 10.1.5.1/24 Int 2: 10.1.64.2/24 Int 3: 10.1.66.1/24 Int 4: 10.1.67.1/24

Router 3: Int 1: 10.1.6.1/24 Int 2: 10.1.65.2/24 Int 3: 10.1.67.2/24

2 3 1 3 1

Router 4: Int 1: 10.1.7.1/24 Int 2: 10.1.66.2/24 Int 3: 10.1.68.2/24

.11

.12

.13

.14

Group members: S: 10.1.5.37 G: 239.192.12.42

No group members

PIM Prune Based on Loss of Group Presence: 2


IGMP Leave Group
Source: 10.1.5.37/24

Group members: S: 10.1.5.37 G: 239.192.12.42

.11

.12

.13

.14

Router 1 and Router 3 remain on the distribution tree as long as each has at least one group member on its user network. When the last member on Router 1s user network leaves the group, the router prunes itself from the tree.

Router 1: R Int 1: 10.1.4.1/24 Int 2: 10.1.64.1/24 Int 3: 10.1.65.1/24 Int 4: 10.1.68.1/24 3

PIM Prune message


2 2 4

Router 2: R Int 1: 10.1.5.1/24 Int 2: 10.1.64.2/24 Int 3: 10.1.66.1/24 Int 4: 10.1.67.1/24

Router 3: Int 1: 10.1.6.1/24 Int 2: 10.1.65.2/24 Int 3: 10.1.67.2/24

2 3 1 3 1

Router 4: Int 1: 10.1.7.1/24 Int 2: 10.1.66.2/24 Int 3: 10.1.68.2/24

.11

.12

.13

.14

Group members: S: 10.1.5.37 G: 239.192.12.42

No group members

Rev. 10.41

5 - 18

HP Switching and Routing Technologies

IP Multicast Protocols

PIM Sparse Multicast Traffic Distribution


The flood and prune multicast traffic distribution method employed by PIM Dense is appropriate in environments that provide plentiful bandwidth. PIM Sparse may be more suitable in environments where group members are widely dispersed, or connected by l lower-bandwidth b d dhl links. k The primary difference between PIM Dense and Sparse modes is the way routers build distribution trees. A single distribution tree carries traffic for all groups. The source node of the tree may be statically defined. Multicast traffic is never flooded downstream. PIM Sparse nodes forward the traffic only after they receive an explicit Join request from a downstream neighbor. PIM-SM routers use Hello messages to set up neighbor relationships with other PIM routers.
R3 R4
IGMP Join PIM Join

R7

PIM Join

R1

R2

R5

R6

Multicast group members

PIM Sparse Terminology


A PIM-SM domain consists of a group of interconnected routers running the PIM Sparse Mode protocol. A Rendezvous Point (RP) acts as the root node of the distribution tree for one or more p multicast g groups. Routers suitably located may be configured as RP Candidates (RP-C) for all or some portion of the multicast address range. A Bootstrap Router (BSR) distributes RP-toGroup mappings. A domain requires one dynamically elected BSR. Each network supports a Designated Router (DR) (DR). The DR on a source network encapsulates the multicast servers traffic and forwards it to the appropriate RP for distribution. A DR connected to a network with receivers originates the PIM Join messages that add the network to the distribution tree.
Multicast group members 10.1.5.3 Server 1: S: 10.1.5.17 10.1.5.17 10 G: 1 230.64.11.37 230 5 17 64 11 37

PIM-SM Domain
BSR for the domain

R7

RP for 239.192.0.0/10

RP for 239.64.0.0/10

R1

.1

R2

R5

10.1.5.0/24

DR for Network 10 1 5 0/24 10.1.5.0/24

.2

PIM Join

R3

R4

R6

Rev. 10.41

5 - 19

HP Switching and Routing Technologies

IP Multicast Protocols

Bootstrap Router Election: 1


After all PIM neighbor relationships have been established, each BSR Candidate originates Bootstrap message for each interface. Each PIM router forwards the Bootstrap messages to its PIM neighbors, replacing the Layer 2 and Layer 3 headers headers. The message is transmitted transmitted, one hop at a time, throughout the domain. The BSR Candidate with the highest priority is elected as the BSR of the domain. The active BSR will be responsible for distributing messages that associate multicast address ranges with Rendezvous Points (RP). If the active BSR becomes unavailable, the BSR Candidate with the next highest priority becomes assumes its responsibilities. bl
Bootstrap R7 messages .1 .1 .1
10.1.64.0/24 .2 10.1.65.0/24 .2

BSR Candidate

10.1.66.0/24 .2

R1

.1

R2

R5

.1

BSR Candidate

10.1.5.0/24 .2

10.1.12.0/24 .2

R3

R4

R6

Bootstrap Router Election: 2

Bootstrap Message sent by Router R7 Over Interface 10.1.64.1

Ethernet header: Dest: 01:00:5e:00:00:0d Source: <R7_MAC> Type: IP (0x0800) IP datagram header: Protocol: PIM (0x67) (Decimal: 103) Source: 10.1.64.1 Destination: 224.0.0.13
Bootstrap messages are sent to the All PIM Routers multicast group. Each PIM router changes the packets Layer 2 and Layer 3 addresses as it forwards the Bootstrap message.

Protocol Independent Multicast header: Version: 2 Type: Bootstrap (4) PIM parameters: t These h values l determine d which h h BSR S Candidate C dd will ll become the active BSR. The original BSR Hash mask len: 30 advertisement remains unchanged as the BSR priority: 10 Bootstrap message PIM is propagated throughout BSR: 10.1.66.1
the domain.

Rev. 10.41

5 - 20

HP Switching and Routing Technologies

IP Multicast Protocols

Rendezvous Point Candidate


Each multicast group requires a Rendezvous Point (RP) to serve as the root of the distribution tree. After the BSR has been elected, each candidate originates RP-Candidate advertisements addressed to the BSR. To achieve fault tolerance, configure at least two RP candidates with identical or overlapping address ranges. In the example, two PIM-SM routers are configured as RP Candidates for the entire multicast address range.
.2

BSR for the domain

.1 .1 .1

R7

10.1.64.0/24 .2

10.1.65.0/24 .2

10.1.66.0/24 .2

BSR Candidate

R1

.1

R2

R5

10.1.5.0/24

R3

R4

R6

Rendezvous Point Candidate: 2

RP Candidate Advertisement from Router R2


Ethernet header: Dest: <R7_MAC> Source: <R2_MAC> Type: IP (0x0800) IP datagram header: Protocol: PIM (0x67) (Decimal: 103) Source: 10.1.65.2 Destination: 10.1.66.1 Protocol Independent Multicast header: Version: 2 Type: Candidate RP Advertisement (8) PIM parameters: Prefix count: 1 Priority: y 255 Holdtime: 150 RP: 10.1.65.2 Group: 224.0.0.0/4

RP Candidates send their advertisements directly to the elected BSR, and not the PIM multicast group.

The PIM portion of the packet lists the multicast address ranges associated with this RP.

Rev. 10.41

5 - 21

HP Switching and Routing Technologies

IP Multicast Protocols

Advertising RP-to-Group Mappings: 1


When the BSR has received RP Candidate advertisements, its Bootstrap messages expand to include the associations between RPs and multicast group addresses. This association is known as the RP-Set. As the A h B Bootstrap messages move through h h the h domain, each PIM-SM router stores this information in a table. When a multicast receiver in network 10.1.6.0/24 joins a group by issuing an IGMP Membership Report, the edge router (R6) uses its table to identify the RP for that group. R6 sends a PIM Join message upstream to define the path to the RP. The tree that has the RP at its root is known k as the h RP Tree. T
BSR for the domain
R7

.1 .1 .1 10.1.66.0/24 .2

10.1.64.0/24 .2

10.1.65.0/24 .2 .1

R1

.1

R2

10.1.4.0/24 10.1.5.0/24 .2

RP for 224.0.0.0/4

R5

RP Candidate BSR Candidate

R3

.2

R4

R6

Advertising RP-to-Group Mappings: 2


Bootstrap Message Containing Mappings
Ethernet header: Dest: 01:00:5e:00:00:0d Source: <R7_MAC> Type: IP (0x0800) IP datagram d t h header: d Protocol: PIM (0x67) (Decimal: 103) Source: 10.1.64.1 Destination: 224.0.0.13

The BSR originates a copy of the Bootstrap message for each of its interfaces that support PIM neighbors. i hb It is i sent tt to th the multicast lti t address dd that includes all PIM routers.

Protocol Independent Multicast header: Type: Bootstrap (4) PIM parameters: Hash mask len: 30 BSR priority: 10 BSR: 10.1.65.1 Group 0: 224 224.0.0.0/4 0 0 0/4 RP count: 1 RP 0: 10.1.65.2 This message includes the RP-to-group mappings from all RP Candidate Priority: 192 Advertisements. Its contents are not Group 1: 224.0.0.0/4 limited to the active RP. RP count: 1 RP 0: 10.1.66.2 Priority: 255

Rev. 10.41

5 - 22

HP Switching and Routing Technologies

IP Multicast Protocols

Sharing RP Responsibilities
Individual RPs can be configured to act as the root of a tree that supports a subset of multicast addresses. This is often done to enable load sharing. Server 2: In the example, R2 and R5 have each been configured as Candidate RPs for only a portion of the multicast address space. R7 is configured as an RP Candidate for the entire multicast address space. As each multicast data transmission begins, the Designated Router (DR) for the source network consults its PIM tables and learns the identity of each RP RP. The DR encapsulates the traffic in an outer packet that specifies the unicast IP address of the RP. The RP decapsulates the packets and sends them downstream.
Server 1: S: 10.1.5.17 G: 239.64.11.37

BSR for the domain

.1 .1 .1

R7

RP Candidate: 224.0.0.0/4

S: 10.1.5.3 G: 239.192.12.42

10.1.64.0/24 .2

10.1.65.0/24 .2 .1

10.1.66.0/24 .2

R1
.1 10.1.5.0/24

10.1.4.0/24

RP for R2 239.192.0.0/10

R5

RP for 239.64.0.0/10

DR for Network 10.1.5.0/24

.2

R3

.2

R4

R6
10.1.10.0/24

10.1.6.0/24

Group members: 239.192.12.42

Group members: 239.64.11.37

The Shortest Path Tree


The placement of RPs must be carefully considered. Multicast traffic between Server 1 and receivers in the network 10.1.10.0/24 follows an inefficient path because the traffic must cross the RP for that group. Placing RPs in a central location is likely to produce a more efficient RP Tree. However, appropriately configured PIM-SM routers may shift an established multicast traffic flow from the RP Tree to the Shortest Path Tree (SPT). The flow can shift to the SPT only after the path through the RP has been established.
Server 1: S: 10.1.5.17 G: 239.64.11.37

BSR for the domain

Server 2: S: 10.1.5.3 G: 239.192.12.42

.1 .1 .1

R7

RP Candidate: 224.0.0.0/4

10.1.64.0/24 10 1 64 0/24 .2

10 1 65 0/24 10.1.65.0/24 .2 .1

10.1.66.0/24 10 1 66 0/24 .2

R1
.1 10.1.5.0/24

10.1.4.0/24

RP for R2 239.192.0.0/10

R5

RP for 239.64.0.0/10

DR for Network 10.1.5.0/24

.2

R3

.2

R4

R6
10 1 10 0/24 10.1.10.0/24

10 1 6 0/24 10.1.6.0/24

Group members: 239.192.12.42

Group members: 239.64.11.37

Rev. 10.41

5 - 23

HP Switching and Routing Technologies

IP Multicast Protocols

Module 5 Summary
This module described the operation of three protocols that enable transmission of multicast traffic within an intranet. In this module you learned: The format of IGMP messages, and how network devices use IGMP information to forward multicast traffic to g group p members The behavior of routers using PIM Dense mode, including the messages they use to become neighbors, and join and leave the distribution tree The similarities between PIM Dense and Sparse modes How the Rendezvous Point and Bootstrap Routers distribute information to other routers that use PIM-Sparse

Rev. 10.41

5 - 24

HP Switching and Routing Technologies

Delivering Quality of Service

Module 6: Delivering Quality of Service


Objectives
This module will reveal some procedures and technologies that have been developed to enable IP networks to support voice and video traffic. After completing this module, you will be able to: Compare and contrast the characteristics of and requirements for data traffic and real-time traffic. Describe Layer 2 and Layer 3 prioritization standards and their appropriate implementations in contemporary enterprise networks Describe the LLDP-MED standard and its relevance to QoS for VoIP and other applications

Lesson 1 Introduction
Bandwidth is typically provisioned based on a calculated average percentage of utilization per client computer. Adequate provisioning is the first step in providing QoS for time-sensitive traffic. For example, an access switch supporting 20 gigabit clients at 5% utilization would require a 1-Gbps uplink. Clients may periodically burst to their maximum bandwidth. bandwidth The switch uses packet buffering to maintain forwarding in the face of higher traffic volumes. If the congestion continues for long enough, some packets will be delayed or even discarded. Because congestion has a more negative effect on time-sensitive traffic than some other types, one goal of QoS is to control which y to be discarded when congestion g occurs. traffic is least likely
1- Gbps uplink

[20 gigabit clients @ 5% average utilization]

Rev. 10.41

6-1

HP Switching and Routing Technologies

Delivering Quality of Service

TCP Traffic Characteristics


The response of senders and receivers to delayed and dropped packets depends on the transport protocol they are using. Data traffic is intolerant of dropped packets. At the start of a conversation, hosts using an application that relies on TCP (rollover text: Transmission Control Protocol) set up an acknowledged, flow controlled session.

Host1 Application Transport (TCP)

Host2 Application

Network (IP) Data Link Physical

Among other items, the hosts negotiate a window size (rollover text: limits the how many packets can be in transit and unacknowledged) that hosts use to slow down their transmission when they detect congestion. An acknowledgement timer defines the length of time each host will wait for acknowledgements from the other.

Transport (TCP)

Network (IP) Data Link Physical

TCP Provides Acknowledgment:1


TCP creates segments from each message it receives from the application. The TCP header contains a segment number that represents the number of bytes offset from the start of the message. The receiver uses this information to acknowledge packets to the sender and also to reassemble packets in the correct order.

Host1
Application

Host2
Application

Transport 4 (TCP) 3 2 1

The transport layer creates sequentially numbered segments and sends them to the Network layer.

Transport (TCP)

Network (IP) Data Link Physical

The message may be further segmented at Network and Data Link Layers as it is encapsulated and transmitted.

Network (IP) Data Link Physical

Rev. 10.41

6-2

HP Switching and Routing Technologies

Delivering Quality of Service

TCP Provides Acknowledgment: 2


TCP creates segments from each message it receives from the application. The TCP header contains a segment number that represents the number of bytes offset from the start of the message. The receiver uses this information to acknowledge packets to the sender and also to reassemble packets in the correct order.

Host1
Application

Host2
If Host1 does not receive acknowledgement of packets 3 and 4 before its timer expires, it retransmits them. Host2 acknowledges receipt of packets 1 and 2 by including the highest received segment number in the TCP header of packets it sends to Host1.
Application

Transport 4 (TCP) 3 2 1

Transport (TCP)

Network (IP) Data Link Physical

If the number of delayed or retransmitted packets is outside a predefined tolerance level, the hosts negotiate a smaller window size, effectively backing down the transmission speed.

Network (IP) Data Link Physical

UDP Provides No Flow Control


User Datagram Protocol (UDP) is a simpler transport protocol. While it does add a header to identify the originating application, it does not provide flow control or acknowledgement services. Applications that transmit data traffic over UDP typically include their own acknowledgement mechanism to force retransmission of lost packets. Without flow control, hosts have no way to detect congestion and slow down their transmission. In this case, the packets retransmitted due to congestion , leading g to further congestion. g increase traffic volume,

Host1
Application

Host2
Application

Transport (UDP)

Transport (UDP)

Network (IP) Data Link Physical

Network (IP) Data Link

Physical

Rev. 10.41

6-3

HP Switching and Routing Technologies

Delivering Quality of Service

Steps to Achieving QoS


A converged infrastructure must consider the special needs of time-sensitive traffic. You will learn more about network design in other training. Generally speaking, however, designers follow some basic steps to limit congestion. 1. Provision sufficient bandwidth: measure actual utilization or calculate based on well-known rules of thumb: g bandwidth p per voice session: 3-100 Kbps p Average Average bandwidth per video stream: 2-8 Mbps 2. Create broadcast domain boundaries that limit the scope of broadcast traffic Provide dedicated voice VLANs to prevent unnecessary data traffic Even with the most careful planning, congestion is somewhat inevitable, requiring another step. 3. Enable time-sensitive traffic to be handled by network devices with higher priority than other traffic. The goal of prioritization is to limit jitter and delay. This module is focused on prioritization mechanisms. 3. Prioritize time-sensitive traffic ahead of normal traffic 2. Control to eliminate unnecessary traffic 1. Provision sufficient bandwidth

Queuing Example for Undifferentiated Traffic


Queuing enables time-sensitive traffic to be forwarded ahead of normal traffic. It is not the only mechanism, but it is the one we will look at first. In this example, the switch accepts many types of traffic through edge ports and forwards them through its uplink. If all traffic types have the same priority, packets are forwarded in the order they arrive at the egress port. A l As long as there h is no congestion, this h is satisfactory f for f all ll types of f traffic. ff When congestion occurs, packets arrive at the egress port more quickly than the uplink can transmit them. Time-sensitive traffic is likely to arrive at its destination exhibiting unacceptable levels of jitter and delay.
Edge ports Uplink

UDP data t ffi traffic Voice traffic TCP data traffic


Ingress ports Egress port

Rev. 10.41

6-4

HP Switching and Routing Technologies

Delivering Quality of Service

Prioritized Queues Accept Differentiated Traffic


Time-sensitive traffic such as VoIP functions best in conditions of low jitter and delay. QoS-capable switches ensure low levels of delay and jitter by transmitting time-sensitive traffic before data traffic, which is less sensitive to delay. Traffic that is identified as high priority is placed in a separate queue from other traffic. For simplicity, p y, we will use an example p with four q queues. Many y QoS-capable p switches support pp eight g queues.

UDP data t ffi traffic Voice traffic TCP data traffic


Ingress ports

4( (highest g es p priority) o y) 3 (medium priority) 2 (normal priority) 1 (lowest priority)

Egress port queues

Strict Priority Queuing


If the switch is using strict priority queuing, all packets in higher priority queues will be serviced (transmitted over the physical link) before any packets in lower priority queues. Packets that arrive in higher priority queues will interrupt servicing of packets in lower priority queues. This creates the opportunity for starving lower priority queues to the point that data traffic can suffer.

Edge ports

Uplink

UDP data traffic ff Voice traffic TCP data traffic Ingress ports

4 3 2 1

Egress port queues

Egress port

Rev. 10.41

6-5

HP Switching and Routing Technologies

Delivering Quality of Service

Weighted Fair Queuing


Weighted fair queuing is a method designed to ensure that no queue is completely starved from servicing. Each queue is assigned a bandwidth percentage, and the total of all queue minimum bandwidth values equals 100%. The allocation defines how much bandwidth each queue gets during a service cycle. In the example, the highest priority queue (4) is allocated 45% of the total bandwidth. Higher priority queues are always serviced before lower priority queues. When a number of bytes equal to this bandwidth percentage have been , the next highest g p priority yq queue is serviced. forwarded, Queue 3 is allocated a bandwidth percentage; however, it contains no waiting packets. Servicing moves on to the normal priority queue (2), and the low priority queue (1). At the end of the cycle, the remaining capacity is allocated to the highest priority queue that has packets waiting. Edge ports Uplink

UDP data traffic ff Voice traffic TCP data traffic Ingress ports Egress port queues

4 3 2 1

45% 15% 35% 5%

Egress port

Layer 2 Priority Marker


Devices requesting priority handling for their traffic include a marker indicating the priority level that should be applied. Traffic may be marked within the 802.1Q tag in each packets Layer 2 header.
Layer 2 header (18 bytes) Dest. MAC (6 bytes) IP datagram header (20 bytes) Source MAC (6 bytes) VLAN tag (4 bytes) Remainder of packet (< 1500 bytes) Type (2)
Canonical Format Indicator (1 bit)

IEEE 802.1Q tag


VLAN Protocol ID (16 bits) Priority (3 bits)
000 001 010 011 100 101 110 111

VLAN ID (1-4094) (12 bits)

8 possible values in 3-bit prioritization field

Most IP phones and many other devices sending time-sensitive traffic use Layer 2 markers to indicate priority. Devices may also request priority handling by marking the Type of Service field in the IPv4 datagram header.

Rev. 10.41

6-6

HP Switching and Routing Technologies

Delivering Quality of Service

Priority Mechanisms: 1
Recognition of time-sensitive traffic and forwarding it ahead of normal traffic are two of the three formalized steps involved in prioritization. 1. Classification The switch reads the packet header to learn its priority and assigns it to a traffic class, which is also known as internal forwarding priority. 2 2. Marking If the switch will need to create a new header for the packet, it modifies the header to reflect the appropriate priority value. Packets are marked for the benefit of other QoS-capable devices which may handle the packet downstream. 3. Scheduling The switch places the packet in the queue associated with its traffic class. The 802.1Q standard specifies relative priority of the traffic classes. Some switches require QoS support to be manually enabled. ProVision ASIC switches are able to classify, mark, and schedule traffic as soon as you have configured VLANs.

Priority Mechanisms: 2
802.1p value Binary 111 110 101 100 011 010 001 000 Decimal 7 6 5 4 3 0 2 1 Traffic class (highest) 7 6 5 4 3 (normal) 0 2 (lowest) 1 When mapped to 8 queues (highest) 8 7 6 5 4 (normal) 3 2 (lowest) 1 (lowest) 1 (normal) 2 (normal) 1 (medium) 3 When mapped to 4 queues (highest) 4 When mapped to 2 queues (high) 2

Rev. 10.41

6-7

HP Switching and Routing Technologies

Delivering Quality of Service

Switch Forwards Traffic With High Priority


Observe as we step through a simple prioritization scenario involving an HP Networking E-series switch, the 3500. 1. 2. 3. 4. The phone marks voice traffic with priority level 6. The switch interprets the priority value in the 802.1Q tag of inbound traffic. The switch assigns the packet to traffic class 6 (Classify). The switch places the packet in the outbound port queue associated with traffic class 6 (Schedule).

The switch does not need to mark the header because the packet is being forwarded at Layer 2. Specifically, the destination port is in the same VLAN as the source port. Note that the priority marker (110) remains intact in the header after the packet has been forwarded.

Priority (binary) VLAN ID (represented in decimal) [MAC header] ... 110 ... 130... [IP header]
802.1Q tag

Layer 2 switch

Priority (binary) VLAN ID (represented in decimal) [MAC header] ... 110 ... 130... [IP header]
802.1Q tag

Retaining Priority When Routing


The next switch in the packets path is an HP networking E5406 switch. Based on packet lookup, the switch has determined that the port leading to the packets destination is in a different VLAN from the source port. The switch interprets the priority value in the packets 802.1Q tag and performs the following steps: 1. 2. 3.

Priority (binary)

VLAN ID (decimal)

[MAC header] ... 110 ... 132... [IP header]


8021Q tag 802.1Q

Classify: y Assign g the p packet to traffic class 6 Mark: Record binary value 6 in the 802.1Q tag of the new header the switch creates for the routed packet. Schedule: Place the packet in the queue associated with traffic class 6.

Layer 3 switch

Outbound port: VLAN 132

Priority (binary) VLAN ID (represented ) in decimal) [MAC header] ... 110 ... 130... [IP header]
802.1Q tag

Inbound port: VLAN 130

Layer 2 switch

Rev. 10.41

6-8

HP Switching and Routing Technologies

Delivering Quality of Service

Forwarding Normal Priority Traffic


In this example, the switch accepts data traffic coming from an IP host connected to an untagged port. The switch interprets this as normal traffic; however, because it will forward the packet over a tagged link, it performs all three steps: 1. 2. 3. Classify: assign packet to traffic class 0 Mark: record traffic class 0 in the 802.1Q tag the switch adds to the packet. place the p packet in the q queue associated with traffic class 0. Schedule: p

Layer 3 switch

In the absence of a specific policy, this Layer 3 switch will forward the packet with normal priority whether it is forwarded over tagged or untagged links

Priority (binary) VLAN ID (represented in decimal) [MAC header] ... 000 ... 24... [IP header]
802.1Q tag

The inbound port is a tagged member of VLAN 24.

Layer 2 switch
This port is an untagged member of VLAN 24

The uplink is a tagged member of VLAN 24

[MAC header] [IP header]


(No 802.1Q tag)

Host sending untagged TCP traffic

Benefits of Marking Priority at Layer 3


Priority settings marked in the 802.1Q tag are typically retained by switches that forward a packet over tagged links. However, when a packet is forwarded over an untagged link, the tag is stripped, and the priority marker is lost. This is true whether the packet in question is forwarded at Layer 2 or Layer 3. The IP datagram header t typically picall remains intact when traffic is forwarded at both La Layer er 2 and La Layer er 3 3. Layer 3 priority settings marked at the edge are likely to be retained from end to end. A QoS-capable router is typically configured to interpret the contents of the 8-bit TOS field in one of two ways. Layer 2 header (18 bytes) IP datagram header (20 bytes) Remainder of packet (variable <1500 bytes)

Version (4) HL (4 bits) Type of Service (8 bits) Identifier (16 bits) Time to Live (8 bits) Protocol (8 bits) Flags (3) Source Address (32 bits)

Total Length (16 bits) Fragment Offset (13 bits) Header Checksum (16 bits)

Destination Address (32 bits)

Rev. 10.41

6-9

HP Switching and Routing Technologies

Delivering Quality of Service

IP Precedence ToS Definition


The original ToS definition is IP Precedence. It uses three most significant (high order) bits in the ToS field.

Positions 3-7 of the TOS field are unused in most implementations.

The decimal value of the entire TOS field is 160.

A packet decoder would display the hexadecimal value of the entire TOS field: A0.

DiffServ ToS Definition


Differentiated Services (DiffServ) is a more recent definition, using six bits in the ToS field.

Only 13 of the 64 possible values are standardized as DiffServ CodePoints (DSCP). Expedited Forwarding (EF) is assigned the highest user-defined value using the DiffServ definition: 46

Rev. 10.41

6 - 10

HP Switching and Routing Technologies

Delivering Quality of Service

Lesson 2 Introduction
LLDP is a useful protocol that enables switches to dynamically learn the identity and other characteristics of their neighbors. An LLDP extension for Media Endpoint Devices (LLDP-MED) enables phones and other endpoints to report their requirements and capabilities to a connected switch. In this lesson you will learn some of the benefits of LLDP-MED.

LLDP

LLDP

LLDP-MED

Using VLANs to Isolate Voice Traffic


In most cases, a phone and PC share the same physical connection to an edge switch port. The phone is connected directly to the jack, and the users PC is connected to a port on the phone. The phone contains a two-port MAC relay that tags VoIP traffic with the ID of the voice VLAN, and sends PC traffic untagged. Isolating voice and data traffic in separate VLANs is an accepted VoIP best p practice. Assignment of phones to voice VLANs may be time-consuming for a large deployment. LLDP-MED is a standard protocol which enables, among many other items, dynamic assignment of phone connections to voice VLANs.

To wiring closet

2-port MAC relay

Rev. 10.41

6 - 11

HP Switching and Routing Technologies

Delivering Quality of Service

Basic LLDP Review: 1


LLDP is a simple, two-way protocol that enables standardized in 2005 as IEEE 802.1AB. Devices supporting LLDP send periodic advertisements containing system and source port identification, software image versions, serial numbers, and many other items.

Transmit and receive operations are independent The switch creates a unique message to be sent over each link Received LLDP messages are not forwarded over other links LLDP messages can be forwarded over links blocked by Spanning Tree

LLDP advertisements are sent to a Layer 2 multicast address. Each advertisement a series of TLVs, each of which provides a single type of information.
MIB Port A1 Device Switch1 Type Switch Info xxxx
A1

Switch2

MIB Port 50 Device Switch2 Type Router Info xxxx

Switch1

50

Switch ID & capabilities

Basic LLDP Review: 2


LLDP Message

Rev. 10.41

6 - 12

HP Switching and Routing Technologies

Delivering Quality of Service

Module 6 Summary
This module described some of the technologies used to provide priorities for traffic generated by time-sensitive applications. Topics included: Classification and scheduling strategies employed by switches Marking Priority within the IEEE 802.1Q tag and IP datagram header

Rev. 10.41

6 - 13

To learn more about HP networking, visit www.hp.com/networking


2010 Hewlett-Packard Development Company, L.P. The information contained herein is

subject to change without notice. The only warranties for HP products and services are set forth in the express warranty statements accompanying such products and services. Nothing herein should be construed as constituting an additional warranty. HP shall not be liable for technical or editorial errors or omissions contained herein.

Вам также может понравиться