Anda di halaman 1dari 131

ZXR10 ZSR

Intelligent Integrated Multi-Service Router

User Manual (IPv4 Routing Volume)


Version: V2.8.11

ZTE CORPORATION
NO. 55, Hi-tech Road South, ShenZhen, P.R.China
Postcode: 518057
Tel: +86-755-26771900
Fax: +86-755-26770801
URL: http://ensupport.zte.com.cn
E-mail: support@zte.com.cn

LEGAL INFORMATION
Copyright 2011 ZTE CORPORATION.
The contents of this document are protected by copyright laws and international treaties. Any reproduction or
distribution of this document or any portion of this document, in any form by any means, without the prior written
consent of ZTE CORPORATION is prohibited.

Additionally, the contents of this document are protected by

contractual confidentiality obligations.


All company, brand and product names are trade or service marks, or registered trade or service marks, of ZTE
CORPORATION or of their respective owners.
This document is provided as is, and all express, implied, or statutory warranties, representations or conditions
are disclaimed, including without limitation any implied warranty of merchantability, fitness for a particular purpose,
title or non-infringement. ZTE CORPORATION and its licensors shall not be liable for damages resulting from the
use of or reliance on the information contained herein.
ZTE CORPORATION or its licensors may have current or pending intellectual property rights or applications
covering the subject matter of this document. Except as expressly provided in any written license between ZTE
CORPORATION and its licensee, the user of this document shall not acquire any license to the subject matter
herein.
ZTE CORPORATION reserves the right to upgrade or make technical change to this product without further notice.
Users may visit ZTE technical support website http://ensupport.zte.com.cn to inquire related information.
The ultimate right to interpret this product resides in ZTE CORPORATION.

Revision History
Revision No.

Revision Date

Revision Reason

R2.0

2011-08-30

First revision

R1.0

2009-01-08

First edition

Serial Number: SJ-20110803091932-005


Publishing Date: 2011-08-30 (R2.0)

Contents
About This Manual ......................................................................................... I
Chapter 1 Safety Instructions.................................................................... 1-1
1.1 Safety Introduction ............................................................................................. 1-1
1.2 Safety Description .............................................................................................. 1-1

Chapter 2 Static Route Configuration ...................................................... 2-1


2.1 Static Route Overview ........................................................................................ 2-1
2.2 Configuring Static Route ..................................................................................... 2-1
2.3 Configuring Static Route Maintenance and Diagnosis ........................................... 2-2
2.4 Static Route Configuration Example .................................................................... 2-2
2.4.1 Basic Static Route Configuration Example ................................................. 2-2
2.4.2 Static Route Summary Configuration Example ........................................... 2-4
2.4.3 Default Route Configuration Example ........................................................ 2-5

Chapter 3 RIP Configuration ..................................................................... 3-1


3.1 RIP Overview..................................................................................................... 3-1
3.1.1 RIP Route Metric and Administrative Distance............................................ 3-1
3.1.2 RIP Timers............................................................................................... 3-2
3.1.3 RIP Route Update .................................................................................... 3-2
3.2 Configuring RIP.................................................................................................. 3-2
3.2.1 Enabling RIP............................................................................................ 3-2
3.2.2 Adjusting RIP Timer.................................................................................. 3-3
3.2.3 Configuring RIP Neighbor ......................................................................... 3-4
3.2.4 Configuring RIP Authentication.................................................................. 3-4
3.2.5 Configuring Split Horizon and Poison Reverse ........................................... 3-4
3.2.6 Configuring Route Redistribution ............................................................... 3-5
3.2.7 Configuring RIP Interface Mode ................................................................ 3-5
3.2.8 Configuring RIP Version............................................................................ 3-5
3.3 Configuring RIP Maintenance and Diagnosis........................................................ 3-6
3.4 RIP Configuration Example ................................................................................. 3-7

Chapter 4 OSPF Configuration.................................................................. 4-1


4.1 OSPF Overview ................................................................................................. 4-1
4.1.1 OSPF Algorithm ....................................................................................... 4-2
4.1.2 OSPF Network Types ............................................................................... 4-2
4.1.3 Hello Packet and Timers ........................................................................... 4-2
I

4.1.4 OSPF Neighbors ...................................................................................... 4-3


4.1.5 Adjacency and Designated Router............................................................. 4-3
4.1.6 Router Priority and DR Election................................................................. 4-4
4.1.7 OSPF Area .............................................................................................. 4-4
4.1.8 LSA Type and Flooding ............................................................................ 4-5
4.1.9 Stub Area and Totally Stub Area................................................................ 4-6
4.1.10 Not-So-Stubby Area ............................................................................... 4-7
4.1.11 OSPF Authentication .............................................................................. 4-7
4.2 Configuring OSPF .............................................................................................. 4-7
4.2.1 Enabling OSPF ........................................................................................ 4-7
4.2.2 Configuring OSPF Interface Timer ............................................................. 4-8
4.2.3 Configuring OSPF Interface Cost .............................................................. 4-8
4.2.4 Configuring OSPF Interface Priority ........................................................... 4-9
4.2.5 Configuring OSPF Neighbor Router........................................................... 4-9
4.2.6 Configuring OSPF Area ............................................................................ 4-9
4.2.7 Configuring OSPF Inter-Area Route Aggregation...................................... 4-10
4.2.8 Configuring OSPF Default Route Notification ........................................... 4-10
4.2.9 Configuring OSPF Virtual Links ................................................................4-11
4.2.10 Configuring OSPF Route Redistribution ................................................. 4-12
4.2.11 Configuring OSPF Authentication .......................................................... 4-13
4.2.12 Configuring Routes to Support Opaque LSA .......................................... 4-13
4.2.13 Modifying OSPF Administrative Distance ............................................... 4-14
4.3 Configuring OSPF Maintenance and Diagnosis .................................................. 4-14
4.4 OSPF Configuration Example ........................................................................... 4-16
4.4.1 Basic OSPF Configuration Example ........................................................ 4-16
4.4.2 Multi-Area OSPF Configuration Example ................................................. 4-16
4.4.3 OSPF Virtual Link Configuration Example ................................................ 4-19
4.4.4 OSPF Authentication Configuration Example ........................................... 4-20

Chapter 5 IS-IS Configuration ................................................................... 5-1


5.1 IS-IS Overview ................................................................................................... 5-1
5.1.1 IS-IS Area................................................................................................ 5-2
5.1.2 IS-IS Network Types................................................................................. 5-2
5.1.3 DIS and Router Priority ............................................................................. 5-3
5.2 Configuring IS-IS................................................................................................ 5-3
5.2.1 Enabling IS-IS.......................................................................................... 5-3
5.2.2 Configuring IS-IS Global Parameters ......................................................... 5-4
5.2.3 Configuring IS-IS Interface Parameters...................................................... 5-5

II

5.2.4 Configuring IS-IS Authentication................................................................ 5-6


5.3 Configuring IS-IS Maintenance and Diagnosis...................................................... 5-6
5.4 IS-IS Configuration Example ............................................................................... 5-7

Chapter 6 BGP Configuration.................................................................... 6-1


6.1 BGP Overview ................................................................................................... 6-1
6.2 Configuring BGP ................................................................................................ 6-2
6.2.1 Enabling BGP .......................................................................................... 6-2
6.2.2 Configuring BGP Route Advertisement ...................................................... 6-3
6.2.3 Configuring BGP Route Aggregation ......................................................... 6-5
6.2.4 Configuring EBGP Multi-Hops ................................................................... 6-6
6.2.5 Filtering Routes by Using Route Map......................................................... 6-7
6.2.6 Filtering Routes by Using NLRI ................................................................. 6-8
6.2.7 Filtering Routes by Using AS_PATH .......................................................... 6-9
6.2.8 Configuring LOCAL_PREF Attribute ........................................................ 6-10
6.2.9 Configuring MED Attribute ...................................................................... 6-12
6.2.10 Configuring Community Attribute ........................................................... 6-14
6.2.11 Configuring BGP Synchronization .......................................................... 6-15
6.2.12 Configuring BGP Route Reflector .......................................................... 6-16
6.2.13 Configuring BGP Confederation ............................................................ 6-19
6.2.14 Configuring BGP Route Dampening ...................................................... 6-21
6.3 Configuring BGP Maintenance and Diagnosis .................................................... 6-21
6.4 BGP Configuration Example ............................................................................. 6-23

Chapter 7 Policy Routing Configuration .................................................. 7-1


7.1 Policy Routing Overview ..................................................................................... 7-1
7.2 Configuring Policy Routing .................................................................................. 7-3
7.3 Policy Routing Configuration Example ................................................................. 7-4

Chapter 8 Load Balancing Configuration................................................. 8-1


8.1 Load Balancing Overview ................................................................................... 8-1
8.2 Configuring Load Balancing ................................................................................ 8-2
8.3 Configuring Load Balancing Maintenance and Diagnosis ...................................... 8-3
8.4 Load Sharing Configuration Example................................................................... 8-4
8.5 Default Load Balancing Configuration Example .................................................... 8-8
8.6 Dynamic Load Balancing Configuration Example................................................ 8-14

Chapter 9 Multicast Routing Configuration ............................................. 9-1


9.1 Multicast Overview ............................................................................................. 9-1
9.1.1 Multicast Address..................................................................................... 9-1
9.1.2 IGMP....................................................................................................... 9-2
III

9.1.3 Multicast Tree .......................................................................................... 9-3


9.1.4 Multicast Routing Protocol ........................................................................ 9-4
9.1.5 PIM-SM ................................................................................................... 9-4
9.1.6 MSDP ..................................................................................................... 9-6
9.2 Enabling IP Multicast .......................................................................................... 9-6
9.3 Configuring IGMP............................................................................................... 9-6
9.3.1 Configuring IGMP Version......................................................................... 9-6
9.3.2 Configuring IGMP Group on Interface ........................................................ 9-6
9.3.3 Configuring IGMP Timer ........................................................................... 9-7
9.4 Configuring Static Multicast................................................................................. 9-8
9.5 Configuring PIM-SM ........................................................................................... 9-8
9.5.1 Enabling PIM-SM ..................................................................................... 9-8
9.5.2 Configuring PIM-SM Parameters ............................................................. 9-10
9.5.3 Configuring PIM-SM Policy Control...........................................................9-11
9.6 Configuring MSDP.............................................................................................9-11
9.6.1 Enabling MSDP.......................................................................................9-11
9.6.2 Configuring Extended MSDP................................................................... 9-12
9.6.3 Configuring MSDP Policy........................................................................ 9-12
9.6.4 Clearing MSDP Status............................................................................ 9-12
9.7 Configuring Multicast Maintenance and Diagnosis .............................................. 9-13
9.7.1 Configuring Public Multicast Maintenance and Diagnosis .......................... 9-13
9.7.2 Configuring IGMP Maintenance and Diagnosis......................................... 9-13
9.7.3 Configuring PIM-SM Maintenance and Diagnosis ..................................... 9-14
9.7.4 Configuring MSDP Maintenance and Diagnosis ....................................... 9-16
9.7.5 Configuring Static Multicast Maintenance and Diagnosis........................... 9-17
9.8 Multicast Configuration Example ....................................................................... 9-17
9.8.1 PIM-SM Configuration Example .............................................................. 9-17
9.8.2 MSDP Configuration Example ................................................................. 9-19

Figures............................................................................................................. I
Tables ............................................................................................................ III
Glossary .........................................................................................................V

IV

About This Manual


Purpose
At first, thank you for choosing ZXR10 routers of ZTE Corporation!
This manual provides procedures and guidelines that support the operation of ZXR10 ZSR
(V2.8.11) Intelligent Integrated Multi-Service Router.

Intended Audience
This manual is intended for the following engineers:
l
l
l

Network planning engineer


Commissioning engineer
On-duty personnel

What Is in This Manual


This manual contains the following chapters:
Chapter

Summary

Chapter 1 Safety Instructions

This chapter describes the safety instructions and signs

Chapter 2 Static Route Configuration

This chapter describes static route and its configuration,


including special summary static route

Chapter 3 RIP Configuration

This chapter describes Routing Information Protocol (RIP)


configuration

Chapter 4 OSPF Configuration

This chapter describes Open Shortest Path First (OSPF)


protocol and related configuration

Chapter 5 IS-IS Configuration

This chapter describes IS-IS protocol and related configuration

Chapter 6 BGP Configuration

This chapter describes Border Gateway Protocol (BGP) and


related configuration

Chapter 7 Policy Routing

This chapter describes Policy Routing and related configuration

Configuration
Chapter 8 Load Balancing

This chapter describes Load Balancing on ZXR10 ZSR

Configuration
Chapter 9 Multicast Routing

This chapter describes basic principle and configuration of

Configuration

IP multicast

Conventions
ZTE documents employ the following typographical conventions.

Typeface

Meaning

Italics

Variables in commands. It may also refers to other related manuals and documents.

Bold

Menus, menu options, function names, input fields, option button names, check boxes,
drop-down lists, dialog box names, window names, parameters and commands.

CAPS

Keys on the keyboard and buttons on screens and company name.

Constant

Text that you type, program codes, filenames, directory names, function names.

width
[]

Optional parameters.

{}

Mandatory parameters.

Separates individual parameter in series of parameters.


Danger: Indicates an imminently hazardous situation, which if not avoided, will result in
death or serious injury.
Warning: Indicates a hazard that, if not avoided, could result in serious injuries,
equipment damages or interruptions of major services.
Caution: Indicates a potential hazard that, if not avoided, could result in moderate
injuries, equipment damages or partial service interruption.
Note: Provides additional information about a certain topic.
Checkpoint: Indicates that a particular step needs to be checked before proceeding
further.
Tip: Indicates a suggestion or hint to make things easier or more productive for the
reader.

II

Chapter 1

Safety Instructions
Table of Contents
Safety Introduction .....................................................................................................1-1
Safety Description ......................................................................................................1-1

1.1 Safety Introduction


In order to operate the equipment in a proper way, follow these instructions:
l
l

Only qualified professionals are allowed to perform installation, operation and


maintenance due to the high temperature and high voltage of the equipment.
Observe the local safety codes and relevant operation procedures during equipment
installation, operation and maintenance to prevent personal injury or equipment
damage. Safety precautions introduced in this manual are supplementary to the local
safety codes.
ZTE bears no responsibility in case of universal safety operation requirements
violation and safety standards violation in designing, manufacturing and equipment
usage.

1.2 Safety Description


Contents deserving special attention during configuration of ZXR10 ZSR are explained in
the following table.
Table 1-1 SAFETY DESCRIPTION
Convention

Meaning

Note

Provides additional information

Important

Provides great significance or consequence

Result

Provides consequence of actions

Example

Provides instance illustration

1-1
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

This page intentionally left blank.

1-2
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 2

Static Route Configuration


Table of Contents
Static Route Overview ................................................................................................2-1
Configuring Static Route.............................................................................................2-1
Configuring Static Route Maintenance and Diagnosis ................................................2-2
Static Route Configuration Example ...........................................................................2-2

2.1 Static Route Overview


Static route means the route information designated by the network administrator to the
routing table through the configuration commands. Unlike a dynamic route, it does not
set up the routing table based on routing algorithm. When configuring a dynamic route,
routing information of the entire Internet must be sent to a router, which is hard to hold the
load. In this case, static routes can be used to solve the problem.
Only a few configurations of the static route are needed to avoid the use of dynamic route.
However, in a routing environment where there are multiple routers and paths, however, it
is very complicated to configure the static routes.

2.2 Configuring Static Route


To configure a static route, use the following command.
Format

Function

ZXR10(config)#ip route [ vrf < vrf-name> ] < prefix> < net-mask> { <

This configures static route.

forwarding-router's-address> | < interface-name> } [ < distance-metric> ] [


tag < tag> ]

Parameter description for the command is as follows:


Parameter

Description

< vrf-name>

It is used to configure the static route in designated VRF, with the


length of VRF name to be 1-16 characters.

< distance-metric>

It is the distance metric, in range of 1-255 with 1 to be the default


value.

< tag>

It is the tag value, used to control route redistribution, in range of


150-255 with 3 to be the default value.

2-1
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Tip:
Tag is a route label. Two static routes (with different next hop IP addresses) to the same
destination network cannot have the same tag value.

2.3 Configuring Static Route Maintenance and


Diagnosis
To configure static route maintenance and diagnosis, use the following commands.
Format

Function

ZXR10#show ip route [ < ip-address> [ < net-mask> ] | < protocol> ]

This displays the global routing table of


router.
This displays route-related information

ZXR10#show ip protocol routing

in protocol stack.

2.4 Static Route Configuration Example


2.4.1 Basic Static Route Configuration Example
Figure 2-1 shows a simple network, in which three routers are interconnected.
Figure 2-1 Static Route Configuration

2-2
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 2 Static Route Configuration

For R1 accessing the network on R3, two configuration methods are available:
l

Method One
R1(config)#ip route 192.168.5.0 255.255.255.0 192.168.4.2
R1(config)#ip route 192.168.6.0 255.255.255.0 192.168.4.2

As shown in above configuration information, the static route is configured in global


configuration mode and only one static route can be configured at a time. Following
the IP route command, remote network, its subnet mask, and the next hop IP address
to the remote address are configured. In other words, to send packets to the network
192.168.5.0/24, firstly R1 must send the packets to R2 (IP address 192.168.4.2). R1
and R2 are directly interconnected.
l

Method Two
R1(config)#ip route 192.168.5.0 255.255.255.0 ce1_2/1.1
R1(config)#ip route 192.168.6.0 255.255.255.0 ce1_2/1.1

It is similar to method one and the only difference is that the next-hop IP address
is used in method one, while local interface is used in this configuration. That is,
all packets to 192.168.5.0/24 and 192.168.6.0/24 are sent out through CE1 interface
ce1_2/1.1 instead of being routed to logic address of the next-hop. The local interface
mode is not applicable to Ethernet interfaces.
If there are multiple paths to the same destination, a router is configured with multiple
static routes with different administrative distances. However, routing table only displays
information of the route with the minimum administrative distance. The reason is that when
router is informed of multiple competition sources to a network, the route with the minimum
administrative distance takes the precedence.
The parameter < distance-metric> in the static route configuration command ip route can
be used to change the administrative distance of a static route. Suppose that there are
two different routes from R1 to 192.168.6.0/24, which are configured as follows:
R1(config)#ip route 192.168.6.0 255.255.255.0 192.168.4.2
R1(config)#ip route 192.168.6.0 255.255.255.0 192.168.3.2 25

With the above two commands, two different static routes to the same network are
configured. The first command does not configure the administrative distance, so the
default value 1 is used. The second command sets the administrative distance to 25.
The administrative distance of the first route is less than that of the second one, the
routing table will only show information of the first route, that is, the router arrives at the
destination network 192.168.6.0/24 only through the next hop 192.168.4.2. The second
route is present in the routing table only when the first one is invalid and disappears from
the routing table.

2-3
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

2.4.2 Static Route Summary Configuration Example


The summary static route is a special kind of static route, which summaries two or more
specific route expressions into one expression to reduce the number of entries in routing
table while reserving all of the original connections. The detailed description of static route
summary is shown in Figure 2-2.
Figure 2-2 Static Route Summary

As shown in Figure 2-2, R3 has two networks: 10.1.0.0/16 and 10.2.0.0/16. For R1
accessing these networks, the following two static routes are configured on R1 in usual
cases:
R1(config)#ip route 10.1.0.0 255.255.0.0 192.168.4.2
R1(config)#ip route 10.2.0.0 255.255.0.0 192.168.4.2

Suppose that R3 has been configured normally, the above configuration can be used to
complete IP connection. However, the static route summary can be used to optimize the
routing table of R1, and the following command can be used to replace the above two
commands.
R1(config)#ip route 10.0.0.0 255.0.0.0 192.168.4.2

The above command shows that all packets to the destination network 10.0.0.0/8 pass
192.168.4.2. That is, all subnet packets (here refer to 10.1.0.0/16 and 10.2.0.0/16) with
the destination to be 10.0.0.0/8 are sent to 192.168.4.2. In this way, static route is used to
summarize all subnets of main network 10.0.0.0/8.

2-4
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 2 Static Route Configuration

2.4.3 Default Route Configuration Example


The default route is also a special static route. The default route is used when all the other
routes in the routing table fail. It gives the routing table a last destination, thus greatly
alleviating the processing burden of the router.
If a router cannot supply a route for a packet, the packet has to be dropped. The packet
is not expected to go to an unknown destination. To fully connect the router, there must
be one route connecting the router with a network.
An example is given in Figure 2-3 to describe the functions and usages of the default route.
Figure 2-3 Default Route Configuration

As shown in Figure 2-3, R2 is connected to R3 in Internet. R2 does not record all the
network addresses in Internet, so it uses the default route to directly send unknown packets
to R3 for proper processing. The configuration of default route of R2 is as follows.
R2(config)#ip route 0.0.0.0 0.0.0.0 211.211.211.2

The configuration method of default route is completely the same with that of static route
except that its network address and subnet mask are 0.0.0.0. This can be seen in routing
table of R2.
R2#show ip route
IPv4 Routing Table:
Dest

Mask

Gw

0.0.0.0

0.0.0.0

211.211.211.2

Net

Owner
static

As shown in the routing table, the default route with the next-hop address to be
211.211.211.2 is added to the routing table as the last route.
2-5
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

When being used in routing protocol configuration, default route varies with routing
protocols.
If the default route is configured on a router running with RIP, RIP will advertise the default
route 0.0.0.0/0 to its neighbors, without redistributing route in RIP domain.
As for OSPF protocol, the router running with OSPF will not advertise the default route to
its neighbors automatically. To make OSPF send the default route to OSPF domain, the
command default-information originate must be used. If it is necessary to redistribute the
default route in OSPF domain, this advertisement is implemented by Autonomous System
Border Router (ASBR) in the OSPF domain.

2-6
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 3

RIP Configuration
Table of Contents
RIP Overview .............................................................................................................3-1
Configuring RIP..........................................................................................................3-2
Configuring RIP Maintenance and Diagnosis..............................................................3-6
RIP Configuration Example ........................................................................................3-7

3.1 RIP Overview


The Routing Information Protocol (RIP) is the first routing protocol to implement dynamic
routing, based on the distance-vector algorithm of the local network. RIPv1 is documented
in RFC1058, while RIPv2 is documented in RFC2453. The ZXR10 ZSR completely
supports RIPv1 and RIPv2. RIPv2 is used by default. Compared with RIPv1, RIPv2 has
the following advantages:
l
l
l

RIPv2 supports Classless Inter-Domain Routing (CIDR) and Variable Length Subnet
Masks (VLSM).
The protocol packet can contain authentication data.
The protocol packet can be advertised in mode of multicast.

RIPv2 is introduced in the following part. Unless otherwise specified, RIP refers to RIPv2.

3.1.1 RIP Route Metric and Administrative Distance


RIP uses the UDP packet (port number 520) to exchange RIP routing information. Routing
information in a RIP packet includes the number of routers that a route passes through,
that is, the number of hops. The router determines the route to the destination network
according to hops. RFC stipulates that the maximum number of hops cannot exceed 16,
so RIP is only applicable to a small-size network. The hop value being 16 indicates the
route is unreachable. Thats also how RIP identifies and prevents loop.
RIP only uses the number of hops as the metric, and does not consider the bandwidth,
delay or other variable factors during routing. RIP always takes the path with the minimum
number of hops as the optimal path. While sometimes the path selected in this way is not
actually the best one.
The Administrative Distance (AD) of RIP is 120 by default. The lower the AD value, the
higher reliability the routing source. Comparing RIP with other routing protocols, RIP is not
reliable.

3-1
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

3.1.2 RIP Timers


The RIP router sends a route update packet periodically (30 seconds by default). The
route update packet includes all routing information of this router. The update process is
called routing information advertisement.
If router A fails to receive update packet from router B within a time period (180 seconds
by default), it will mark the route from router B as invalid.
If update packet still fails to be received within the subsequent period of time (240 seconds),
router A will delete this route from the routing table.
RIP provides four timers:
l
l
l
l

Update timer
Invalid timer
Holddown timer
Flush timer

3.1.3 RIP Route Update


RIP uses triggered update to accelerate the dispersion of routing changes in RIP route
domain. When an RIP router detects that an interface is being or has been disabled,
a neighboring node collapses, or a new subnet/neighboring node joins in, it will send a
triggered update. The triggered update packet only contains data of changed routes.
RIP uses poison reverse to accelerate convergence of protocol. The poison reverse sets
the prefix metric of the inaccessible network to 16 (indicates inaccessible). After receiving
the route update packet with this metric, the router drops this route, instead of waiting for
expiration of aging time.
RIP uses the split horizon function to prevent loops and reduce the size of route update.
The split horizon means that the update packets are not repeatedly sent to an interface
that has received a route update packet.

3.2 Configuring RIP


3.2.1 Enabling RIP
RIP configurations include basic configuration, enhanced configuration and version
configuration.
To configure RIP, perform the following steps.
Step

Format

Function

ZXR10(config)#router rip

Enable RIP routing process and


enter route configuration mode

3-2
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 3 RIP Configuration

Step

Format

Function

ZXR10(config-router)#network < ip-address> < net-mask>

Specify the interface where RIP is


enabled; in case the IP address
of the interface belongs to the
designated network segment, RIP is
enabled on this interface.

3.2.2 Adjusting RIP Timer


To adjust RIP timer, execute the following commands:
Step

Format

Function

ZXR10(config)# router rip

Enable RIP routing process and


enter route configuration mode.

ZXR10(config-router)#timers basic < update> < invalid> <

Adjust RIP network timer.

holddown> < flush>


3

ZXR10(config-router)#utput-delay < packets> < delay>

Change the delay of sending RIP


update packet.

Parameter description to the command in step 2 is as follows:


Parameter

Description

< update>

It is the rate of sending update packets (in seconds), in range of 1-65535 with 30
seconds to be the default value. It is a basic parameter of routing protocol.

< invalid>

It is the period (in seconds) before a route is declared to be invalid, in range of 1-65535
with 180 seconds to be the default value. This parameter is suggested to be at least
3 times larger than parameter update. Once a route is received, in case there is no
route update before the invalid period expires, the route is invalid. Now, the route is
in holddown state. If the parameter holddown is set to 0, flush timer is enabled directly.

< holddown>

It is the period (in seconds) of holding down route update, in range of 0-65535 with
180 seconds to be the default value. This parameter is suggested to be at least
3 times larger than parameter update. When the router receives the update packet
but learns that the route is unreachable, or when invalid timer expires, the route will
be invalid and enter the holddown state. The route will be marked as inaccessible in
the routing table and advertised as unreachable, but it can still be used to forward
packets. After the holddown period, router can receive the routes advertised by other
sources, and the route can be accessed again.

< flush>

It is the period (in seconds) started from a route entry getting invalid to this route being
cleared, in range of 1-65535 with 240 seconds to be the default value. The specified
time mustnt be less than the holddown time. Otherwise, the holddown period will be
improper, which causes that new routes will be received before the holddown time
expires.
3-3

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Parameter description to the command in step 3 is as follows:


Parameter

Description

< packets>

It is the number of packets, in range of 1-4294967295.

< delay>

The delay of sending multiple RIP update packets (in milliseconds), in range of 0-100.

3.2.3 Configuring RIP Neighbor


To configure RIP neighbor, perform the following steps.
Step

Format

Function

ZXR10(config)#router rip

Enable RIP routing process and


enter route configuration mode.

ZXR10(config-router)#neighbor < ip-address>

Specify the neighboring router


exchanging route information with
the local router.

3.2.4 Configuring RIP Authentication


RIPv2 supports simple password authentication and MD5 authentication. Neighbors
in a network must set the same password for interfaces. RIPv1 does not support
authentication.
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip rip authentication key < key>

It designates a key that is used for


simple text authentication on an
interface (The key length ranges
from 1 to 16 characters).

ZXR10(config-if)#ip rip authentication mode { text | md5}

It designates the authentication type


for RIP packets.

3.2.5 Configuring Split Horizon and Poison Reverse


To configure split horizon and poison reverse, perform the following steps.
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip split-horizon

Enable split horizon mechanism.

ZXR10(config-if)#ip poison-reverse

Enable poison reverse mechanism.


3-4

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 3 RIP Configuration

3.2.6 Configuring Route Redistribution


To configure route redistribution, performing the following steps:
Step

Format

Function

ZXR10(config)#router rip

Enable RIP routing process and


enter route configuration mode.

ZXR10(config-router)#redistribute < protocol> [ metric <

Redistribute a route from one route

metric-value> ] [ route-map < map-tag> ]

domain to the RIP route domain.

ZXR10(config-router)#default-metric < metric-value>

It specifies the default metric used


for redistributing a route of another
protocol to RIP route (The metric
ranges from 1 to 16 with the default
value to be 1).

3.2.7 Configuring RIP Interface Mode


To configure RIP interface mode, perform the following steps:
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip rip interface { active | passive}

As for active, interface can both


receive and send RIP packets; as for
passive, interface can only receive
RIP packets but cannot send RIP
packets.

3.2.8 Configuring RIP Version


ZXR10 ZSR supports RIPv1 and RIPv2. RIPv2 is used by default. Designate the RIP
version received or sent by the router with the following commands.
Step

Format

Function

ZXR10(config)#router rip

Enable RIP routing process and


enter route configuration mode.

ZXR10(config-router)#version { 1 | 2}

Specify the global RIP version for


router.

ZXR10(config-router)#exit

Exit from route configuration mode.

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip rip receive version { 1 | 2} [ 1 | 2]

Specify the RIP version received on


interface.

3-5
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Step

Format

Function

ZXR10(config-if)#ip rip send version { 1 | 2 { broadcast | multicast} }

Designate the RIP version sent by


the interface.

3.3 Configuring RIP Maintenance and Diagnosis


To perform RIP maintenance and diagnosis, use the following show commands (in all
modes).
Format

Function

ZXR10#show ip rip [ vrf < vrf-name> ]

It displays basic RIP running


information.

ZXR10#show ip rip interface [ vrf < vrf-name> ] < interface-name>

It displays current configuration and


status of a RIP interface.

ZXR10#show ip rip database [ vrf < vrf-name> ] [ network < ip-address> [

It displays RIP route entries.

mask < net-mask> ] ]


ZXR10#show ip rip networks [ vrf < vrf-name> ]

It displays all RIP interface information


configured by the user.

ZXR10 ZSR also provides debug commands to debug RIP and trace relevant information,
use the following commands.
Format

Function

ZXR10#debug ip rip

It traces packet receiving and sending


of RIP protocol.

ZXR10#debug ip rip all

It enables all RIP debugging functions.

ZXR10#debug ip rip database

It traces changing process of RIP


routing table.

ZXR10#debug ip rip events

It traces RIP-related events.

ZXR10#debug ip rip trigger

It traces RIP-triggered events.

Example
This example describes the output information of debug ip rip command.
ZXR10#debug ip rip
RIP protocol debugging is on
ZXR10#
11:01:28: RIP: building update entries
130.1.0.0/16 via 0.0.0.0, metric 1, tag 0
130.1.1.0/24 via 0.0.0.0, metric 1, tag 0
177.0.0.0/9 via 0.0.0.0, metric 1, tag 0

3-6
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 3 RIP Configuration


193.1.168.0/24 via 0.0.0.0, metric 1, tag 0
197.1.0.0/16 via 0.0.0.0, metric 1, tag 0
199.2.0.0/16 via 0.0.0.0, metric 1, tag 0
202.119.8.0/24 via 0.0.0.0, metric 1, tag 0
11:01:28: RIP: sending v2 periodic update to 224.0.0.9 via
pos3_3/1 (193.1.1.111)
130.1.0.0/16 via 0.0.0.0, metric 1, tag 0
130.1.1.0/24 via 0.0.0.0, metric 1, tag 0
177.0.0.0/9 via 0.0.0.0, metric 1, tag 0
193.1.1.0/24 via 0.0.0.0, metric 1, tag 0
11:01:28: RIP: sending v2 periodic update to 193.1.168.95 via
fei_1/1 (193.1.168.111)
11:01:28: RIP: sending v2 periodic update to 193.1.168.86 via
fei_1/1 (193.1.168.111)
11:01:28: RIP: sending v2 periodic update to 193.1.168.77 via
fei_1/1 (193.1.168.111)
11:01:28: RIP: sending v2 periodic update to 193.1.168.68 via
fei_1/1 (193.1.168.111)

3.4 RIP Configuration Example


As shown in Figure 3-1, enable RIP on R1 and R2.
Figure 3-1 RIP Configuration Example

Configuration of R1:
ZXR10_R1(config)#router rip
ZXR10_R1(config-router)#network 10.1.0.0 0.0.255.255
ZXR10_R1(config-router)#network 192.168.1.0 0.0.0.255

Configuration of R2:
ZXR10_R2(config)#router rip
ZXR10_R2(config-router)#network 10.2.0.0 0.0.255.255
ZXR10_R2(config-router)#network 192.168.1.0 0.0.0.255

3-7
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

This page intentionally left blank.

3-8
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4

OSPF Configuration
Table of Contents
OSPF Overview .........................................................................................................4-1
Configuring OSPF ......................................................................................................4-7
Configuring OSPF Maintenance and Diagnosis ........................................................4-14
OSPF Configuration Example...................................................................................4-16

4.1 OSPF Overview


Open Shortest Path First (OSPF) is one of the most popular and widely used routing
protocols. OSPF is a link state protocol which has overcome the disadvantages of
Routing Information Protocol (RIP) and other distance vector protocols. OSPF is an open
criteria and equipment from multiple manufacturers and running different protocols can
communicate with each other.
OSPFv1 is defined in RFC1131. OSPFv2, defined in RFC2328, is used at present. ZXR10
ZSR completely supports OSPFv2.
OSPF has the following features:
l

Fast Convergence
It guarantees database synchronization by means of fast flooding of link state update
packets, and calculates the routing table simultaneously.

No loop
Shortest Path First (SPF) algorithm is used to ensure that no loop is generated.

Route aggregation
It reduces the size of routing table

Classless routing completely


It supports Variable Length Subnet Mask (VLSM) and Classless Inter-Domain Routing
(CIDR).

Reduction of network bandwidth


Since triggered update mechanism is adopted, the update packets are sent only when
network structure changes.

l
l

It supports interface packet authentication to guarantee the security of route


calculation.
Sending update packets in mode of multicast
4-1

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

It eliminates interferences upon unrelated network devices while broadcasting


packets.

4.1.1 OSPF Algorithm


As OSPF is a link state protocol, the OSPF router generates the routing table by setting
up an LSDB, which contains the data of all networks and routers. Routers use these data
to set up routing tables. To ensure reliability, all routers must have the completely same
LSDB.
The LSDB is set up according to Link State Advertisements (LSA), which are generated
by each router and spread all over the OSPF network. There are many types of LSAs; a
complete LSA set shows an accurate distribution diagram of the whole network.
OSPF uses cost as the metric. The cost is assigned to each port of a router. The cost of
a port is calculated automatically based on 100M by default. The path cost to a particular
destination is the total cost of all links between this router and the destination.
To generate a routing table based on the LSA database, a router run Dijkstra SPF algorithm
to construct a cost routing tree, with itself as the root of the routing tree. The Dijkstra
algorithm enables the router to calculate the lowest-cost path between itself and any other
nodes in the network and the router saves the routes of these paths into the routing table.
Different from RIP, OSPF does not simply broadcast all its routing information regularly.
An OSPF router sends hello packets to its neighbors to let them know that it is still alive. If
a router does not receive any packets from a neighbor within a certain period, it indicates
the neighbor is down.
OSPF router only sends the update packets when the topology structure changes. When
the aging time of an LSA reaches 1800 seconds, a new version of this LSA is resent.

4.1.2 OSPF Network Types


The type of the network connected to an interface is used to judge the default behavior
of OSPF. The network type affects the adjacency relationship and how does a router
designate a timer to the interface.
There are five network types for OSPF as follows:
l
l
l
l
l

Broadcast network
Non-broadcast Multi-access (NBMA) network
Point-to-Point network
Point-to-Multipoint network
Virtual links

4.1.3 Hello Packet and Timers


An OSPF router exchanges Hello packets with its neighbors at an certain interval to
keep alive status among neighbors. Hello Packet can detect OSPF neighbors, establish
association and adjacency among neighbors, and select a DR.
4-2
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration

In broadcast, point-to-point, and point-to-multipoint networks, Hello packet is multicasted;


in NBMA and virtual links, Hello packet is unicasted to neighbor routers.
OSPF uses three types of timers related to the Hello packet:
l

Hello interval
The Hello interval is an attribute of the interface, defining the interval for a router to
send Hello packets from each of its interface. The default hello interval depends on
the network type.
In the broadcast network and point-to-point network, the default hello interval is 10
seconds; in the NBMA network and point-to-multipoint network, it is 30 seconds.
The neighboring routers must agree on the hello interval to enable them to become
neighbors.

Router dead interval


It is the time from a router receiving the last hello packet from its neighbor to it detecting
that its neighbor is disconnected. The default router dead interval is four times as long
as hello interval, which applies to all network types.

Polling Interval
It is only used in NBMA network.

4.1.4 OSPF Neighbors


OSPF neighbors are a group of routers in the same network, with some of the same
configuration parameters. To form adjacency, routers must be neighbors.
They must analyze the Hello packets from each other firstly to make sure the required
parameters are agreed on. These parameters include area ID, area flag, authentication
information, Hello Interval, and Router Dead Interval.

4.1.5 Adjacency and Designated Router


After adjacency is established between two routers, they can exchange routing information.
Whether adjacency can be established between two routers depends on the type of the
network where routers are interconnected.
There are only two routers for point-to-point network and virtual links, therefore, adjacency
is established automatically between routers. The point-to-multipoint network can be
regarded as a set of point-to-point networks, so adjacency is established between each
pair of routers.
In broadcast and NBMA networks, adjacency is not established between neighbors. In
case adjacency is established for all routers in a network, each router has (n-1) adjacencies
and there are n (n-1)/2 adjacencies in the network.
In a large multi-access network, if each router traces so many adjacencies, the router will
bear too much burden, and furthermore, the routing information transmitted between each
pair of adjacent routers will consume a lot network bandwidth.
4-3
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Therefore, OSPF defines a Designated Router (DR) and a Backup Designated Router
(BDR). Adjacency must be established between DR/BDR and each OSPF router in the
network, and each OSPF router only establishes adjacency with DR/BDR.If DR is down,
BDR will become the DR.

4.1.6 Router Priority and DR Election


Each router interface has a priority, which determines if it can be elected as the DR or BDR
in this network. Router priority is an 8-bit unsigned integer, ranging from 0 to 255 (default
value is 1).
Upon DR election, the router with the highest priority will become DR. If two routers have
the same priority, the one with the highest IP address will become the DR. The router with
priority "0" cannot be DR or BDR.

4.1.7 OSPF Area


A network is divided into several smaller OSPF areas to reduce the data stored and
maintained by each router. Each router must have the complete information of area
where it is located. Areas share each others information, and the routing information can
be filtered on area edge router to reduce the routing information stored in routers.
Each area is identified by a 32-bit unsigned number. Area 0 is reserved to identify the
backbone area and other areas must be directly connected to area 0. An OSPF network
must have one backbone area. According to specific task in area where a router is located,
the router can be of one or multiple of the following types, as shown in Figure 4-1.
Figure 4-1 OSPF Router Type

Internal router
4-4

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration

The interfaces of a router are in one area.


l

Backbone router
At least one interface of the router is in area 0.

Area Border Router (ABR)


At least one interface of the router is in area 0 and at least one interface is in another
area

Autonomous System Border Router (ASBR)


The router connects one AS running OSPF with another AS running other protocols
(such as RIP or IGRP).

4.1.8 LSA Type and Flooding


OSPF routers use LSAs to exchange information among LSDBs, compose an accurate
and complete network diagram, and then generate routes for routing table. ZXR10 ZSR
supports six types of LSAs, as shown below:
Type

LSA Name

Description

Router LSA

Router LSA is the basic type of LSA, all OSPF routers can generate this type of

No.
Type 1

LSA. It is mainly used to describe the connection status and cost of an interface
where OSPF is enabled. ABR generates one Router LSA for each area. This
type of LSA is transmitted within the entire areas it belongs to.
Type 2

Network LSA

Network LSA is generated by DR. It is used to describe broadcast network and


NBMA network. Once DR is elected in a network segment, not only the mode
of sending packets but also the description to link state changes. Router LSA
of DR and BDR only contains the information of connection to DR, and DR
uses Network LSA to describe all adjacent routers in local network segment
(list their Router ID). This type of LSA is also transmitted within the entire areas
it belongs to.

Type 3

Network Summary

Network Summary LSA is generated by ABR. After calculating intra-area routes

LSA

of an area that ABR belongs to, ABR searches routing table and encapsulates
each OSPF route in this area to a Network Summary LSA and send it out.
Network Summary LSA introduces the destination, mask, cost and other
information of a route. It can be distributed to all areas of ABR except for the
area where this LSA is generated.

Type 4

ASBR Summary LSA

ASBR Summary LSA is generated by ABR. It is mainly used to describe


routes pointing to ASBR of this area. The content of ASBR Summary LSA
and Network Summary LSA are basically the same except that the destination
contained in ASBR Summary LSA is ASBR and the route is host route, so the
mask is 0.0.0.0. This type of LSA is distributed in the same range with that of
Network Summary LSA.

4-5
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Type

LSA Name

Description

AS External LSA

This type of LSA is used in NSSA. AS External LSA is generated by ASBR. It is

No.
Type 5

mainly used to describe the route pointing to an address outside of the AS. This
type of LSA is the only type that is not related to area. This type of LSA can be
distributed over the whole AS (except STUB area).
Type 7

NSSA External LSA

This type of LSA is used in NSSA.

The operation of OSPF depends on all routers sharing the same public LSDB in one area.
Therefore, all LSAs need to be flooded through this area and the processing must be
reliable. Each router will flood the LSAs that it receives from a particular area to the other
interfaces in this area.
LSAs do not have their own packets. They are included in Link State Update (LSU) packets
and it is ok to include multiple LSAs in one LSU.
When a router receives an LSU packet, instead of forwarding it directly, the router extracts
LSAs from the packet and delivers them into its database. In addition, the router generates
its own LSU and forwards the modified LSU to its neighbors.
OSPF sends Link State Acknowledgements (LSAck) to verify if each LSA is received
by neighbors. An LSAck contains the head of verified LSA , which provides sufficient
information to identify an LSA uniquely.
When a router sends an LSA to an interface, the LSA is recorded in the
retransmission-queue of the interface. The router will wait for the maximum interval to
receive the LSAck of this LSA. If router fails to receive the LSAck within the preset time, it
will resend this LSA.
A router can send the original LSU in mode of unicast or multicast, but as for the
re-transmitted LSU, only unicast mode is available.

4.1.9 Stub Area and Totally Stub Area


When there is no ASBR in a non-backbone area, the router has only one path to the outside
of the AS: through the ABR. Therefore, routers in this area will send the LSAs destined to
an unknown host outside the AS to the ABR.
Now type 5 LSA needs not to be flooded to this area and neither type 4 LSA can be found
in the area. Such an areas type is called stub area.
In a stub area, all routers must be configured as stub routers. The Hello packet contains
a stub area flag bit, which must be consistent among neighbors.
The ABR in a stub area can filter type 5 LSAs to prevent them from being distributed to
the stub area. Meanwhile ABR will generate a type 3 LSA to advertise a default route to a
destination addresses outside the AS.
If ABR also filters type 3 LSAs and advertises a default route to a destination address
outside the area, this kind of area is called totally stubby area.
4-6
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration

4.1.10 Not-So-Stubby Area


Routers in a stub area refuse type 5 LSAs, so ASBR is not a part of stub area. However,
to create a stub area with ASBR, where routers in this area receive AS external routes
from the ASBR of this area but external routing information from other areas is blocked,
OSPF defines the Not-So-Stubby Area (NSSA). In an NSSA, the ASBR generates type 7
LSAs instead of type 5 LSAs. The ABR cannot forward type 7 LSAs to other OSPF areas.
It blocks external routes to enter NSSA area; on the other hand, it converts type 7 LSAs
into type 5 ones.

4.1.11 OSPF Authentication


The authentication applies to packet exchanging between OSPF neighbors. Neighbors
must agree on the authentication mode, which is included in all packets.
Authentication mode 0 indicates no authentication, 1 indicates simple password
authentication, and 2 indicates MD5 password authentication.
When simple password authentication is configured, one interface can have only one
password and each interface can have a different password, but all interfaces in a
particular network must have the same password. The simple password is transmitted
through OSPF packet in a plain text.

4.2 Configuring OSPF


4.2.1 Enabling OSPF
To enable OSPF, perform the following steps.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

This enables OSPF routing process


and enters into route configuration
mode

ZXR10(config-router)#network < ip-address> < wildcard-mask>

This defines OSPF interfaces and

area < area-id>

area IDs for these interfaces

Parameter description of command in step 1 is described as follows:


Parameter

Description

< process-id>

OSPF process id, in range of 1-65535

< vrf-name>

VRF name, with the length to be 1-16 characters

4-7
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

4.2.2 Configuring OSPF Interface Timer


OSPF characteristics can be customized to adapt to any network environment. Although
in most cases it doesnt need to modify the default value of timer, regulating timer can
improve protocol performance in some cases.
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter into interface configuration


mode.

ZXR10(config-if)#ip ospf hello-interval < seconds>

Interval for the interface sending


Hello packets (in seconds, in range
of 1-65535, 1/4 dead-interval by
default, that is 10 seconds).

ZXR10(config-if)#ip ospf retransmit-interval < seconds>

Interval for the interface


retransmitting LSAs (in seconds,
in range of 1-65535, 5 seconds by
default).

ZXR10(config-if)#ip ospf transmit-delay < seconds>

Specify the delay of transmitting


a link state update packet on the
interface (in seconds, in range of
1-65535, 1 second by default).

ZXR10(config-if)#ip ospf dead-interval < seconds>

Specify the dead-interval of neighbor


on the interface (in seconds, in range
of 1-65535, 4 times of dead-interval
by default, that is 40 seconds).

4.2.3 Configuring OSPF Interface Cost


To configure OSPF interface cost, execute the following commands:
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip ospf cost < cost>

Configure interface cost (in range of


1-65535, 1 by default).

Tip:
When network devices from different manufacturers are used together, make sure these
OSPF devices are compatible with each other. For example, all routers must use the same
algorithm to calculate interface cost.

4-8
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration

4.2.4 Configuring OSPF Interface Priority


To configure OSPF interface priority, use the following commands.
Step

Command

Function

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip ospf priority < priority>

Configure interface priority (range of


0-255, 1 by default).

4.2.5 Configuring OSPF Neighbor Router


To manually configure neighboring routers in a non-broadcast network, use the following
commands.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

Enable OSPF routing process and


enter route configuration mode.

ZXR10(config-router)#neighbor < ip-address> [ cost < cost> ] [

Configure neighboring routers in a

priority < priority> ] [ poll-interval < seconds> ]

non-broadcast network.

It needs to traverse all interfaces. When a neighbors IP address is in the same network
segment with interface IP address, connect the neighbor to this interface.

4.2.6 Configuring OSPF Area


OSPF area is used to implement hierarchical routing. OSPF areas are divided into stub
area, totally stubby area, and not-so-stubby area. The backbone area is a transitional
area. To configure an OSPF area, perform the following steps.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

Enable OSPF routing process and


enter route configuration mode.

ZXR10(config-router)#area < area-id> stub [ no-summary] [

Define an area to be stub area or

default-cost < cost> ]

totally stub area.

ZXR10(config-router)#area < area-id> nssa [ no-redistribution] [

Define an area to be not-so-stubby

default-information-originate [ metric < metric-value> ] [ metric-type

area.

< type> ] ] [ no-summary]

Parameter description to the command in step 3 is as follows:


Parameter

Description

< area-id>

It's the area id, an IP address expressed in decimal (04294967295)


or dotted decimal notation.
4-9

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Parameter

Description

< metric-value>

It's the metric value of type 7 LSA of default route, expressed in


24bit number, in range of 0-16777214.

< type>

It's the type of type 7 LSA of default route. Two types are available:
ext-1 and ext-2.

4.2.7 Configuring OSPF Inter-Area Route Aggregation


Route aggregation is among the features that make OSPF popular. Route aggregation
can either be inter-area or inter-AS. Inter-area route aggregation is implemented on ABR,
while inter-AS route aggregation is implemented on ASBR.
Configuring a stub area can save router resources in the stub area, but it does not help
the backbone area. If network addresses in an area are allocated in sequence, user can
configure the ABR to advertise an aggregated route to replace these sequential routes.
Route aggregation can save resources of backbone area by advertising a summary
address for a group of network addresses. To configure the range of intra-area summary
address, execute the following commands.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

Enable OSPF routing process and


enter route configuration mode.

ZXR10(config-router)#area < area-id> range < ip-address> <

Configure the range of intra-area

net-mask> [ advertise | not-advertise]

summary address.

4.2.8 Configuring OSPF Default Route Notification


To configure an ASBR to advertise a default route over the entire OSPF domain, use the
following commands.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

Enable OSPF routing process and


enter route configuration mode.

ZXR10(config-router)#notify default route [ always] [ metric <

Configure an ASBR to advertise a

metric-value> ] [ metric-type < type> ] [ route-map < map-tag> ]

default route over the entire OSPF


domain.

Parameter description to the command in step 2 is as follows:


Parameter

Description

< metric-value>

Define the metric value of default route, in range of 0-16777214, 1


by default.
4-10

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration

Parameter

Description

< type>

Define the type of default route. Two types are available: ext-1
and ext-2, ext-2 by default.

< map-tag>

Define the route map name for this default route, with the length to
be 1-16 characters.

When route redistribution is configured on a router, it becomes an ASBR. ASBR does not
automatically advertise the default route over the whole OSPF area by default. When
executing corresponding command to configure a router to advertise a default route, this
router becomes an ASBR automatically.

4.2.9 Configuring OSPF Virtual Links


All areas in an OSPF network must be directly connected to the backbone area, which will
set a limit to the layout of areas, especially when the network is very large.
To solve this problem, a virtual link can be used to connect a remote area to the backbone
area through another area. The area that the virtual link crosses must have complete
routing information, so it cannot be a stub area.
To define an OSPF virtual link, execute the following commands.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

Enable OSPF routing process and


enter route configuration mode.

ZXR10(config-router)#area < area-id> virtual-link < router-id>

Define OSPF virtual link.

[ hello-interval < seconds> ] [ retransmit-interval < seconds>


] [ transmit-delay < seconds> ] [ dead-interval < seconds> ] [
authentication-key < key> ] [ message-digest-key < keyid> md5 <
cryptkey> [ delay < time> ] ] [ authentication [ null | message-digest] ]

Parameter description to the command in step 2 is as follows:


Parameter

Description

< area-id>

It is the area id, an IP address expressed in decimal (0-4294967295)


or dotted decimal notation.

< router-id>

It is the peer router ID of the virtual link, IP address expressed in


dotted decimal notation.

hello-interval < seconds>

It is the interval of sending Hello packets on the virtual link (in


seconds), in range of 1~8192, 10 seconds by default.

retransmit-interval < seconds>

It is the retransmit interval on the virtual link (in seconds), in range


of 1-8192, 5 seconds by default.

4-11
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Parameter

Description

transmit-delay < seconds>

Specify the delay of transmitting a link state update packet on the


virtual link (in seconds) in range of 1-8192, 1 second by default).

dead-interval < seconds>

It is the dead-interval of neighbor on the virtual link (in seconds),


in range of 1-8192, 40 seconds by default.

dead-delay < seconds>

It is the dead-delay of neighbor on the virtual link (in seconds), in


range of 1-8192, 40 seconds by default.

< key>

It is the authentication key on the virtual link, with the length to


be 1~8 characters.

< keyid>

It is the key id of md5 authentication on virtual link, an integer


between 0 and 255; at most 10 keyids are allowed.

< cryptkey>

It is the md5 authentication key on the virtual link, with the length to
be 1-16 characters.

< time>

It is the daly of md5 authentication getting valid (in minutes), in


range of 0~100000.

4.2.10 Configuring OSPF Route Redistribution


Different dynamic routing protocols can share routing information through route
redistribution. In OSPF, routing information of other routing protocols is the AS external
routing information. Only when the AS external routing information is redistributed to
OSPF, can LSAs of OSPF be flooded to the whole OSPF network.
To control the redistribution of routes of other routing protocols to OSPF AS, execute the
following commands. The router becomes an ASBR when the command is executed.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

Enable OSPF routing process and


enter route configuration mode.

ZXR10(config-router)#redistribute < protocol> [ as < as-number> ]

Control the redistribution of

[ peer < peer-address> ] [ tag < tag-value> ] [ metric < metric-value> ]

other protocol routes meeting

[ metric-type < type> ] [ route-map < map-tag> ]

requirements to OSPF AS. After


executing this command, router will
become and ASBR.

Parameter description to the command in step 2 is as follows:


Parameter

Description

< protocol>

Filter routes according to protocol. The value can be connected, static, rip,
bgp-ext, bgp-int, isis-1, isis-1-2, and isis-2.

4-12
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration

Parameter

Description

< as-number>

There are two additional conditions when < protocol-value> is bgp-ext: <
as-number> and < peer-address> , where < as-number> indicates AS number of
the peer, in range of 1~65535.

< peer-address>

There are two additional conditions when < protocol-value> is bgp-ext: <
as-number> and < peer-address> , where < as-number> indicates AS number of
the peer and < peer-address> indicates IP address of the peer.

< tag-value>

Set tag of restributed LSA, in range of 0-4294967295.

< metric-value>

Set the metric value of redistributed LSA. The default metric of system is used
by default, in range of 0-16777214.

< type>

Set metric-type of LSA after redistribution. Two values are available: ext-1
and ext-2, ext-2 by default.

< map-tag>

Set the name of route map for redistribution, with the length to be 1-16
characters.

4.2.11 Configuring OSPF Authentication


To improve the security of routing processes in network, configure OSPF authentication
on routers. Neighbors in a network must set the same password for interfaces.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

Enable OSPF routing process and


enter route configuration mode.

ZXR10(config-router)#area < area-id> authentication [

Enable authentication in OSPF area.

message-digest]
3

ZXR10(config-router)#exit

Exit from route configuration mode.

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip ospf authentication [ null | message-digest]

Configure authentication mode.

ZXR10(config-if)#ip ospf authentication-key < password>

Set a password for the interface with


simple password authentication.

ZXR10(config-if)#ip ospf message-digest-key < key id> md5 <

Set authentication password for

password> [ encrypt] [ delay < time> ]

encryption.

4.2.12 Configuring Routes to Support Opaque LSA


In process of exchanging LSDB, opaque LSAs are contained in database summary list
and sent to the neighboring routers which also support opaque LSA.
When one router floods opaque LSAs to its neighboring router, it firstly verifies if the
neighboring router supports opaque LSA. Opaque LSAs are only sent to the neighboring
4-13
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

routers that support this function and they are added to link state retransmit lists of the
neighboring routers. When link state update packet are multicasted, the neighboring
router that doesnt support this function will receive this advertisement passively an drop
it simply.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

Enable OSPF routing process and


enter route configuration mode.

Configure to support opaque LSA.

ZXR10(config-router)#capability opaque

4.2.13 Modifying OSPF Administrative Distance


Administrative distance is related to the reliability of the source of routing information.
administrative distance is an integer between 0 and 255; higher value indicates lower
reliability. If the administrative distance is 255, the source of routing information is
unreliable, and all related routes will be ignored.
To specify route type-based OSPF route administrative distance, execute the following
commands.
Step

Format

Function

ZXR10(config)#router ospf < process-id> [ vrf < vrf-name> ]

Enable OSPF routing process and


enter route configuration mode.

ZXR10(config-router)#distance ospf { [ internal < distance> ] [

This specifies route type-based

ext1 < distance> ] [ ext2 < distance> ] }

OSPF route administrative distance


(in range of 1-255, 110 by default).

Note:
As for ZXR10 ZSR, defines administrative distances of three types of OSPF routes: internal
route, external 1 route and external 2 route. By default, administrative distance of these
three types of routes are 110 .

4.3 Configuring OSPF Maintenance and Diagnosis


To perform OSPF maintenance and diagnosis, use the following commands.
Format

Function

ZXR10#show ip ospf [ < process-id> ]

View OSPF process details.

ZXR10#show ip ospf interface [ < interface-name> ] [ process < process-id> ]

View current configuration and status of


an OSPF interface.

4-14
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration

Format

Function

ZXR10#show ip ospf neighbor [ interface < interface-name> ] [ neighbor-id

Check the information of OSPF

< neighbor> ] [ process < process-id> ]

neighbors.

ZXR10#show ip ospf database [ database-summary | adv-router < router-id>

| self-originate] [ area < area-id> ] [ process < process-id> ]


ZXR10#show ip ospf database router [ < link-state-id> ] [ adv-router <

router-id> | self-originate] [ area < area-id> ] [ process < process-id> ]


ZXR10#show ip ospf database network [ < link-state-id> ] [ adv-router <

router-id> | self-originate] [ area < area-id> ] [ process < process-id> ]


ZXR10#show ip ospf database summary [ < link-state-id> ] [ adv-router <

router-id> | self-originate] [ area < area-id> ] [ process < process-id> ]

Show all or partial information of an

ZXR10#show ip ospf database asbr-summary [ < link-state-id> ] [ adv-router

LSDB.

< router-id> | self-originate] [ area < area-id> ] [ process < process-id> ]


ZXR10#show ip ospf database nssa [ < link-state-id> ] [ adv-router <

router-id> | self-originate] [ area < area-id> ] [ process < process-id> ]


ZXR10#show ip ospf database external [ < link-state-id> ] [ adv-router <

router-id> | self-originate] [ process < process-id> ]


ZXR10#show ip ospf database opaque-area [ < link-state-id> ] [ adv-router <

router-id> | self-originate] [ area < area-id> ] [ process < process-id> ]

Tip:
If two routers cannot communicate with each other, it is because the adjacency between
them is not established. Check if the state of neighborhood between the two OSPF routers
is FULL; FULL indicates that OSPF runs properly between the two routers.
LSDB is the source of all OSPF routes in IP routing table. Routing problems are caused
by incorrect data or data loss in LSDB.

ZXR10 ZSR also provides debug commands to debug OSPF and trace relevant
information. For example:
Format

Function

ZXR10#debug ip ospf adj

Enable the function of returning the debugging information


of OSPF adjacency events.

ZXR10#debug ip ospf packet

Enable the function of returning the debugging information


of OSPF packet sending/receiving event to monitor the
sending/receiving of all OSPF packets.

4-15
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Format

Function

ZXR10#debug ip ospf lsa-generation

Enable the function of returning the debugging information


of OSPF LSA generation events.

ZXR10#debug ip ospf events

Enable the function of returning the debugging information


of important OSPF events.

4.4 OSPF Configuration Example


4.4.1 Basic OSPF Configuration Example
As shown in Figure 4-2, OSPF is enabled on routers R1 and R2 and the network is divided
into three areas.
Figure 4-2 Basic OSPF Configuration

Configuration of R1:
ZXR10_R1(config)#router ospf 1
ZXR10_R1(config-router)#network 192.168.2.0 0.0.0.255 area 23
ZXR10_R1(config-router)#network 192.168.1.0 0.0.0.255 area 0

Configuration of R2:
ZXR10_R2(config)#router ospf 1
ZXR10_R2(config-router)#network 192.168.3.0 0.0.0.255 area 24
ZXR10_R2(config-router)#network 192.168.1.0 0.0.0.255 area 0

4.4.2 Multi-Area OSPF Configuration Example


When a network expands to a certain scale, it must be divided into multiple OSPF areas.
Figure 4-3 shows an instance of multiple-area OSPF configuration.

4-16
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration

Figure 4-3 Multi-Area OSPF Configuration

The configuration details of all routers are as follows:


Area 1 is a NSSA and R1 is the ABR between area 1 and backbone area. R1 advertises
a default route in the local area.
Configuration of R1:
ZXR10_R1(config)#interface fei_1/1
ZXR10_R1(config-if)#ip address 10.0.1.1 255.255.255.252
ZXR10_R1(config-if)#exit
ZXR10_R1(config)#interface fei_1/2
ZXR10_R1(config-if)#ip address 10.0.1.1 255.255.255.0
ZXR10_R1(config-if)#exit
ZXR10_R1(config)#router ospf 1
ZXR10_R1(config-router)#network 10.0.0.0 0.0.0.255 area 0
ZXR10_R1(config-router)#network 10.0.1.0 0.0.0.3 area 1
ZXR10_R1(config-router)#area 1 nssa default-information-originate

Area 2 is a stub area and R2 is the ABR between area 2 and backbone area. In the stub
area, ABR will advertise a default route automatically.
Configuration of R2:
ZXR10_R2(config)#interface fei_1/1
ZXR10_R2(config-if)#ip address 10.0.2.1 255.255.255.252
ZXR10_R2(config-if)#exit
ZXR10_R2(config)#interface fei_1/2

4-17
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


ZXR10_R2(config-if)#ip address 10.0.0.2 255.255.255.0
ZXR10_R2(config-if)#exit
ZXR10_R2(config)#router ospf 1
ZXR10_R2(config-router)#network 10.0.0.0 0.0.0.255 area 0
ZXR10_R2(config-router)#network 10.0.2.0 0.0.0.3 area 2
ZXR10_R2(config-router)#area 2 stub

R3 works in the backbone area 0 and is connected to other ASs through BGP. User can
manually configure R3, egress router of the whole AS, to advertise a default route to the
entire OSPF area.
Configuration of R3:
ZXR10_R3(config)#interface fei_1/1
ZXR10_R3(config-if)#ip address 10.0.0.3 255.255.255.0
ZXR10_R3(config-if)#exit
ZXR10_R3(config)#interface fei_1/2
ZXR10_R3(config-if)#ip address 192.168.0.1 255.255.255.0
ZXR10_R3(config-if)#exit
ZXR10_R3(config)#router ospf 1
ZXR10_R3(config-router)#network 10.0.0.0 0.0.0.255 area 0
ZXR10_R3(config-router)#notify default route always

R4 is the ASBR in area 1. Both OSPF and RIP are enabled on R4, and RIP routes can be
redistributed to OSPF.
Configuration of R4:
ZXR10_R4(config)#interface fei_1/1
ZXR10_R4(config-if)#ip address 192.168.1.1 255.255.255.0
ZXR10_R4(config-if)#exit
ZXR10_R4(config)#interface fei_1/2
ZXR10_R4(config-if)#ip address 10.0.1.2 255.255.255.252
ZXR10_R4(config-if)#exit
ZXR10_R4(config)#router ospf 1
ZXR10_R4(config-router)#network 10.0.1.0 0.0.0.3 area 1
ZXR10_R4(config-router)#area 1 nssa
ZXR10_R4(config-router)#redistribute rip metric 10

R5 works in stub area 2.


Configuration of R5:
ZXR10_R5(config)#interface fei_1/1
ZXR10_R5(config-if)#ip address 10.0.2.2 255.255.255.252
ZXR10_R5(config-if)#exit
ZXR10_R5(config)#router ospf 1
ZXR10_R5(config-router)#network 10.0.2.0 0.0.0.3 area 2

4-18
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration


ZXR10_R5(config-router)#area 2 stub

4.4.3 OSPF Virtual Link Configuration Example


Figure 4-4 shows an instance of OSPF virtual link configuration.
Figure 4-4 OSPF Virtual Link Configuration

The configuration details of all routers are as follows:


Configuration of R1:
ZXR10_R1(config)#interface fei_1/1
ZXR10_R1(config-if)#ip address 10.0.0.1 255.255.255.0
ZXR10_R1(config-if)#exit
ZXR10_R1(config)#router ospf 1
ZXR10_R1(config-router)#network 10.0.0.0 0.0.0.255 area 0

Configuration of R2:
ZXR10_R2(config)#interface fei_1/1
ZXR10_R2(config-if)#ip address 10.0.0.2 255.255.255.0
ZXR10_R2(config-if)#exit
ZXR10_R2(config)#interface fei_1/2
ZXR10_R2(config-if)#ip address 10.0.1.1 255.255.255.252
ZXR10_R2(config-if)#exit
ZXR10_R2(config)#router ospf 1
ZXR10_R2(config-router)#network 10.0.0.0 0.0.0.255 area 0
ZXR10_R2(config-router)#network 10.0.1.0 0.0.0.3 area 1

4-19
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


ZXR10_R2(config-router)#area 1 virtual-link 10.0.1.2

Configuration of R3:
ZXR10_R3(config)#interface fei_1/1
ZXR10_R3(config-if)#ip address 10.0.1.2 255.255.255.252
ZXR10_R3(config-if)#exit
ZXR10_R3(config)#router ospf 1
ZXR10_R3(config-router)#network 10.0.1.0 0.0.0.3 area 1
ZXR10_R3(config-router)#area 1 virtual-link 10.0.0.2

4.4.4 OSPF Authentication Configuration Example


Figure 4-5 shows an instance of OSPF authentication configuration.
Plain text
authentication is adopted in Area 0; MD5 encryption authentication is adopted in Area 1.
Figure 4-5 OSPF Authentication Configuration

The static configurations of all routers are as follows:


Configuration of R1:
ZXR10_R1(config)#interface fei_1/1
ZXR10_R1(config-if)#ip address 10.0.0.1 255.255.255.0
ZXR10_R1(config-if)#ip ospf authentication-key ZXR10
ZXR10_R1(config-if)#exit
ZXR10_R1(config)#router ospf 1
ZXR10_R1(config-router)#network 10.0.0.0 0.0.0.255 area 0
ZXR10_R1(config-router)#area 0 authentication

Configuration of R2:
4-20
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 4 OSPF Configuration


ZXR10_R2(config)#interface fei_1/1
ZXR10_R2(config-if)#ip address 10.0.0.2 255.255.255.0
ZXR10_R2(config-if)#ip ospf authentication-key ZXR10
ZXR10_R2(config-if)#exit
ZXR10_R2(config)#interface fei_1/2
ZXR10_R2(config-if)#ip address 10.0.1.1 255.255.255.252
ZXR10_R2(config-if)#ip ospf message-digest-key 1 md5 ZXR10
ZXR10_R2(config-if)#exit
ZXR10_R2(config)#router ospf 1
ZXR10_R2(config-router)#network 10.0.0.0 0.0.0.255 area 0
ZXR10_R2(config-router)#network 10.0.1.0 0.0.0.3 area 1
ZXR10_R2(config-router)#area 0 authentication
ZXR10_R2(config-router)#area 1 authentication message-digest

Configuration of R3:
ZXR10_R3(config)#interface fei_1/1
ZXR10_R3(config-if)#ip address 10.0.1.2 255.255.255.252
ZXR10_R3(config-if)#ip ospf message-digest-key 1 md5 ZXR10
ZXR10_R3(config-if)#exit
ZXR10_R3(config)#router ospf 1
ZXR10_R3(config-router)#network 10.0.1.0 0.0.0.3 area 1
ZXR10_R3(config-router)#area 1 authentication message-digest

4-21
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

This page intentionally left blank.

4-22
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 5

IS-IS Configuration
Table of Contents
IS-IS Overview ...........................................................................................................5-1
Configuring IS-IS ........................................................................................................5-3
Configuring IS-IS Maintenance and Diagnosis............................................................5-6
IS-IS Configuration Example ......................................................................................5-7

5.1 IS-IS Overview


The Intermediate System-to-Intermediate System (IS-IS) is a routing protocol introduced
by International Organization for Standardization (ISO) for Connectionless Network
Service (CLNS). Among Open Systems Interconnection (OSI) protocols, IS-IS is a
network layer protocol. By further expanding IS-IS function, IP routing is supported and
Integrated IS-IS forms.
IS-IS has been widely used in network as an Interior Gateway Protocol (IGP).It has a
similar working mechanism as OSPF: divide a network into areas, and routers in an area
only manage the routing information of the local area, so that the router cost is reduced.
This feature especially suits for medium to large networks.
As IS-IS is based on CLNS instead of IP, IS-IS uses the ISO-defined Protocol Data Units
(PDU) in communication between two routers. PDUs used in IS-IS include the following
types:
l
l
l

Hello PDU
Link State PDU (LSP)
Sequence Num PDU (SNP)

The Hello PDU is similar to Hello packet in OSPF, used to establish adjacency between
routers, discover new neighbors, and detect if any neighbor exists.
IS-IS routers exchange routing information and set up and maintain LSDB through LSPs.
An LSP contains the important data of a router, including the area and connected network.
In addition, SNPs are used to ensure reliable transmission of LSPs.
SNP contains the summary information of each LSP in the network. When a router
receives an SNP, it compares the SNP with its LSDB. If the router loses one LSP in an
SNP, it multicasts an SNP to the other routers in the network to request the LSP it needs.
Using LSP and SNP together enables IS-IS to exchange routing information reliably in a
large network.
IS-IS also uses Dijkstra SPF algorithm to calculate routes. IS-IS uses SPF algorithm to
obtain the optimal route according to LSDB and adds this route to IP routing table.
5-1
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

5.1.1 IS-IS Area


To facilitate the management of LSDB, the concept of area is introduced into IS-IS. Routers
in one area only need to maintain LSDB of the local area, which relieves the burden of
routers. This is extremely important in large networks.
IS-IS areas are divided into backbone area and non-backbone area.
l
l

Routers in the backbone area have database information of the whole network.
Routers in non-backbone areas only have the information of local area.

IS-IS defines three types of routers corresponding to different areas:


l

L1 router:
It locates in non-backbone area and only exchanges routing information with L1 and
L1/L2 routers in the local area.

L2 router:
It locates in backbone area and exchanges routing information with other L2 and L1/L2
routers.

L1/L2 router:
It locates in non-backbone area and is used to exchange routing information between
local area and backbone area.

The example of IS-IS areas is as shown in Figure 5-1.


Figure 5-1 IS-IS Area

5.1.2 IS-IS Network Types


IS-IS provides two network types: broadcast network and point-to-point network. This
makes IS-IS easy to configure and implement.

5-2
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 5 IS-IS Configuration

5.1.3 DIS and Router Priority


In a broadcast network, similar to OSPF, IS-IS also has a Designate IS (DIS). The DIS is
used to advertise network information to all routers in this broadcast network and all the
other routers only advertise an adjacency to this DIS.
Parameter priority is configured for routers for DIS election. It can also configure different
priorities for L1 and L2 routers. In DIS election, the router with the highest priority is elected
as DIS; if all routers have the same priority, as for frame relay (FR) interfaces, the router
with the highest system ID is selected as DIS; as for Ethernet interface, the router with the
largest interface MAC address is selected as DIS.

5.2 Configuring IS-IS


5.2.1 Enabling IS-IS
To enable IS-IS, perform the following steps.
Step

Format

Function

ZXR10(config)#router isis [ vrf < vrf-name> ]

Enable IS-IS routing process and


enter route configuration mode.

ZXR10(config-router)#area < area-address>

Set IS-IS area address


(hexadecimal string with 1-13
bytes).

ZXR10(config-router)#system-id < system-id> [ range <

Set IS-IS system id.

range-number> ]
4

ZXR10(config-router)#exit

Exit from route configuration mode.

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip router isis

Run IS-IS protocol on the


designated interface.

Parameter description to the command in step 3 is as follows:


Parameter

Description

< system-id>

It is the system ID of an instance, hexadecimal string with 6 bytes,


expressed in form of xxxx.xxxx.xxxx.

< range-number>

Expansion range of SystemID, in range of 0-32, 0 by default. In


instance, the ID from SystemID to SystemID+range-number will
be used.

5-3
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Tip:
In IS-IS route configuration mode, an area is required to define, and specify a router to
belong to this area. In addition, a system ID is required to define, which identifies the
router in this area. The ID is expressed by the MAC address of a routers interface.
By default, the router running with IS-IS is identified as LEVEL-1-2. To optimize the
network, command can be used to change the identification.

5.2.2 Configuring IS-IS Global Parameters


If all the routers running in the network are ZXR10 router; just use default parameters in
IS-IS configuration. However, upon interconnection with routers of other manufacturers,
the related interface parameters and timers need adjustment so that IS-IS protocol can run
more efficiently in the network.
IS-IS parameter configuration involves global parameters and interface parameters. IS-IS
global parameters need to be configured in IS-IS route mode. To configure global IS-IS
parameters, perform the following steps.
Step

Command

Function

ZXR10(config)#router isis [ vrf < vrf-name> ]

Enable IS-IS routing process and


enter route configuration mode.

Disable IS-IS instance and clear

ZXR10(config-router)#disable

IS-IS running data.


3

ZXR10(config-router)#enable

Restart IS-IS instance.

ZXR10(config-router)#metric-style { narrow | wide}

Configure IS-IS metric type.

ZXR10(config-router)#is-type { level-1 | level-1-2 | level-2-only}

Set IS-IS operation type.

ZXR10(config-router)#set-overload-bit [ on-start-up | suppress]

Set IS-IS OL bit to enable the


local router to send notification to
other routers when its processing
capability is insufficient.

ZXR10(config-router)#default-information originate [ always] [

Generate default route. When

metric < metric-value> ] [ metric-type < type> ] [ level-1 | level-1-2 |

configuring route redistribution, this

level-2]

command is used on the router to


redistribute the default route in route
entries into IS-IS domain.

ZXR10(config-router)#summary-address < ip-address> < net-mask>

Set IS-IS summary address.

< metric-value> [ level-1 | level-1-2 | level-2]

5-4
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 5 IS-IS Configuration

Tip:
IS-IS can summarize some entries in the routing table to one summary route and advertise
it, instead of advertising all routes. The smallest metric value in the summary route is
selected as metric value of the summary route.

5.2.3 Configuring IS-IS Interface Parameters


Interface IS-IS parameters need to be configured on the interface running IS-IS in interface
mode. The configurations of interface parameters are given below:
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter into interface configuration


mode.

ZXR10(config-if)#isis psnp-interval < interval> [ level-1 | level-2]

Set PSNP sending interval (PSNP is


often used in point-to-point network
and the parameter < interval> is used
to set the interval of sending PSNPs,
3 by default).

ZXR10(config-if)#isis circuit-type { level-1 | level-1-2 |

Set interface operation type.

level-2-only}
4

ZXR10(config-if)#isis hello-interval < interval> [ level-1 | level-2]

Configure the interval of sending Hello


packets on the interface.

ZXR10(config-if)#isis hello-multiplier < multiplier> [ level-1 |

Set the multiple between hello interval

level-2]

and holdtime configured on interface.

ZXR10(config-if)#isis lsp-interval < interval> [ level-1 | level-2]

Set the interval of sending LSP


packets.

ZXR10(config-if)#isis priority < priority> [ level-1 | level-2]

Configure priority on interface for DIS


election.

ZXR10(config-if)#isis metric < metric-value> [ level-1 | level-2]

Set metric value on IS-IS interface (It


is ok to set different metric values for
L1 and L2 on the same interface, 10
by default).

ZXR10(config-if)#isis csnp-interval < interval> [ level-1 | level-2]

Set CSNP interval (It is 10 by default in


broadcast network and 3600 by default
in a point-to-point network).

5-5
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

5.2.4 Configuring IS-IS Authentication


ZXR10 ZSR supports four types of IS-IS authentication:
l
l
l
l

Inter-neighbor authentication
Intra-area authentication
Inter-area authentication
Inter-SNP authentication

At present ZXR10 ZSR supports simple password authentication and MD5 authentication.
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#isis authentication < key> [ level-1 | level-2]

Configure simple password


authentication for hello packets.

ZXR10(config-if)#isis authentication-type { MD5 | TEXT} [

Configure authentication mode for

level-1 | level-2]

IS-IS hello packets.

ZXR10(config-if)#exit

Exit from interface configuration mode.

ZXR10(config)#router isis [ vrf < vrf-name> ]

Enable IS-IS routing process and enter


route configuration mode.

ZXR10(config-router)#authentication < key> [ level-1 | level-2]

Configure IS-IS LSP authentication.

ZXR10(config-router)#enable-snp-authentication

Configure authentication for SNP


packets.

Example
l

This example shows how to configure SNP simple password authentication with
authentication string as welcome.
ZXR10(config)#router isis
ZXR10(config-router)#authentication welcome
ZXR10(config-router)#enable-snp-authentication

This example shows how to configure L1 LSP MD5 authentication with authentication
string to as welcome.
ZXR10(config)#router isis
ZXR10(config-router)#authentication welcome level-1
ZXR10(config-router)#authentication-type md5 level-1

5.3 Configuring IS-IS Maintenance and Diagnosis


To perform IS-IS maintenance and diagnosis, execute the following commands (in all
modes).
5-6
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 5 IS-IS Configuration

Format

Function

ZXR10#show isis adjacency [ level-1 | level-2] [ vrf < vrf-name> ]

Show adjacency and current neighbor


statuses.

ZXR10#show isis circuits [ detail] [ vrf < vrf-name> ]

Show current information of IS-IS


interface.

ZXR10#show isis database [ level-1 | level-2] [ detail] [ vrf < vrf-name> ]

Show current information of IS-IS


database.

ZXR10#show isis topology [ level-1 | level-2] [ vrf < vrf-name> ]

Show current IS-IS topology.

For the configuration of debug commands, use the following commands.


Format

Function

ZXR10#debug isis adj-packets

Trace and show the received and sent


IS-IS Hello packets.
Trace and show the received and

ZXR10#debug isis snp-packets

sent IS-IS SNP packets and relevant


processing events.
Trace and show the debugging information

ZXR10#debug isis spf-events

of IS-IS route calculation events.


Trace and show the debugging information

ZXR10#debug isis update-packets

of IS-IS LSP processing events.

5.4 IS-IS Configuration Example


Before configuring IS-IS, analyze the whole network. This example explains the network
topology which needs to decide whether it is needed to divide the network into multiple
areas and determines the running of multiple routing protocols on the network according
to network size. The following example shows the basic configuration of IS-IS protocol in
a single-area network, as shown in Figure 5-2.
Figure 5-2 Single-Area IS-IS Configuration

5-7
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

In the above figure, R1 and R2 form Area 1 and IS-IS is enabled on the two. The detailed
configuration is shown as follows.
Configuration of R1:
ZXR10_R1(config)#router isis
ZXR10_R1(config-router)#area 01
ZXR10_R1(config-router)#system-id 00D0.D0C7.53E0
ZXR10_R1(config-router)#exit
ZXR10_R1(config)#interface fei_2/4
ZXR10_R1(config-if)#ip address 192.168.2.1 255.255.255.0
ZXR10_R1(config-if)#ip router isis
ZXR10_R1(config)#interface fei_2/6
ZXR10_R1(config-if)#ip address 192.168.1.1 255.255.255.0
ZXR10_R1(config-if)#ip router isis

Configuration of R2:
ZXR10_R2(config)#router isis
ZXR10_R2(config-router)#area 01
ZXR10_R2(config-router)#system-id 00D0.D0C7.5460
ZXR10_R2(config-router)#exit
ZXR10_R2(config)#interface fei_1/4
ZXR10_R2(config-if)#ip address 192.168.2.2 255.255.255.0
ZXR10_R2(config-if)#ip router isis
ZXR10_R2(config)#interface fei_1/3
ZXR10_R2(config-if)#ip address 192.168.6.1 255.255.255.0
ZXR10_R2(config-if)#ip router isis

5-8
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6

BGP Configuration
Table of Contents
BGP Overview............................................................................................................6-1
Configuring BGP ........................................................................................................6-2
Configuring BGP Maintenance and Diagnosis ..........................................................6-21
BGP Configuration Example.....................................................................................6-23

6.1 BGP Overview


Border Gateway Protocol (BGP) is an inter-domain routing protocol, exchanging Network
Layer Reachable Information (NLRI) between ASs that run BGP.
The information mainly includes the list of ASs that a route passes through, which can
be used to compose an AS connection state diagram. This makes the AS-based routing
policy possible and solves the loop problem.
BGP of version 4 (BGP4) is the latest BGP version, which is defined in RFC1771. BGP4
supports the implementation of CIDR, supernet and subnet and the functions such as route
aggregation and route filtering. At present, BGP4 is widely applied in Internet.
A management area that has its own independent routing policy is called an autonomous
system (AS). An important feature of an AS is that from the perspective of another AS, it
has a set of internal routes and shows identical topology for reachable destinations.
The AS indicator is a 16-bit value ranging from 1 to 65535, where the numbers between 1
to 32767 can be allocated, those from 32768 to 64511 are reserved, and those from 64512
to 65534 are used for private ASs (similar to private network addresses in IP address).
The session between BGP routers in different ASs is called EBGP session; BGP routers
in one AS set up an IBGP session.
BGP is based on reliable transmission protocol. TCP is used as its bottomlayer protocol
and the TCP port as 179. The BGP routers firstly set up a TCP connection, and then
exchange all routing table information after packet authentication. After that, when the
routing table changes, they send route update packets to all BGP neighbors, who will
further spread the routing information until it reaches the whole network.
When a router sends a BGP update packet regarding to the destination network to its peer,
the packet contains BGP metric, which is called path attribute. The path attributes include
four types:
l

Recognized attributes that must be followed: The attributes must be present in route
description.
6-1

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

AS-path
next-hop
origin
l

Recognized and self-determined attributes: The attributes do not have to appear in


route description.
Local preference
Atomic aggregate

Optional and transferable attributes: These attributes do not need support by all BGP
implementations. When supported, the attributes can be transferred to the BGP
neighbors; if not supported by the current router, the attributes need to be transferred
to other BGP routers.
Aggregator
Community

Optional and non-transferable attributes: It indicates that the router not supporting this
kind of attributes shall delete the attributes.
Multi-exiy-discriminator (MED)

Besides the above attributes, the weight attribute (defined by CISCO) is also a common
attribute.

6.2 Configuring BGP


6.2.1 Enabling BGP
There are three steps to enable BGP routing protocol on a router.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#neighbor < ip-address> remote-as <

Configure BGP neighbor (the range

number>

of AS is 1-65535).

ZXR10(config-router)#network < ip-address> < net-mask>

Use BGP to advertise a network.

Example
Figure 6-1 shows an instance of BGP4 configuration. Where R1 belongs to AS 100 and
R2 belongs to AS 200.

6-2
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration

Figure 6-1 Basic BGP Configuration

Configuration of R1:
ZXR10_R1(config)#router bgp 100
ZXR10_R1(config-router)#neighbor 10.1.1.1 remote-as 200
ZXR10_R1(config-router)#network 182.16.0.0 255.255.0.0

Configuration of R2:
ZXR10_R2(config)#router bgp 200
ZXR10_R2(config-router)#neighbor 10.1.1.2 remote-as 100
ZXR10_R3(config-router)#network 182.17.0.0 255.255.0.0

In the above configuration, R1 and R2 are defined as BGP neighbor of each other. Since
R1 and R2 belong to different ASs, they will set up an EBGP session. R1 advertises
network 182.16.0.0/16 and R2 advertises network 182.17.0.0/16.

6.2.2 Configuring BGP Route Advertisement


To configure BGP route advertisement, perform the following steps.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

This enables BGP process and


enters route configuration mode

ZXR10(config-router)#network < ip-address> < net-mask>

This advertises the known network


to local router

Tip:
The use of the network command in BGP is different from that in IGP.
In the above configurations, the network command is used to advertise BGP routers.
In BGP, we can use the network command to advertise networks known by local router.
The known networks can be learned through direct, static and dynamic routes.

6-3
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

To redistribute IGP, RIP, OSPF and IS-IS) routes to BGP, execute the following commands.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#redistribute < protocol> [ metric <

Redistribute routes of other

metric-value> ] [ route-map < map-tag> ]

protocols to BGP routing table.

Note:
When using redistribute command, avoid redistributing the routes that IGP learns from
BGP to BGP again, and use filter commands to prevent loop if necessary.
The route source of redistributed static routes in routing table is shown as incomplete.

Example
Figure 6-2 shows an example of advertising routes to BGP by route redistribution.
Figure 6-2 BGP Route Advertisement

ZXR10_R3(config)#router ospf 1
ZXR10_R3(config-router)#network 175.220.0.0 0.0.0.255 area 0
ZXR10_R3(config-router)#exit
ZXR10_R3(config)#router bgp 200
ZXR10_R3(config-router)#neighbor 1.1.1.1 remote-as 300
ZXR10_R3(config-router)#redistribute ospf-int

6-4
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration

6.2.3 Configuring BGP Route Aggregation


Through aggregate-address command, BGP can aggregate multiple learnt routes to one
route and advertise it outside, so that the entries in a routing table can be significantly
reduced.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#aggregate-address < ip-address> <

Create one aggregation policy (the

net-mask> [ count < count> ] [ as-set] [ summary-only] [ strict]

range of < count> is 0-255, 1 by


default)

ZXR10(config-router)#aggregate-address < ip-address> <

Create one aggregation policy in

net-mask> subnet < subnet-address> < subnet-mask>

BGP routing table.

Example
The following section shows an example of route aggregation. As shown in Figure 6-3,
routers R1 and R2 notify 170.10.0.0/16 and 170.20.0.0/16 of routes respectively. R3
aggregates the two routes into 170.0.0.0/8 and advertises it to R4. After configuring route
aggregation, the routing table of R4 can only learn the aggregate route 170.0.0.0/8.
Figure 6-3 BGP Route Aggregation

Configuration of R1:
ZXR10_R1(config)#interface fei_1/1
ZXR10_R1(config-if)#ip address 2.2.2.2 255.255.255.0
ZXR10_R1(config-if)#exit
ZXR10_R1(config)#router bgp 100

6-5
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


ZXR10_R1(config-router)#network 170.20.0.0 255.255.0.0
ZXR10_R1(config-router)#neighbor 2.2.2.1 remote-as 300

Configuration of R2:
ZXR10_R2(config)#interface fei_1/1
ZXR10_R2(config-if)#ip address 3.3.3.3 255.255.255.0
ZXR10_R2(config-if)#exit
ZXR10_R2(config)#router bgp 200
ZXR10_R2(config-router)#network 170.10.0.0 255.255.0.0
ZXR10_R2(config-router)#neighbor 3.3.3.1 remote-as 300

Configuration of R3:
ZXR10_R3(config)#interface fei_1/1
ZXR10_R3(config-if)#ip address 2.2.2.1 255.255.255.0
ZXR10_R3(config-if)#exit
ZXR10_R3(config)#interface fei_1/2
ZXR10_R3(config-if)#ip address 3.3.3.1 255.255.255.0
ZXR10_R3(config)#interface fei_1/3
ZXR10_R3(config-if)#ip address 4.4.4.1 255.255.255.0
ZXR10_R3(config-if)#exit
ZXR10_R3(config)#router bgp 300
ZXR10_R3(config-router)#neighbor 2.2.2.2 remote-as 100
ZXR10_R3(config-router)#neighbor 3.3.3.3 remote-as 200
ZXR10_R3(config-router)#neighbor 4.4.4.4 remote-as 400
ZXR10_R3(config-router)#aggregate-address 170.0.0.0 255.0.0.0
summary-only

R3 learns both routes 170.20.0.0 and 170.10.0.0, but it only advertises the aggregate route
170.0.0.0/8. Pay attention to the parameter summary-only in the command. Without this
parameter, R3 will advertise the detailed routes together with aggregate route.
Configuration of R4:
ZXR10_R4(config)#interface fei_1/1
ZXR10_R4(config-if)#ip address 4.4.4.4 255.0.0.0
ZXR10_R4(config-if)#exit
ZXR10_R4(config)#router bgp 400
ZXR10_R4(config-router)#neighbor 4.4.4.1 remote-as 300

6.2.4 Configuring EBGP Multi-Hops


EBGP neighbor is established on the direct-connect interfaces of two routers. To establish
EBGP neighborhood on non-direct connect interfaces, the following commands are used
6-6
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration

to perform EBGP multihop configuration, as well as proper IGP or static route configuration
to enable intercommunication between non-direct connect neighbors.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#neighbor < ip-address> ebgp-multihop [

Establish EBGP neighborhood over

ttl < value> ]

indirect-connect networks.

Example
As shown in Figure 6-4, router R1 needs to establish neighborhood with a non-direct
connect interface (180.225.11.1) on R2. Command neighbor ebgp-multihop is used.
Figure 6-4 BGP Multi-hop Configuration

Configuration of R1:
ZXR10_R1(config)#interface fei_1/1
ZXR10_R1(config-if)#ip address 129.213.1.2 255.255.255.0
ZXR10_R1(config-if)#exit
ZXR10_R1(config)#router bgp 100
ZXR10_R1(config-router)#neighbor 180.225.11.1 remote-as 300
ZXR10_R1(config-router)#neighbor 180.225.11.1 ebgp-multihop

Configuration of R2:
ZXR10_R2(config)#interface fei_1/1
ZXR10_R2(config-if)#ip address 129.213.1.3 255.255.255.0
ZXR10_R2(config)#interface fei_1/2
ZXR10_R2(config-if)#ip address 180.225.11.1 255.255.255.0
ZXR10_R2(config-if)#exit
ZXR10_R2(config)#router bgp 300
ZXR10_R2(config-router)#neighbor 129.213.1.2 remote-as 100

6.2.5 Filtering Routes by Using Route Map


The setting of route filtering and attributes are the base of BGP routing policy. With route
filtering, it is possible to control the attributes of the imported and exported routes according
to requirements.
6-7
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

The route map is used to control the routing information and redistribute routes between
areas by specifying conditions. The route map works with the route attributes to make
routing decisions. To use a route map, perform the following steps.
Step

Format

Function

ZXR10(config)#route-map < map-tag> [ permit | deny] [ <

Define a route map and enter route

sequence-number> ]

map configuration mode.

ZXR10(config-router)#exit

Exit from route map configuration

mode.
3

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#neighbor < ip-address> route-map <

Filter the routes advertised to/from

map-tag> { in | out}

neighbors or configure priorities for


them.

Example
The following example shows how to configure route filtering by route map.
A route map MAP1 is defined in the above example. This route map allows to advertise
network 172.3.0.0 to AS 200 and sets its MED as 5. When using route map for route
filtering, it is uses match command and set command together. The match command
defines the match conditions and set command defines the action to be executed when
set match conditions are met.
ZXR10_R1(config)#router bgp 100
ZXR10_R1(config-router)#neighbor 182.17.20.1 remote-as 200
ZXR10_R1(config-router)#neighbor 182.17.20.1 route-map MAP1 out
ZXR10_R1(config-router)#neighbor 182.17.20.1 send-med
ZXR10_R1(config-router)#exit
ZXR10_R1(config)#route-map MAP1 permit 10
ZXR10_R1(config-route-map)#match ip address 1
ZXR10_R1(config-route-map)#set metric 5
ZXR10_R1(config)#ip access-list standard 1
ZXR10_R1(config-std-acl)#permit 172.3.0.0 0.0.255.255

6.2.6 Filtering Routes by Using NLRI


To limit a router to get or advertise the routing information, filter the route updates received
from or sent to a specific neighboring device. The filter has an update list sent to or received
from the neighbor.

6-8
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration

Example
As shown in Figure 6-5, R1 and R2 are IBGP peers; R1 and R3 are EBGP peers; and R2
and R4 are EBGP peers.
Figure 6-5 Filtering Router through NLRI

To prevent AS100 from being a transitional AS and prevent R1 from advertising the network
192.18.10.0/24 from AS300 to AS200, perform filtering on R1. Configuration is as follows:
ZXR10_R1(config)#router bgp 100
ZXR10_R1(config-router)#no synchronization
ZXR10_R1(config-router)#neighbor 182.17.1.2
ZXR10_R1(config-router)#neighbor 182.17.20.1

remote-as 100
remote-as 200

ZXR10_R1(config-router)#neighbor 182.17.20.1 route-map MAP1 out


ZXR10_R1(config-router)#exit
ZXR10_R1(config)#route-map MAP1 permit 10
ZXR10_R1(config-route-map)#match ip address 1
ZXR10_R1(config)#ip access-list standard 1
ZXR10_R1(config-std-acl)#deny 192.18.10.0 0.0.0.255
ZXR10_R1(config-std-acl)#permit 0.0.0.0 255.255.255.255

In this example, commands route-map and access-list are used to prevent R1 from
advertising routes with prefix 192.18.10.0/24 to AS200.

6.2.7 Filtering Routes by Using AS_PATH


To filter all routes in one or more ASs, use AS-path-based route filtering method. It can
avoid the complexity caused by prefix-based filtering.
6-9
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Use the following command to set a new ACL for imported and exported route updates
based on AS path attribute.
Step

Format

Function

ZXR10(config)#ip as-path access-list < access-list-number> { permit

Define BGP-related ACL.

| deny} < as-regular-expression>

Example
Use AS path-based route filtering to prevent R1 from advertising the network
192.18.10.0/24 from AS300 to AS200. Configuration is as follows:
ZXR10_R1(config)#router bgp 100
ZXR10_R1(config-router)#no synchronization
ZXR10_R1(config-router)#neighbor 182.17.1.2

remote-as 100

ZXR10_R1(config-router)#neighbor 182.17.20.1

remote-as 200

ZXR10_R1(config-router)#neighbor 182.17.20.1

route-map MAP1 out

ZXR10_R1(config-router)#exit
ZXR10_R1(config)#route-map MAP1 permit 10
ZXR10_R1(config-route-map)#match as-path 1
ZXR10_R1(config)#ip as-path access-list 1 permit ^$

In above configuration, with AS-path based ACL, R1 only advertises the networks
originating from AS100 to AS200, so that routes of network 192.18.10.0/24 can be filtered.

6.2.8 Configuring LOCAL_PREF Attribute


The value of attribute Local Preference is used for routing between IBGP peers inside an
AS.
To set local preference value for BGP advertised route, perform the following steps.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#bgp default local-preference < value>

Configure local-preference value for


BGP advertised route.

When two IBGP routers in one AS learn external routes to the same destination
simultaneously, their Local preference values are compared. The route with larger value
is preferential. The default value of Local-preference is 100.

Example
As shown in Figure 6-6, R3 and R4 learn routes to 170.10.0.0 simultaneously. Since the
Local preference value of R4 is larger than that of R3, packets sent from AS256 interior to
the destination prefer to be forwarded through interface of R4.
6-10
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration

Figure 6-6 Configure LOCAL-PREF Attribute

The following two modes are used to configure the LOCAL_PREF attribute.
l

Set LOCAL_PREF attribute with command bgp default local-preference.


Configuration of R3:
ZXR10_R3(config)#router bgp 256
ZXR10_R3(config-router)#neighbor 1.1.1.1 remote-as 100
ZXR10_R3(config-router)#neighbor 128.213.11.2 remote-as 256
ZXR10_R3(config-router)#bgp default local-preference 150

Configuration of R4:
ZXR10_R4(config)#router bgp 256
ZXR10_R4(config-router)#neighbor 3.3.3.2 remote-as 300
ZXR10_R4(config-router)#neighbor 128.213.11.1 remote-as 256
ZXR10_R4(config-router)#bgp default local-preference 200

Set LOCAL_PREF attribute with command route-map.


Configuration of R4:
ZXR10_R4(config)#router bgp 256
ZXR10_R4(config-router)#neighbor 3.3.3.2 remote-as 300
ZXR10_R4(config-router)#neighbor 3.3.3.2 route-map setlocalin in
ZXR10_R4(config-router)#neighbor 128.213.11.1 remote-as 256
ZXR10_R4(config-router)#exit
ZXR10_R4(config)#ip as-path access-list 7 permit ^300$
ZXR10_R4(config)#route-map setlocalin permit 10
ZXR10_R4(config-route-map)#match as-path 7
ZXR10_R4(config-route-map)#set local-preference 200
ZXR10_R4(config)#route-map setlocalin permit 20

6-11
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


ZXR10_R4(config-route-map)#set local-preference 150

6.2.9 Configuring MED Attribute


The Metric attribute is also called Multi_Exit_Discrimination (MED) attribute, used for the
exchanging between ASs for route decision.
The router only compares the Metric values of BGP neighbors in the same AS by default.
To compare Metric values of BGP neighbors from different ASs, perform the following
steps.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#bgp always-compare-med

Compare path MED values of BGP


neighbors in different ASs.

The Metric value is 0 by default. Smaller Metric value is preferred. The Metric value is not
delivered to the third AS. That is, when receiving an update packet with the Metric value,
the update packet will be delivered to the third AS with the default Metric.

Example
As shown in Figure 6-7, R1 receives the update packets of 180.10.0.0 from R2, R3 and
R4 at the same time. Only Metric values of neighbors R3 and R4 (in the same AS) are
compared by default; the Metric value of R3 is smaller than that of R4. Therefore, for
180.10.0.0 update packets, R1 prefers to use the value of R3.
Figure 6-7 Configure MED Attribute

The following shows how to set MED value with command route-map.
Configuration of R1:
6-12
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration


ZXR10_R1(config)#router bgp 100
ZXR10_R1(config-router)#neighbor 2.2.2.1 remote-as 300
ZXR10_R1(config-router)#neighbor 3.3.3.2 remote-as 300
ZXR10_R1(config-router)#neighbor 4.4.4.1 remote-as 400

Configuration of R3:
ZXR10_R3(config)#router bgp 300
ZXR10_R3(config-router)#neighbor 2.2.2.2 remote-as 100
ZXR10_R3(config-router)#neighbor 2.2.2.2 route-map setmetricout out
ZXR10_R3(config-router)#neighbor 1.1.1.2 remote-as 300
ZXR10_R3(config-router)#exit
ZXR10_R3(config)#route-map setmetricout permit 10
ZXR10_R3(config-route-map)#set metric 120

Configuration of R4:
ZXR10_R4(config)#router bgp 300
ZXR10_R4(config-router)#neighbor 3.3.3.1 remote-as 100
ZXR10_R4(config-router)#neighbor 3.3.3.1 route-map setmetricout out
ZXR10_R4(config-router)#neighbor 1.1.1.1 remote-as 300
ZXR10_R4(config-router)#exit
ZXR10_R4(config)#route-map setmetricout permit 10
ZXR10_R4(config-route-map)#set metric 200

Configuration of R2:
ZXR10_R2(config)#router bgp 400
ZXR10_R2(config-router)#neighbor 4.4.4.2 remote-as 100
ZXR10_R2(config-router)#neighbor 4.4.4.2 route-map setmetricout out
ZXR10_R2(config-router)#exit
ZXR10_R2(config)#route-map setmetricout permit 10
ZXR10_R2(config-route-map)#set metric 50

In the following configuration, command bgp always-compare-med is used to compare


the metric values of R1 and R2 by force. Metric value of R2 is smaller than that of R3.
Therefore, for 180.10.0.0 update packets, R1 prefers that of R2 rather than R3.
Configuration of R1:
ZXR10_R1(config)#router bgp 100
ZXR10_R1(config-router)#neighbor 2.2.2.1 remote-as 300
ZXR10_R1(config-router)#neighbor 3.3.3.2 remote-as 300
ZXR10_R1(config-router)#neighbor 4.4.4.1 remote-as 400
ZXR10_R1(config-router)#bgp always-compare-med

6-13
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

6.2.10 Configuring Community Attribute


The community string attribute is an optional transferred attribute in range of
0-4294967200. It is available to make route decision to a set of routes according to
community string attribute.
The definition to several recognized community attributes is as follows:
l
l
l

no-export: It is forbidden to advertise routes to EBGP neighbor


no-advertise: It is forbidden to advertise routes to any BGP neighbor
no-export-subconfed: It is forbidden to advertise routes with this attribute to ones
beyond the community.

In addition, ZXR10 ZSR supports the community attribute to have an ordinary value. There
are two types of community attribute formats with ordinary value:
l
l

<1~4294967295> Community number


<1~65535>:<0~65535> Community number in <aa:nn> format

Where aa:nn format is converted to a longer integer through the expression aa x 65536 +
nn. For example:
set community 1000:1 equals to set community 65536001
The route-map command is used to define community attribute. The community attribute
is not sent to neighbor by default. It can be sent to neighbor when advertising routes to
neighbor.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#neighbor < ip-address> send-community

Send community attribute when


advertising routes to neighbor or
neighbor peer group.

Example
This example shows how to configure route-map and to set community attribute to 1000:1
(that is 65536001):
ZXR10(config)#route-map setcomm
ZXR10(config-route-map)#set community ?
<1-4294967295>

Community number

<1-65535>:<0-65535>

Community number in aa:nn format

additive

Add to the existing community

no-advertise

Do not advertise to any peer

no-export

Do not export to next AS

no-export-subconfed

Do not send outside local AS

none

No community attribute

ZXR10(config-route-map)#set community 10001

6-14
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration


ZXR10(config)#show route-map setcomm
route-map setcomm permit 10
set community 1000:1

ZXR10 ZSR supports the community attribute with ordinary value and expands community
attribute-based filtering function.
In the following configuration, R1 will advertise the routes to its neighbors. It is forbidden
to advertise routes of 192.166.1.0/24 to other EBGP neighbors.
Configuration of R1:
ZXR10_R1(config)#router bgp 100
ZXR10_R1(config-router)#neighbor 3.3.3.3 remote-as 300
ZXR10_R1(config-router)#neighbor 3.3.3.3 send-community
ZXR10_R1(config-router)#neighbor 3.3.3.3 route-map setcomm out
ZXR10_R1(config)#route-map setcomm permit 10
ZXR10_R1(config-route-map)#match ip address 1
ZXR10_R1(config-route-map)#set community no-export
ZXR10_R1(config)#route-map setcomm permit 20
ZXR10_R1(config)#ip access-list standard 1
ZXR10_R1(config-std-acl)#permit 192.166.1.0 0.0.0.255

6.2.11 Configuring BGP Synchronization


As shown in Figure 6-8, in AS100, IBGP is enabled on R1 and R2 and mean while OSPF
is enabled on R1, R2 and R5.

6-15
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Figure 6-8 Configure BGP Synchronization

R1 learns a route pointing to 170.10.0.0 from AS300 and advertises it to R2 through IBGP
connection.
BGP synchronization rule is: Before a route learned from IBGP neighbor is redistributed
into IGP routing table or advertised to a BGP peer, BGP router must learn this route through
IGP.
According to BGP synchronization rule, before R2 advertises this route to R4, it fails to
discover route pointing to 170.10.0.0 through IGP. Therefore, it will not advertise the route
to R4.
The synchronization function is enabled by default.
There are two ways to solve this problem:
l
l

On R1 or R2, redistribute BGP routes unto OSPF.


Enable IBGP on R5 and form full-mesh connection with R1 and R2. Disable BGP
synchronization function on the three routers simultaneously.

The configuration of disabling route synchronization is as follows:


ZXR10_R2(config)#router bgp 100
ZXR10_R2(config-router)#no synchronization

6.2.12 Configuring BGP Route Reflector


As for BGP routers in the same AS, neighborhood must be established between each two.
Therefore, with the increasing of IBGP routers, the number of neighbors will increment by

6-16
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration

n (n-1)/2 (n indicates the number of IBGP routers). Router reflector and confederation are
used to reduce the job of maintenance and configuration.
For IBGP routers inside the AS, select one as the Router Reflector (RR) and take other
IBGP routers as clients, which only establishes adjacency with RR. All clients reflect routes
through RR. Number of neighbors decreases to n-1.
To set neighbors as RR clients, execute the following commands.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#neighbor < ip-address> router-reflector-cl

Set a neighbor or neighbor peer

ient

group as RR client.

ZXR10(config-router)#neighbor [ < ipv4-address> | <

Specify the name of interface used

peer-group-name> ] update-source < interface-name>

as the source address of TCP


connection in BGP session.

Example
As shown in Figure 6-9, AS100 has two router reflectors: R3 and R4. Among them, clients
of R4 are R5 and R6 and clients of R3 are R1 and R2.

6-17
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Figure 6-9 Configure BGP Route Reflector

Configuration of R3:
ZXR10_R3(config)#interface loopback1
ZXR10_R3(config-if)#ip address 3.3.3.3 255.255.255.255
ZXR10_R3(config-if)#exit
ZXR10_R3(config)#router bgp 100
ZXR10_R3(config-router)#neighbor 2.2.2.2 remote-as 100
ZXR10_R3(config-router)#neighbor 2.2.2.2 route-reflector-client
ZXR10_R3(config-router)#neighbor 1.1.1.1 remote-as 100
ZXR10_R3(config-router)#neighbor 1.1.1.1 route-reflector-client
ZXR10_R3(config-router)#neighbor 7.7.7.7 remote-as 100
ZXR10_R3(config-router)#neighbor 4.4.4.4 remote-as 100
ZXR10_R3(config-router)#neighbor 1.1.1.1 update-source loopback1
ZXR10_R3(config-router)#neighbor 2.2.2.2 update-source loopback1

Configuration of R2:
ZXR10_R2(config)#interface loopback1
ZXR10_R2(config-if)#ip address 2.2.2.2 255.255.255.255
ZXR10_R2(config-if)#exit
ZXR10_R2(config)#router bgp 100

6-18
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration


ZXR10_R2(config-router)#neighbor 3.3.3.3 remote-as 100
ZXR10_R2(config-router)#neighbor 3.3.3.3 update-source loopback1

When one route is received by RR, it will reflect according to types of different peers.
l
l
l

If the route comes from non-client peer, it is reflected to all client peers.
If the route comes from a peer client, it is reflected to all non-client peers and client
peers.
If the route comes from a EBGP peer, it is reflected to all non-client peers and client
peers.

In case of multiple RRs available in one AS, the multiple RRs in the AS are incorporated
into one cluster. There can be multiple clusters inside one AS and one cluster must contain
one RR at least.

6.2.13 Configuring BGP Confederation


The route confederation has the same function as router reflector. The purpose is to reduce
the number of IBGP connections established inside the same AS. Route confederation
divides an AS into multiple sub-ASs; multiple IBGP routers inside the AS belong to sub-ASs
respectively; IBGP is established inside the sub-AS and EBGP is established between
sub-ASs. As for routers outside AS, sub-ASs are invisible.
To configure BGP confederation, perform the following steps.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#bgp confederation identifier < value>

Set confederation ID.

ZXR10(config-router)#bgp confederation peers < value> [ < value>

Set confederation peer AS number.

]
4

ZXR10(config-router)#neighbor [ < ipv4-address> | <

Specify the name of interface used

peer-group-name> ] update-source < interface-name>

as the source address of TCP


connection in BGP session.

Example
The following example shows the application of route confederation.
As shown in Figure 6-10, there are five BGP routers in AS200, which is divided into two
sub-ASs. One is defined as AS65010 (consists of routers R3, R5 and R6) and the other
is defined as AS65020 (consists of routers R4 and R7).

6-19
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Figure 6-10 Configure BGP Confideration

Configuration of R3:
ZXR10_R3(config)#interface loopback1
ZXR10_R3(config-if)#ip address 210.61.30.1 255.255.255.255
ZXR10_R3(config-if)#exit
ZXR10_R3(config)#router bgp 65010
ZXR10_R3(config-router)#bgp confederation identifier 200
ZXR10_R3(config-router)#bgp confederation peers 65020
ZXR10_R3(config-router)#neighbor 210.61.10.1 remote-as 65010
ZXR10_R3(config-router)#neighbor 210.61.20.1 remote-as 65010
ZXR10_R3(config-router)#neighbor 210.61.19.2 remote-as 65020
ZXR10_R3(config-router)#neighbor 2.2.2.2 remote-as 100
ZXR10_R3(config-router)#neighbor 210.61.10.1 update-source loopback1
ZXR10_R3(config-router)#neighbor 210.61.20.1 update-source loopback1

Configuration of R5:
ZXR10_R5(config)#interface loopback1
ZXR10_R5(config-if)#ip address 210.61.10.1 255.255.255.255
ZXR10_R5(config-if)#exit
ZXR10_R5(config)#router bgp 65010
ZXR10_R5(config-router)#bgp confederation identifier 200
ZXR10_R5(config-router)#neighbor 210.61.30.1 remote-as 65010
ZXR10_R5(config-router)#neighbor 210.61.20.1 remote-as 65010
ZXR10_R5(config-router)#neighbor 210.61.30.1 update-source loopback1
ZXR10_R5(config-router)#neighbor 210.61.20.1 update-source loopback1

6-20
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration

When establishing neighborhood, EBGP neighborhood is established between R3 and


the confederation peer; IBGP neighborhood is established in the confederation; EBGP
neighborhood is also established between R3 and AS100. AS100 does not know whether
the confederation exists. Therefore, router R1 in AS100 still sets up adjacency with R3
through AS200.
Configuration of R1:
ZXR10_R1(config)#router bgp 100
ZXR10_R1(config-router)#neighbor 2.2.2.1 remote-as 200

6.2.14 Configuring BGP Route Dampening


BGP provides route dampening mechanism to reduce the instability caused by route flap.
Each time the flap occurs, the route is given a Penalty of 1000. The route will be
suppressed to advertise when the Penalty reaches suppress-limit. For each half-life-time,
the Penalty proportionally decreases . Route dampening will be cancelled when Penalty
decreases to reuse-limit.
To validate BGP route damping or to modify BGP route damping factors, execute the
following commands.
Step

Format

Function

ZXR10(config)#router bgp < as-number>

Enable BGP process and enter


route configuration mode.

ZXR10(config-router)#bgp dampening [ < half-life> < reuse> <

Validate BGP route damping or

suppress> < max-suppress-time> | route-map < map-tag> ]

modify BGP route damping factors.

l
l
l
l

Half-life-time: 1~45min, 15min by default


Reuse-value: 1~20000, 750 by default
Suppress-value: 1~20000, 2000 by default
Max-suppress-time: 1~255, 4 times of half-life-time by default

Example
This example describes how to enable route dampening function on a router:
ZXR10(config)#router bgp 100
ZXR10(config-router)#bgp dampening 15 750 2000 60

6.3 Configuring BGP Maintenance and Diagnosis


When BGP route problem is encountered, locate the fault and remove them with
debugging commands. User can view the current BGP neighbor state and learn BGP
route information with show commands.
6-21
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Format

Function

ZXR10#show ip bgp protocol

Show configuration information of the


BGP module.

ZXR10#show ip bgp neighbor [ [ vrf < vrf-name> ] < ip-address> ]

View BGP adjacency and show current


neighbor state.

ZXR10#show ip bgp neighbor [ in | out] < ip-address>


ZXR10#show ip bgp neighbor [ vrf-in | vrf-out] < ip-address> < vrf-name>
ZXR10#show ip bgp neighbor [ vpnv4-in | vpnv4-out] < ip-address>

ZXR10#show ip bgp route [ network < ip-address> [ mask < net-mask> ] ]

Show entries in BGP routing table.

ZXR10#show ip bgp summary

Show connection states of all BGP


neighbors.

Besides show command, debug command is also used to view the BGP adjacency process,
route update process and so on.
Format

Function

ZXR10#debug ip bgp in

Trace and show the notification packets


sent by BGP and list the error number
and sub-error number.
Trace and show the notification packets

ZXR10#debug ip bgp out

sent by BGP and list the error number


and sub-error number.
Trace and show transition of state

ZXR10#debug ip bgp events

machine connected to the BGP.

Example
The following example shows how to trace the state transition of BGP with debug ip bgp
events command.
ZXR10#debug ip bgp events
BGP events debugging is on
ZXR10#
04:10:07: BGP: 192.168.1.2 reset due to Erroneous BGP Open received
04:10:07: BGP: 192.168.1.2 went from Connect to Idle
04:10:08: BGP: 192.168.1.2 went from Idle to Connect
04:10:13: BGP: 192.168.1.2 went from Connect to OpenSent
04:10:13: BGP: 192.168.1.2 went from OpenSent to OpenConfirm
04:10:13: BGP: 192.168.1.2 went from OpenConfirm to Established

6-22
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 6 BGP Configuration


ZXR10#

6.4 BGP Configuration Example


The following BGP instance involves the actual applications of many BGP functions such
as route aggregation and static route redistribution.
As shown in Figure 6-11, EBGP is established between R4 and R1; IBGP is established
between R1 and R2; multihop is established between R2 and R5. Suppose that R4 has
four static routes as marked on upper right corner of the figure.
In R4 configuration, only routes in network segment 192.16.0.0/16 are aggregated and
advertised and through the route map, it is forbidden to advertise the network segment
170.16.10.0/24 to the outside by BGP. EBGP multi-hop relationship is established between
R2 and R5 through R3. Before configuring BGP, it shall make sure that the addresses of
two routers used to establish neighborhood can intercommunicate.
Figure 6-11 BGP Configuration Example

Configuration of R4:
ZXR10_R4(config)#router bgp 2
ZXR10_R4(config-router)#redistribute static
ZXR10_R4(config-router)#neighbor 172.16.20.2 remote-as 1
ZXR10_R4(config-router)#aggregate-address 192.16.0.0 255.255.0.0
count 0 as-set summary-only
ZXR10_R4(config-router)#neighbor 172.16.20.2 route-map torouter1 out
ZXR10_R4(config-router)#exit
ZXR10_R4(config)#ip access-list standard 1
ZXR10_R4(config-std-acl)#permit 172.16.10.0 0.0.0.255
ZXR10_R4(config-std-acl)#exit
ZXR10_R4(config)#route-map torouter1 deny 10
ZXR10_R4(config-route-map)#match ip address 1
ZXR10_R4(config-route-map)#exit

6-23
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


ZXR10_R4(config)#route-map torouter1 permit 20

Configuration of R1:
ZXR10_R1(config)#router bgp 1
ZXR10_R1(config-router)#no synchronization
ZXR10_R1(config-router)#neighbor 172.16.1.2 remote-as 1
ZXR10_R1(config-router)#neighbor 172.16.1.2 next-hop-self
ZXR10_R1(config-router)#neighbor 172.16.20.1 remote-as 2

Configuration of R2:
ZXR10_R2(config)#ip route 183.16.0.0 255.255.0.0 173.16.20.1
ZXR10_R2(config)#router bgp 1
ZXR10_R2(config-router)#no synchronization
ZXR10_R2(config-router)#neighbor 172.16.1.1 remote-as 1
ZXR10_R2(config-router)#neighbor 172.16.1.1 next-hop-self
ZXR10_R2(config-router)#neighbor 183.16.20.2 remote-as 3
ZXR10_R2(config-router)#neighbor 183.16.20.2 ebgp-multihop ttl 2

Configuration of R5:
ZXR10_R5(config)#ip route 173.16.0.0 255.255.0.0 183.16.20.1
ZXR10_R5(config)#router bgp 3
ZXR10_R5(config-router)#neighbor 173.16.20.2 remote-as 1
ZXR10_R5(config-router)#neighbor 173.16.20.2 ebgp-multihop ttl 2

6-24
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 7

Policy Routing Configuration


Table of Contents
Policy Routing Overview.............................................................................................7-1
Configuring Policy Routing .........................................................................................7-3
Policy Routing Configuration Example........................................................................7-4

7.1 Policy Routing Overview


Traditionally, a router obtains the next hop by searching routing table according to the
destination address to forward packets. The entries in routing table are specified statically
by the network administrator or generated dynamically by routing protocol through routing
algorithm.
Compared with traditional routing, policy routing is more powerful and more flexible. With
policy routing, the network administrator can select the forwarding path according to
destination address, packet application (TCP/UDP port number) or source IP address.
As for control to packet forwarding, policy routing has a stronger capability over traditional
routing and packet ToS value and priority can be set for policy routing. Policy routing can
implement traffic engineering to a certain extent, thus ensuring that data flows with different
service qualities or of different properties (such as voice and FTP) go to different paths. The
user has higher and higher requirements to network performance, therefore, it is necessary
to select different packet forwarding paths based on the differences of services or user
categories.
Network administrator can define different Route-maps by using match and set clauses
on ZXR10 ZSR and then apply the Route-map on the packet incoming interface, thus
implementing path selection.
Each Route-map has a series of sequences with each sequence containing multiple match
and set clauses. Clause match defines match conditions. Policy routing is performed
when the incoming packet meets the conditions. Clause set specifies the routing behaviors
when the packet meets the match conditions. In case a packet does not meet the match
conditions in a sequence, the packet tries to match the next sequence.
When a router receives a packet, it firstly judges if the ingress is bound with policy routing.
If not, it searches the routing table for the destination and forward the packet according
to the destination address, if so, it processes the packet according to the sequence of
Route-map. The specific procedures are as shown in Figure 7-1.

7-1
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Figure 7-1 Packet Forwarding Bound with Policy Routing

7-2
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 7 Policy Routing Configuration

The detailed process is as follows:


1. Firstly match the packet with ACL configured in the first sequence. If matching fails,
continue to match the packet with ACL in the next sequence, and so forth. If matching
succeeds, judge the attribute of the sequence.
2. If the attribute of the sequence is deny, the packet is routed in the normal way; if the
attribute is permit, router forwards the packet according to set clause in the sequence.
3. The router checks whether a valid set ip next-hop (direct next-hop) exists. When multiple set ip next-hop settings are available, the router selects the first valid next-hop
according to the sequence. If it exists, the router forwards the packet to the specified
next-hop.
4. If set ip next-hop is not set or no valid set ip next-hop is available, the router needs
to check whether a valid egress exists (The egress exists and is in UP status). When
multiple set interface settings are available, the router selects the first valid egress
according to the sequence. If it exists, the router sends the packet from the egress.
Otherwise, the router routes the packet in the normal way.
5. In normal routing, if the router finds corresponding route in the forwarding table, it
forwards the packet according to the route. Otherwise, it forwards the packet according
to the valid set ip default next-hop (direct next-hop) specified in policy routing. When
multiple set ip default next-hop settings are available, the router selects the first
default next-hop according to the sequence.
6. If set ip default next-hop is not set or no valid set ip default next-hop is available,
the router forwards the packet according to the valid set default interface specified in
policy routing. When multiple set default interface settings are available, the router
selects the first valid default egress according to the sequence.
7. If set default interface is not set or no valid set default interface is available, the
router forwards the packet according to the default route.
8. If no default route is specified in the system, the packet will be dropped.

Note:
On ZXR10 ZSR, the path selection modes for packet forwarding are prioritized as policy
routing>normal routing>default routing.

7.2 Configuring Policy Routing


To configure policy routing, perform the following steps.
Step
1

Format

Function

ZXR10(config)#route-map < map-tag> [ permit | deny] [ <

Create a Route-map used for

sequence-number> ]

policy routing and enter route map


configuration mode.

7-3
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Step

Format

Function

ZXR10(config-route-map)#match ip address { < access-list-number>

Perform policy routing to the packet

| < access-list-name> } [ < access-list-number> | < access-list-name> ]

that matches ACL.

ZXR10(config-route-map)#set ip next-hop < ip-address> [ <

When policy routing can be

ip-address> ]

performed to a packet, route the

packet to the designated next hop.


4

ZXR10(config-route-map)#set interface < interface-name> [ <

When policy routing can be

interface-name> ]

performed to a packet, route the


packet to the designated interface.

ZXR10(config-route-map)#set ip default next-hop < ip-address> [

When policy routing can be

< ip-address> ]

performed to a packet but the


definite route to the destination is
unavailable, route the packet to the
designated next hop.

ZXR10(config-route-map)#set default interface < interface-name> [

When policy routing can be

< interface-name> ]

performed to a packet but the


definite route to the destination is
unavailable, route the packet to the
designated interface.

Exit from route map configuration

ZXR10(config-route-map)#exit

mode.
8

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip policy route-map < map-tag>

Configure plicy routing-based fast


forwarding for incoming packets on
the interface.

7.3 Policy Routing Configuration Example


When there are multiple Internet Service Provider (ISP) egresses in the network, it is
possible to select different ISP egresses for users of different groups by configuring policy
routing on egress router, or select different ISP egresses based on service types.

Policy Routing Configuration Example One


As shown in Figure 7-2, a router accesses users of two subnets through different
interfaces. Two ISP egresses are available, and users with different IP addresses need
to select different egresses. The services of users whose IP addresses belong to subnet
10.10.0.0/24 are forwarded through ISP1 egress and services of those belonging to
subnet 11.11.0.0/24 are forwarded through ISP2 egress.

7-4
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 7 Policy Routing Configuration

Figure 7-2 Policy Routing Configuration Example One

Configuration of ZXR10:
ZXR10(config)#interface fei_1/1
ZXR10(config-if)#ip address 10.10.0.254 255.255.255.0
ZXR10(config-if)#ip policy route-map source-ip
ZXR10(config-if)#exit

ZXR10(config)#interface fei_1/2
ZXR10(config-if)#ip address 11.11.0.254 255.255.255.0
ZXR10(config-if)#ip policy route-map source-ip
ZXR10(config-if)#exit

ZXR10(config)#interface fei_2/1
ZXR10(config-if)#ip address 100.1.1.2 255.255.255.252
ZXR10(config-if)#exit

ZXR10(config)#interface fei_2/2
ZXR10(config-if)#description To ISP2
ZXR10(config-if)#ip address 200.1.1.2 255.255.255.252
ZXR10(config-if)#exit

ZXR10(config)#ip route 0.0.0.0 0.0.0.0 100.1.1.1

ZXR10(config)#acl standard number 50


ZXR10(config-std-acl)#rule 1 permit 10.10.0.0 0.0.0.255
ZXR10(config-std-acl)#exit
ZXR10(config)#acl standard number 51
ZXR10(config-std-acl)#rule 1 permit 11.11.0.0 0.0.0.255
ZXR10(config-std-acl)#exit
ZXR10(config)#route-map source-ip permit 10
/*Forward the packets matching ACL 10 to 100.1.1.1*/
ZXR10(config-route-map)#match ip address 50
ZXR10(config-route-map)#set ip next-hop 100.1.1.1

7-5
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


ZXR10(config-route-map)#exit

ZXR10(config)#route-map source-ip permit 20


/*Forward the packets matching ACL 20 to 200.1.1.1*/
ZXR10(config-route-map)#match ip address 51
ZXR10(config-route-map)#set ip next-hop 200.1.1.1

In this instance, there are three cases:


l
l

When both ISP1 and ISP2 egresses are in normal state, services of users belonging
to 10.10.0.0/24 and 11.11.0.0/24 subnets are forwarded through ISP1 and ISP2;
When ISP1 is normal but ISP2 is abnormal, all services of users belonging to
10.10.0.0/24 and 11.11.0.0/24 subnets are forwarded through ISP1 and now the
default route is adopted for services of users in 11.11.0.0/24 subnet;
When ISP1 is abnormal and ISP2 is normal, services of users in 11.11.0.0/24 subnet
are normal, while those in 10.10.0.0/24 subnet are interrupted.

Policy Routing Configuration Example Two


As shown in Figure 7-3, when users in different subnets access router through the same
interface, the configuration to policy routing need to be changed.
Figure 7-3 Policy Routing Configuration Example Two

Configuration of ZXR10:
ZXR10(config)#interface fei_1/1
ZXR10(config-if)#ip address 192.168.1.1 255.255.255.252
ZXR10(config-if)#ip policy route-map source-ip
ZXR10(config-if)#exit

ZXR10(config)#interface fei_2/1
ZXR10(config-if)#ip address 100.1.1.2 255.255.255.252
ZXR10(config-if)#exit

ZXR10(config)#interface fei_2/2
ZXR10(config-if)#ip address 200.1.1.2 255.255.255.252

7-6
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 7 Policy Routing Configuration


ZXR10(config-if)#exit

ZXR10(config)#ip route 10.10.0.0 255.255.255.0 192.168.1.2


ZXR10(config)#ip route 11.11.0.0 255.255.255.0 192.168.1.2

ZXR10(config)#acl standard number 50


ZXR10(config-std-acl)#rule 1 permit 10.10.0.0 0.0.0.255
ZXR10(config-std-acl)#exit
ZXR10(config)#acl standard number 51
ZXR10(config-std-acl)#rule 1 permit 11.11.0.0 0.0.0.255
ZXR10(config-std-acl)#exit

ZXR10(config)#route-map source-ip permit 10


/*Forward the packets matching ACL 10 to 100.1.1.1, with
200.1.1.1 to be the backup egress*/
ZXR10(config-route-map)#match ip address 50
ZXR10(config-route-map)#set ip next-hop 100.1.1.1 200.1.1.1
ZXR10(config-route-map)#exit

ZXR10(config)#route-map source-ip permit 20


/*Forward the packets matching ACL 20 to 200.1.1.1, with
100.1.1.1 to be the standby egress*/
ZXR10(config-route-map)#match ip address 51
ZXR10(config-route-map)#set ip next-hop 200.1.1.1 100.1.1.1

In this instance, two ISP egresses are mutually backup. There are two cases for service
connection:
l
l

When both ISP1 and ISP2 egresses are in normal state, services of users belonging
to 10.10.0.0/24 and 11.11.0.0/24 subnets are forwarded through ISP1 and ISP2;
When one egress is down, services of users in corresponding subnet will be forwarded
through the standby egress. Therefore, the services will not be interrupted as long two
egresses are not down at the same time.

7-7
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

This page intentionally left blank.

7-8
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 8

Load Balancing
Configuration
Table of Contents
Load Balancing Overview...........................................................................................8-1
Configuring Load Balancing........................................................................................8-2
Configuring Load Balancing Maintenance and Diagnosis ...........................................8-3
Load Sharing Configuration Example .........................................................................8-4
Default Load Balancing Configuration Example ..........................................................8-8
Dynamic Load Balancing Configuration Example .....................................................8-14

8.1 Load Balancing Overview


Load sharing is a policy of implementing load balancing on multiple links. Load sharing
can be implemented based on source and destination addresses or based on packet.
l

Load sharing based on source and destination addresses


As for a flow with specific source address and destination address, if there is no
change to load sharing links, the flow will be upsent over a certain load sharing link
through some algorithm.

Load sharing based on single packet


When sending a packet on load sharing link, system will poll the links and select one
load sharing link to send the packet.

Load sharing based on main link


A main link-based load sharing mode is implemented on ZXR10 ZSR to meet market
demands. That is, there is a main link among load sharing links. If traffics on this main
link are less than the set upper threshold, traffics are only delivered over this link. Or
the traffics will be delivered on one idle link among other load sharing links (except for
main link).

The algorithm used to dynamically select main link among load sharing links is:
l
l
l

If load sharing links have different priorities, the link with the highest priority will be
selected as the main link.
If load sharing links have the same priority, the link with the largest bandwidth will be
selected as the main link.
If load sharing links have the same priority and bandwidth, the main link will be
selected at random.
8-1

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

8.2 Configuring Load Balancing


Step

Format

Function

ZXR10(config)#router { rip | bgp < as-number> | ospf < process-id>

Enter route configuration mode.

| isis}
2

ZXR10(config-router)#maximum-paths < number>

Configure protocol to support load


sharing.

ZXR10(config-router)#exit

Exit from route configuration mode.

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZZXR10(config-if)#ip load-sharing { per-destination | per-packet}

Configure load sharing mode on


interface.

ZXR10(config-if)#load-sharing bandwidth < bandwidth>

Configure the bandwidth for dynamic


load sharing on interface (in range
of 1-100000).

ZXR10(config-if)#band-limit < bandwidth>

Configure bandwidth for dynamic


load sharing on interface (only valid
on outgoing interface; the bandwidth
range changes according to different
actual bandwidths on interface).

ZXR10(config-if)#load-sharing priority < 0~7>

Configure priority for dynamic load


sharing on interface.

Exit from interface configuration

ZXR10(config-if)#exit

mode.
10

ZXR10(config)#ip load-sharing dynamic { enable | disable}

Enable or disable dynamic load


sharing function.

In step 6, to configure bandwidth for dynamic load sharing on interface:


Weight of load sharing is calculated according to link bandwidth. After configuring
bandwidth for dynamic load sharing, use the configured bandwidth to select the main
link among load sharing links. Meanwhile, if the link configured with load sharing
bandwidth is occupied by other traffics and the load sharing bandwidth is beyond the
configured one, the link will not participate in load sharing function in actual application.
Dynamic load sharing on different links occupies different bandwidths.

In step 8, to configure priority for dynamic load sharing on interface:


When selecting the main link for dynamic load sharing, the larger the configured value,
the higher the link priority.

8-2
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 8 Load Balancing Configuration

Note:
As for step 6, in case port rate limit is also configured on this link, the smallest value among
physical rate of the interface, port rate limit, and bandwidth of load sharing will be used for
selecting the main link for dynamic load sharing.
As for step 8, if all links in dynamic load sharing have the same priority, the link with the
largest bandwidth will be selected as main link. If load sharing links have the same priority
and bandwidth, the main link will be selected at random.
At present ZXR10 ZSR supports load sharing of BGP, OSPF, IS-IS, RIP and static routes.
Load sharing is configured on outgoing interface It is perdestination by default.
Only when all interfaces are configured to be in per-packet mode, the mode of load sharing
is per-packet.

Example
l

Configure protocol to support load sharing.


For example, the configuration of BGP load sharing is as follows:
R1(config)#router bgp 100
R1(config-router)#maximum-paths 8

Configure load sharing mode on interface.


For example, the configuration of load sharing mode is as follows:
R1(config)#int fei_1/7
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#show running-config interface fei_1/7
Building configuration...
interface fei_1/7
negotiation auto
ip load-sharing per-packet
end

8.3 Configuring Load Balancing Maintenance and


Diagnosis
To configure the maintenance and diagnosis of Load balancing, perform the following step.
Format

Function

ZXR10(diag)#forward ldsh search < index>

View information of load sharing table


8-3

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

8.4 Load Sharing Configuration Example


BGP Load Sharing Example
The following figure shows an example of BGP load sharing configuration.
Figure 8-1 Load Sharing Configuration

As shown in Figure 8-1, there are two 100Mbps links between R1 and R2. Take BGP load
sharing for example and the configurations of two routers are as follows:
Router

Link1

Link2

AS

R1

fei_1/712.0.0.1

fei_1/812.0.1.1

100

R2

fei_1/112.0.0.2

fei_1/212.0.1.2

200

Configuration of R1:
R1(config)#interface fei_1/7
R1(config-if)#ip address 12.0.0.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface fei_1/8
R1(config-if)#ip address 12.0.1.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface gei_0/1
R1(config-if)#ip address 120.1.1.1 255.255.255.0
R1(config-if)#exit
R1(config)#router bgp 100
R1(config-router)#neighbor 12.0.0.2 remote-as 200
R1(config-router)#neighbor 12.0.1.2 remote-as 200
R1(config-router)#network 120.1.1.0 255.255.255.0
R1(config-router)#maximum-paths 8
R1(config-router)#exit

Configuration of R2:
R2(config)#interface fei_1/1
R2(config-if)#ip address 12.0.0.2 255.255.255.0
R2(config-if)# ip load-sharing per-packet
R2(config-if)#exit

8-4
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 8 Load Balancing Configuration


R2(config)#interface fei_1/2
R2(config-if)#ip address 12.0.1.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#exit
R2(config)#interface gei_0/1
R2(config-if)#ip address 120.1.2.2 255.255.255.0
R2(config-if)#exit
R2(config)#router bgp 200
R2(config-router)#neighbor 12.0.0.1 remote-as 100
R2(config-router)#neighbor 12.0.1.1 remote-as 100
R2(config-router)#network 120.1.2.0 255.255.255.0
R2(config-router)#maximum-paths 8

View routes on R1:


R1#show ip route bgp
IPv4 Routing Table:
Dest

Mask

Gw

Interface Owner

pri metric

120.1.2.0 255.255.255.0 12.0.1.2 fei_1/8

bgp

20

120.1.2.0 255.255.255.0 12.0.0.2 fei_1/7

bgp

20

View routes on R2:


R1#show ip route bgp
IPv4 Routing Table:
Dest

Mask

Gw

Interface Owner

pri metric

120.1.1.0 255.255.255.0 12.0.1.1 fei_1/2

bgp

20

120.1.1.0 255.255.255.0 12.0.0.1 fei_1/1

bgp

20

OSPF Load Sharing Example


As shown in Figure 8-1, there are two 100Mbps links between R1 and R2. TakeConsider
OSPF load sharing foras an example and the configurations of two routers are as follows:
Router

Link1

Link2

R1

fei_1/7 12.0.0.1

fei_1/8 12.0.1.1

R2

fei_1/1 12.0.0.2

fei_1/2 12.0.1.2

Configuration of R1:
R1(config)#interface fei_1/7
R1(config-if)#ip address 12.0.0.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface fei_1/8

8-5
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


R1(config-if)#ip address 12.0.1.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface gei_0/1
R1(config-if)#ip address 120.1.1.1 255.255.255.0
R1(config-if)#exit
R1(config)#router ospf 100
R1(config-router)#network 12.0.0.0 0.0.0.255 area 0
R1(config-router)#network 12.0.1.0 0.0.0.255 area 0
R1(config-router)#network 120.1.1.0 0.0.0.255 area 0
R1(config-router)#maximum-paths 8
R1(config-router)#exit

Configuration of R2:
R2(config)#interface fei_1/1
R2(config-if)#ip address 12.0.0.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#exit
R2(config)#interface fei_1/2
R2(config-if)#ip address 12.0.1.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#exit
R2(config)#interface gei_0/1
R2(config-if)#ip address 120.1.2.2 255.255.255.0
R2(config-if)#exit
R2(config)#router ospf 200
R2(config-router)#network 12.0.0.0 0.0.0.255 area 0
R2(config-router)#network 12.0.1.0 0.0.0.255 area 0
R2(config-router)#network 120.1.2.0 0.0.0.255 area 0
R2(config-router)#maximum-paths 8

View routes on R1:


R1#show ip route ospf
IPv4 Routing Table:
Dest

Mask

Gw

Interface Owner

pri metric

120.1.2.0

255.255.255.0

12.0.1.2 fei_1/8

ospf

110

120.1.2.0

255.255.255.0

12.0.0.2 fei_1/7

ospf

110

View routes on R2:


R2#show ip route ospf
IPv4 Routing Table:
Dest

Mask

Gw

Interface Owner

120.1.1.0

255.255.255.0

12.0.1.1 fei_1/2

ospf

pri metric
110

8-6
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 8 Load Balancing Configuration


120.1.1.0

255.255.255.0

12.0.0.1 fei_1/1

ospf

110

IS-IS Load Sharing Example


As shown in Figure 8-1, there are two 100Mbps links between R1 and R2. TakeConsider
IS-IS load sharing for as an example and the configurations of two routers are as follows:
Router

Link1

Link2

R1

fei_1/7 12.0.0.1

fei_1/8 12.0.1.1

R2

fei_1/1 12.0.0.2

fei_1/2 12.0.1.2

Configuration of R1:
R1(config)#router isis
R1(config-router)#area 01
R1(config-router)#system-id 00D0.D0C7.53E0
R1(config-router)#maximum-paths 8
R1(config-router)#exit
R1(config)#interface fei_1/7
R1(config-if)#ip address 12.0.0.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#ip router isis
R1(config-if)#exit
R1(config)#interface fei_1/8
R1(config-if)#ip address 12.0.1.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#ip router isis
R1(config-if)#exit
R1(config)#interface gei_0/1
R1(config-if)#ip address 120.1.1.1 255.255.255.0
R1(config-if)#ip router isis
R1(config-if)#exit

Configuration of R2:
R2(config)#router isis
R2(config-router)#area 01
R2(config-router)#system-id 00D0.D0C7.5460
R2(config-router)#maximum-paths 8
R2(config-router)#exit
R2(config)#interface fei_1/1
R2(config-if)#ip address 12.0.0.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#ip router isis
R2(config-if)#exit

8-7
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


R2(config)#interface fei_1/2
R2(config-if)#ip address 12.0.1.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#ip router isis
R2(config-if)#exit
R2(config)#interface gei_0/1
R2(config-if)#ip address 120.1.2.2 255.255.255.0
R2(configif)#ip router isis
R2(config-if)#exit

View routes on R1:


R1#show ip route isis-l1
IPv4 Routing Table:
Dest

Mask

Gw

Interface Owner

pri metric

120.1.2.0 255.255.255.0 12.0.1.2 fei_1/8

isis-l1 115

20

120.1.2.0 255.255.255.0 12.0.0.2 fei_1/7

isis-l1 115

20

View routes on R2:


R2#show ip route isis-l1
IPv4 Routing Table:
Dest

Mask

Gw

Interface Owner

pri metric

120.1.1.0 255.255.255.0 12.0.1.1 fei_1/2

isis-l1 115

20

120.1.1.0 255.255.255.0 12.0.0.1 fei_1/1

isis-l1 115

20

8.5 Default Load Balancing Configuration Example


Default Static Route Load Sharing Example
As shown in figure, there are two 100Mbps links between R1 and R2. Take load sharing
of default static route for example and the configurations of two routers are as follows.
Router

Link1

Link2

R1

fei_1/7 12.0.0.1

fei_1/8 12.0.1.1

R2

fei_1/1 12.0.0.2

fei_1/2 12.0.1.2

Configuration of R1:
R1(config)#interface fei_1/7
R1(config-if)#ip address 12.0.0.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface fei_1/8
R1(config-if)#ip address 12.0.1.1 255.255.255.0

8-8
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 8 Load Balancing Configuration


R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface gei_0/1
R1(config-if)#ip address 120.1.1.1 255.255.255.0
R1(config-if)#exit
R1(config)#ip route 0.0.0.0 0.0.0.0 12.0.0.2 tag 150
R1(config)#ip route 0.0.0.0 0.0.0.0 12.0.1.2 tag 160

Configuration of R2:
R2(config)#interface fei_1/1
R2(config-if)#ip address 12.0.0.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#exit
R2(config)#interface fei_1/2
R2(config-if)#ip address 12.0.1.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#exit
R2(config)#interface gei_0/1
R2(config-if)#ip address 120.1.2.2 255.255.255.0
R2(config-if)#exit
R2(config)#ip route 0.0.0.0 0.0.0.0 12.0.0.1 tag 150
R2(config)#ip route 0.0.0.0 0.0.0.0 12.0.1.1 tag 160

View routes on R1:


R1#show ip route static
IPv4 Routing Table:
Dest

Mask

Gw

Interface

Owner

pri

metric

0.0.0.0

0.0.0.0

12.0.1.2

fei_1/8

static

0.0.0.0

0.0.0.0

12.0.0.2

fei_1/7

static

View routes on R2:


R1#show ip route static
IPv4 Routing Table:
Dest

Mask

Gw

Interface

Owner

pri

metric

0.0.0.0

0.0.0.0

12.0.1.1

fei_1/2

static

0.0.0.0

0.0.0.0

12.0.0.1

fei_1/1

static

Default OSPF Route Load Sharing Example


As shown in figure, there are two 100Mbps links between R1 and R2. Take OSPF load
sharing for example and the configurations of two routers are as follows.

8-9
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Router

Link1

Link2

R1

fei_1/7, 12.0.0.1

fei_1/8, 12.0.1.1

R2

fei_1/1, 12.0.0.2

fei_1/2, 12.0.1.2

Configuration of R1:
R1(config)#interface fei_1/7
R1(config-if)#ip address 12.0.0.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface fei_1/8
R1(config-if)#ip address 12.0.1.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface gei_0/1
R1(config-if)#ip address 120.1.1.1 255.255.255.0
R1(config-if)#exit
R1(config)#router ospf 100
R1(config-router)#network 12.0.0.0 0.0.0.255 area 1
R1(config-router)#network 12.0.1.0 0.0.0.255 area 1
R1(config-router)#network 120.1.1.0 0.0.0.255 area 1
R1(config-router)#maximum-paths 8
R1(config-router)#area 1 stub
R1(config-router)#exit

Configuration of R2:
R2(config)#interface fei_1/1
R2(config-if)#ip address 12.0.0.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#exit
R2(config)#interface fei_1/2
R2(config-if)#ip address 12.0.1.2 255.255.255.0
R2(config-if)# ip load-sharing per-packet
R2(config-if)#exit
R2(config)#interface gei_0/1
R2(config-if)#ip address 120.1.2.2 255.255.255.0
R2(config-if)#exit
R2(config)#router ospf 200
R2(config-router)#network 12.0.0.0 0.0.0.255 area 1
R2(config-router)#network 12.0.1.0 0.0.0.255 area 1
R2(config-router)#network 120.1.2.0 0.0.0.255 area 1
R2(config-router)#network 12.0.2.0 0.0.0.255 area 0
R2(config-router)#maximum-paths 8
R2(config-router)#area 1 stub no-summary

8-10
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 8 Load Balancing Configuration

View routes on R1:


R1#show ip route ospf
IPv4 Routing Table:
Dest

Mask

Gw

Interface

Owner

pri

metric

0.0.0.0

0.0.0.0

12.0.1.2

fei_1/8

ospf

110

0.0.0.0

0.0.0.0

12.0.0.2

fei_1/7

ospf

110

Default IS-IS Route Load Sharing Example


As shown in Figure 8-2, there are two 100Mbps links between R1 and R2. Take IS-IS load
sharing for example and the configurations of two routers are as follows.
Figure 8-2 Default ISIS Route Load Sharing Configuraiton

Router

Link1

Link2

Link3

R1

fei_1/712.0.0.1

fei_1/812.0.1.1

R2

fei_1/112.0.0.2

fei_1/212.0.1.2

R3

gei_0/1, 12.0.2.2
gei_0/1, 12.0.2.1

Configuration of R1:
R1(config)#router isis
R1(config-router)#area 01
R1(config-router)#system-id 00D0.D0C7.53E0
R1(config-router)#maximum-paths 8
R1(config-router)#is-type level-1
R1(config-router)#exit
R1(config)#interface fei_1/7
R1(config-if)#ip address 12.0.0.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#ip router isis
R1(config-if)#isis circuit-type level-1

8-11
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


R1(config-if)#exit
R1(config)#interface fei_1/8
R1(config-if)#ip address 12.0.1.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#ip router isis
R1(config-if)#isis circuit-type level-1
R1(config-if)#exit
R1(config)#interface gei_0/1
R1(config-if)#ip address 120.1.1.1 255.255.255.0
R1(config-if)#ip router isis
R1(config-if)#isis circuit-type level-1
R1(config-if)#exit

Configuration of R2:
R2(config)#router isis
R2(config-router)#area 01
R2(config-router)#system-id 00D0.D0C7.5460
R2(config-router)#maximum-paths 8
R2(config-router)#exit
R2(config)#interface fei_1/1
R2(config-if)#ip address 12.0.0.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#ip router isis
R2(config-if)#exit
R2(config)#interface fei_1/2
R2(config-if)#ip address 12.0.1.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#ip router isis
R2(config-if)#exit
R2(config)#interface gei_0/1
R2(config-if)#ip address 12.0.2.2 255.255.255.0
R2(config-if)#ip router isis

Configuration of R3:
R3(config)#router isis
R3(config-router)#area 02
R3(config-router)#system-id 00D0.D0C7.5461
R3(config-router)#exit
R3(config)#interface gei_0/1
R3(config-if)#ip address 12.0.2.1 255.255.255.0
R3(config-if)#ip router isis

View routes on R1:


8-12
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 8 Load Balancing Configuration


R1#show ip route isis-l1
IPv4 Routing Table:
Dest

Mask

Gw

Interface

Owner

pri

metric

0.0.0.0

0.0.0.0

12.0.1.2

fei_1/8

isis-l1

115

10

0.0.0.0

0.0.0.0

12.0.0.2

fei_1/7

isis-l1

115

10

Default BGP Route Load Sharing Example


As shown in figure, there are two gigabit/100Mbps links between R1 and R2. Both R1
and R2 are interconnected with tester through Pos48 interface. Take BGP load sharing for
example and the configurations of two routers are as follows.
Router

Link1

Link2

AS

R1

fei_1/712.0.0.1

fei_1/812.0.1.1

100

R2

fei_1/112.0.0.2

fei_1/212.0.1.2

200

Configuration of R1:
R1(config)#interface fei_1/7
R1(config-if)#ip address 12.0.0.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface fei_1/8
R1(config-if)#ip address 12.0.1.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface gei_0/1
R1(config-if)#ip address 120.1.1.1 255.255.255.0
R1(config-if)#exit
R1(config)#router bgp 100
R1(config-router)#neighbor 12.0.0.2 remote-as 200
R1(config-router)#neighbor 12.0.1.2 remote-as 200
R1(config-router)#network 120.1.1.0 255.255.255.0
R1(config-router)#maximum-paths 8

Configuration of R2:
R2(config)#interface fei_1/1
R2(config-if)#ip address 12.0.0.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#exit
R2(config)#interface fei_1/2
R2(config-if)#ip address 12.0.1.2 255.255.255.0
R2(config-if)#ip load-sharing per-packet
R2(config-if)#exit

8-13
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


R2(config)#interface gei_0/1
R2(config-if)#ip address 120.1.2.2 255.255.255.0
R2(config-if)#exit
R2(config)#router bgp 200
R2(config-router)#neighbor 12.0.0.1 remote-as 100
R2(config-router)#neighbor 12.0.0.1 default-originate
R2(config-router)#neighbor 12.0.1.1 remote-as 100
R2(config-router)#neighbor 12.0.1.1 default-originate
R2(config-router)#network 120.1.2.0 255.255.255.0
R2(config-router)#maximum-paths 8

View routes on R1:


R1#show ip route bgp
IPv4 Routing Table:
Dest

Mask

Gw

Interface

Owner

pri

metric

0.0.0.0

0.0.0.0

12.0.1.2

fei_1/8

bgp

20

0.0.0.0

0.0.0.0

12.0.0.2

fei_1/7

bgp

20

8.6 Dynamic Load Balancing Configuration Example


As shown in Figure 8-3, R1 is interconnected with R2 through three links (such as link 1,
link 2 and link 3) with all bandwidths to be 2M. Load sharing is enabled on all three links.
Special data flow are designated to be forwarded over link 3 (static route is configured in
this case and policy routing can also be used to specify link; both have the same function)
and common data flow are forwarded over link 1, link 2 and link 3 through load sharing.
The difference lies in that bandwidth load sharing command is configured on link 3, which
enables link 3 to not forward traffics in load sharing when bandwidth of link 3 reaches or
exceeds 1M.
Figure 8-3 Dynamic Load Sharing Configuration

Take OSPF load sharing for example and the configurations of two routers are as follows:
Router

Link1

Link2

Link3

Common Data Flow

Voice Data Flow

R1

CE1_1/1.1

CE1_1/2.1

CE1_1/3.1

fei_8/1, destination address:

fei_7/1, destination

13.1.1.2/24

address: 14.1.1.2/24

fei_8/1, destination address:

fei_7/1, destination

13.1.1.2/24

address: 14.1.1.2/24

R2

CE1_1/1.1

CE1_1/2.1

CE1_1/3.1

8-14
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 8 Load Balancing Configuration

Configuration of R1:
R1(config)#interface ce1_1/1.1
R1(config-if)#ip address 12.0.1.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface ce1_1/2.1
R1(config-if)#ip address 12.0.2.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#exit
R1(config)#interface ce1_1/3.1
R1(config-if)#ip address 12.0.3.1 255.255.255.0
R1(config-if)#ip load-sharing per-packet
R1(config-if)#load-sharing bandwidth 1000
R1(config-if)#exit
R1(config)#interface fei_7/1
R1(config-if)#ip address 120.1.1.1 255.255.255.0
R1(config-if)#exit
R1(config)#interface fei_8/1
R1(config-if)#ip address 120.1.2.1 255.255.255.0
R1(config-if)#exit
R1(config)#router ospf 100
R1(config-router)#network 12.0.1.0 0.0.0.255 area 0
R1(config-router)#network 12.0.2.0 0.0.0.255 area 0
R1(config-router)#network 12.0.3.0 0.0.0.255 area 0
R1(config-router)#network 120.1.2.0 0.0.0.255 area 0
R1(config-router)#maximum-paths 8
R1(config-router)#exit
R1(config)#ip route 14.1.1.0 255.255.255.0 12.0.3.2
R1(config)#ip load-sharing dynamic enable

Configuration of R2:
R2(config)#interface ce1_1/1.1
R2(config-if)#ip address 12.0.1.2 255.255.255.0
R2(config-if)#exit
R2(config)#interface ce1_1/2.1
R2(config-if)#ip address 12.0.2.2 255.255.255.0
R2(config-if)#exit
R2(config)#interface ce1_1/3.1
R2(config-if)#ip address 12.0.3.2 255.255.255.0
R2(config-if)#exit
R2(config)#interface fei_7/1
R2(config-if)#ip address 120.1.1.2 255.255.255.0
R2(config-if)#exit
R2(config)# interface fei_8/1

8-15
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


R2(config-if)#ip address 120.1.2.2 255.255.255.0
R2(config-if)#exit
R2(config)#router ospf 100
R2(config-router)#network 12.0.1.0 0.0.0.255 area 0
R2(config-router)#network 12.0.2.0 0.0.0.255 area 0
R2(config-router)#network 12.0.3.0 0.0.0.255 area 0
R2(config-router)#network 13.1.1.0 0.0.0.255 area 0
R2(config-router)#network 14.1.1.0 0.0.0.255 area 0
R2(config-router)#exit

View routes on R1:


R1#show ip route
IPv4 Routing Table:
Dest

Mask

13.1.1.0
13.1.1.0

Gw

Interface

Owner

pri metric

255.255.255.0 12.0.1.2

ce1_1/1.1

ospf

110

255.255.255.0 12.0.2.2

ce1_1/2.1

ospf

110

13.1.1.0

255.255.255.0 12.0.3.2

ce1_1/3.1

ospf

110

14.1.1.0

255.255.255.0 12.0.3.2

ce1_1/3.1

static 1

Firstly forward special data flow and common data flow at the same time and keep the
bandwidth for special data flow not more than 1M. Now link 3 is not only used to forward all
packets of special data flow but also forward partial packets of common data flow. Increase
the bandwidth for special data flow to 1M. Now link 3 only forward all packets of special
data flow and not forward partial packets of common data flow any more. With increasing
of traffics, the state maintains. When the bandwidth occupied by special data flow falls to
less than 1M, link 3 will detect the bandwidth occupation change dynamically and then it
again forwards partial packets of common data flow.

8-16
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9

Multicast Routing
Configuration
Table of Contents
Multicast Overview .....................................................................................................9-1
Enabling IP Multicast..................................................................................................9-6
Configuring IGMP.......................................................................................................9-6
Configuring Static Multicast ........................................................................................9-8
Configuring PIM-SM ...................................................................................................9-8
Configuring MSDP....................................................................................................9-11
Configuring Multicast Maintenance and Diagnosis....................................................9-13
Multicast Configuration Example ..............................................................................9-17

9.1 Multicast Overview


Multicast is a point-to-multipoint or multipoint-to-multipoint communication mode. That is,
multiple receivers receive the same data sent from the same one source at the same
time. Multicast-based applications include video conference, remote education, software
version release and so on.
Multicast protocols include IGMP and multicast routing protocol. IGMP is used to manage
joining and leaving of multicast group members and multicast routing protocol is used to
exchange packets between routers to set up multicast tree. Multicast routing protocols
include two types: PIM-SM and MSDP.
The supported protocols are as follows:
l
l
l

Internet Group Management Protocol (IGMP)


Protocol Independent Multicast Sparse Mode (PIM-SM)
Multicast Source Discovery Protocol (MSDP)

9.1.1 Multicast Address


In a multicast network, a sender multicasts a packet to multiple receivers. Sender
is called ad multicast source. Multiple receiver of this packet can identify this packet
with the same ID, which is called multicast group address. In IP address assignment
plan, class D addresses 224.0.0.0~239.255.255.255 are multicast addresses, where
224.0.0.0~224.0.0.255 and 239.0.0.0~239.255.255.255 are used for research and
management.

9-1
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

9.1.2 IGMP
When a host wants to receive the multicast packet sent to a specific group, it needs to
listen to all packets sent to that specific group. To solve the problem of selecting route for
multicast packets, host needs to notify multicast routers in other sub-nets to join or leave
one group.
In multicast, Internet Group Management Protocol (IGMP) is used to accomplish this task.
Thus multicast router can learn multicast group members in network and thus decides
whether to forward multicast packets to the subnets where these members locate. When
one multicast router receives one multicast packet, it checks the multicast destination
address of the packet. Only when a group member is found on this interface, the router
will forward the packet.
IGMP provides information needed at the last stage of forwarding a multicast packet to
the destination. Multicast router exchanges information with the host that receives the
multicast packet. These information is collected from group members of host that is directly
connected to the multicast router.
IGMP is used by multicast router to learn the information of multicast group members.
Two types of packets are used for IGMP: group member query packet and group member
report packet.
Multicast router sends group member query packet to all hosts regularly to learn group
members in connected sub-nets. Each host returns a group member report packet to
report the multicast group that it belongs to. When one host joins in a new group, it sends a
join packet immediately rather than wait for the next query to prevent to be the first member
of that group.
When the host begins to receive packets as the member of a group, multicast router will
send query packets to this group periodically to query if the group members are still there.
As long there is on host in the group, multicast router will continue to forward packets.
When the host leaves the group, multicast router will receive one leave message. Then
multicast router will immediately query if there is still any active member in the group. If
active member is available, multicast router will continue to forward the packet, or stop
forwarding it.
In actual applications, two IGMP versions are available: IGMP V1 and IGMP V2.
Compared with IGMP V1, IGMP V2 has some improved characteristics. In IGMPV2, four
main types of packets are used to exchange packets between host and router:
l
l
l
l

Group member query


V2 member report
Leave report
V1 member report

Here V1 member report is used to be compatible with IGMP V1.

9-2
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration

9.1.3 Multicast Tree


In TCP/IP network, to realize multicast communication, multicast source, receiver and the
path that multicast packets are passing through are premise. The most common routing
method is constructing routing tree, since it has two advantages:
l
l

Packets are paralleled to different receivers along the tree branches;


Packets are duplicated at the cross to reduce the number of packets delivered in network to the least.

Multicast tree is a collection of incoming interfaces and outgoing interfaces of a series of


routers. It specifies unique forwarding routes between the subnet where multicast source
locates and subnets that all group members belong to.
There are two basic ways to construct multicast tree: source-based multicast tree and
shared multicast tree.
l

Source-based multicast tree


Source-based multicast tree is also called source shortest path tree (SPT). It
constructs a spanning tree between each source and all receivers. The tree takes
the subnet where source locates as the root node and expands to the subnets where
receivers locate. There can be multiple multicast sources in one multicast group. We
can say that for each source, there is one multicast tree corresponding to each pair
of (S,G).
The way to construct source-based multicast tree is Reverse Path Forwarding (RPF).
Each router can find the shortest path to source and corresponding outgoing interface
through the unicast route. When one router receives a multicast packet, it will check
if the incoming interface of this packet is the outgoing interface of the shortest unicast
route to source. If so, the router will duplicate and forward the packet to the other
interfaces; if not, this multicast packet will be dropped.
The incoming interface for router to receive the multicast packet is called upstream
interface and the outgoing interface used to send multicast packet is called
downstream interface.

Shared multicast tree


Shared multicast tree constructs a multicast routing tree for each multicast group. The
multicast route tree is shared by all members of this group, that is (*,G) shares one
shared multicast tree instead of constructing one tree for each pair of (S,G). Each
device that wants to receive multicast packet of this group must join the shared tree
in explicit mode.
Shared multicast tree uses one or a set of routers as the core of this multicast tree.
To send multicast packets to receiver, all multicast sources of this group unicast the
packets to the core which then multicasts the packets along shared multicast tree.

9-3
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

9.1.4 Multicast Routing Protocol


Multicast routing protocols are used to exchange information between routers to construct
multicast tree. Different multicast routing protocols use different ways to exchange
packets. To match distribution of multicast users in network, multicast routing protocols
are classified into two types: dense mode and sparse mode.

Dense Mode
The premise of dense mode multicast routing protocol is dense distribution of multicast
users in network and redundant bandwidth. Dense mode multicast routing protocol
constructs and maintains multicast tree by flooding multicast packets over the whole
network periodically. That is the routers running with multicast routing protocol firstly flood
received multicast packets to all the other interfaces.
Dense Mode Multicast Routing Protocol includes:
l
l
l

Distance Vector Multicast Routing Protocol (DVMRP)


Multicast Open Shortest Path First (MOSPF)
Protocol Independent Multicast Dense Mode (PIM-DM)

Pruning Defining
When the neighboring router of an interface reports that a group doesnt exist, the
interface will be deleted from multlicast tree of this group, which is called pruning. When
the neighboring router reports that a receiver of this group occurs again, the interface will
be added to multicast tree of this group accordingly, which is called graft.

Sparse Mode
Sparse mode multicast routing protocol is applicable to the sparse distribution of multicast
receivers in network. In this case, its a great waste to construct multicast routing tree by
flooding packets as dense mode does. In sparse mode, to receive multicast packets, the
network device needs to apply to join a multicast routing tree firstly.
Sparse Mode Multicast Routing Protocol includes:
l
l

Core-Based Trees (CBT)


Protocol Independent Multicast Sparse Mode (PIM-SM)
ZXR10 ZSR supports PIM-SM.

9.1.5 PIM-SM
PIM-SM transmits multicast packets through shared multicast tree. There is one core in
one shared multicast tree to send packets to all source packet senders in one multicast
group. Each source packet sender sends packets to the core along the shortest path and
then take the core as the root node to distribute the packets to each receiver in the group
along the shortest path.

9-4
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration

The group core of PIM-SM is called Rendezvous Point (RP). There can be multiple RPs
in one network but there can be only one RP in one multicast group.
A router can obtain RP location by three methods:
l
l
l

Configure static RP manually on each router running with PIM-SM.


PIM-SM V1 obtains the location dynamically through Auto-RP.
PIM-SM V2 obtains the location dynamically through candidate-RP, where the
candidate-RP with the highest priority will be selected as the formal RP.

PIM-SM V2 manually configures some routers running with PIM-SM as candidate


(BootStrap Router) BSR and elects the candidate-BSR with the highest priority as the
formal BSR.
BSR is used to collect the information of candidate RP of each multicast router to find
what candidate RPs are available in the multicast domain and to advertise them to all PIM
routers in PIM domain. Each PIM router elects the candidate-RP with the highest priority
as the formal RP according to the same hash rules. Candidate RP is configured manually.
The routers running with PIM-SM discover each other and maintain neighborhood by
exchanging hello packets. In mutli-access network, hello packet also contains the
information of router priority, which is used to elect DR.
Multicast source or the first hop router (DR that is directly connected with the multicast
source) encapsulates the packet into a register message and unicasts it to RP. After RP
receives this register message, de-encapsulates the message, takes out the packet, and
sends the packet to the downstream receiver of the group along shared multicast tree.
Each host acting as the receiver will join multicast group through IGMP member report
message. The last hop router (or DP in multi-access network) sends the received join
message to RP for registration hop by hop. After receiving the join message, intermediate
router checks if the route of this group is available. If so, join the downstream request
router to shared multicast tree as a branch; if not, it continues to send the join message to
RP.
When receiver is directly connected to RP or multicast router, the forwarding path can be
switched to source-based shortest path tree from shared multicast tree. When receiving
one register message sent from a new multicast source, RP returns a join message to DR
that is directly connected to multicast source, thus constructing a shortest path tree from
source to RP.
After DR or the router that is directly connected with multicast members receives the first
multicast packet sent from the multicast group, or after the number of the received packets
reaches threshold, the forwarding path can be forwarded to source-based shortest path
tree from shared multicast tree. Once switchover occurs, router will send a pruning
message to the upstream neighbor to request leaving from shared multicast tree.

9-5
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

9.1.6 MSDP
Multicast Source Discovery Protocol (MSDP): This mechanism is used to connect multiple
PIM-SM domains. It is based on TCP and provides the information of multicast sources
out of PIM domain for PIM-SM.

9.2 Enabling IP Multicast


To enable IP multicast, perform the following step.
Format

Function

ZXR10(config)#ip multicast-routing

This enables multicast protocol.

9.3 Configuring IGMP


IGMP function of ZXR10 ZSR is based on PIM interface, so IGMP function is enabled
automatically on all interfaces enabled with PIM. // Check this topic.

9.3.1 Configuring IGMP Version


Currently IGMP has two versions: IGMP V1 and IGMP V2. V2 is the default version. To
select a proper version , execute the following commands.
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter into interface configuration


mode

ZXR10(config-if)#ip igmp version < version>

Configure IGMP version number on


the interface

Note:
Taking security into account, router requires that all NEs in one network segment to have
the same version, IGMP V1 or IGMP V2.
The configuration of IGMP version is based on interface. Different versions can be
configured for different interfaces.

9.3.2 Configuring IGMP Group on Interface


To configure IGMP group on interface, perform the following steps.

9-6
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration

Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip igmp access-group < access-list-number>

Configure the group range allowing


IGMP to join in.

ZXR10(config-if)#ip igmp static-group < group-address>

Configure static group member on


interface.

ZXR10(config-if)#ip igmp immediate-leave [ group-list <

Configure the group range allowing

access-list-number> ]

IGMP to leave immediately.

Example
l

Configure the group range allowing IGMP to join in.


When enabling IGMP on the interface, it is default to receive all multicast groups. Set
the group range allowing packets to be received. When join request sent from a host
doesnt belong to this range, the request packet will be dropped.
This example shows the configuration of an interface, on which only group
239.10.10.10 permitted by ACL 10 can be received.
ZXR10(config)#ip access-list standard 10
ZXR10(config-std-acl)#permit 239.10.10.10 0.0.0.0
ZXR10(config-std-acl)#exit
ZXR10(config)#int fei_1/1
ZXR10(config-if)#ip igmp access-group 10

Configure static group member on interface.


Statically bind group address to the interface. Namely, it is supposed that member of
this group is always available on this interface.
This example shows how to configure static group 239.10.10.10 on the interface.
ZXR10(config)#int fei_1/1
ZXR10(config-if)#ip igmp static-group 239.10.10.10

9.3.3 Configuring IGMP Timer


After enabling IGMP on the multicast router interface which is connected with shared
network segment, select the optimum one as the querier of this network segment to send
query messages to obtain the information of group members.
After sending query message, querier will wait for the member report sent from the host
that receives the query message for a period. The wait duration is the max response time
carried in query message. The default value is 10 seconds.
After receiving query message, host member in the network segment will reduce a random
deviation value based on the max response time. This result will be used as the response
9-7
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

time. During this period, if the report of another host member is received, cancel the
previous report; if not, send the host report as setting. Therefore, prolonging the max
response time will increase the waiting changes of group member in the network segment
accordingly and decrease the burst rate of multiple host reports in the network segment.
Parameters of querier-related timers can be adjusted properly according to actual network
conditions.
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip igmp query-interval < seconds>

Configure IGMP query interval.

ZXR10(config-if)#ip igmp query-max-response-time < seconds>

Configure the value of max response


time carried in query message sent
by IGMP.

ZXR10(config-if)#ip igmp querier-timeout < seconds>

Configure timeout of IGMP querier.

ZXR10(config-if)#ip igmp last-member-query-interval < seconds>

Configure query interval of a specific


IGMP group.

9.4 Configuring Static Multicast


To establish static multicast route, execute the following command.
Format

Function

ZXR10(config)#ip mroute < ip address> < net-mask> < rpf address>

This establishes static multicast route.

9.5 Configuring PIM-SM


9.5.1 Enabling PIM-SM
To enable PIM-SM, perform the following steps
Step

Format

Function

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip pim sm

Add an interface running with


PIM-SM.

Exit from interface configuration

ZXR10(config-if)#exit

mode.
4

ZXR10(config)#router pimsm

Enable PIM-SM.

ZXR10(config-router)#static-rp < ip-address> [ group-list <

Configure static RP.

access-list-number> ] [ priority < priority> ]


9-8
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration

Step

Format

Function

ZXR10(config-router)#bsr-candidate < interface-name> [ <

Configure candidate BSR.

hash-mask-length> ] [ < priority> ]


7

ZXR10(config-router)#rp-candidate < interface-name> [ group-list

Configure candidate RP.

< access-list-number> ] [ priority < priority> ]

Command Illustration:
1. Step 1: Configuring static RP
A static RP can be configured for one or more particular groups. And meanwhile static
RP must be configured on all PIM-SM multicast routers in the multicast domain for
this/these groups.
RP address must be reachable for other routers. Loopback interface address is often
used to reduce network flapping caused by up/down of physical interface. After static
RP is configure, it doesnt need to configure candidate RP for this group.
2. Step 2: Configuring candidate BSR
If static RP mechanism doesnt apply here, backup BSR must be configured on more
than one multicast router for each multicast domain and elect one BSR meanwhile.
BSR periodically sends bootstrap message to advertise RP information. PIM-SM
router updates RP state according to the latest advertisement message. Bootstrap
message sent by BSR is also used to elect the formal BSR from the candidate BSRs.
The default priority of candidate BSR is 0. The candidate BSR with the highest priority
will be elected as the formal BSR. In case multiple routers has the same BSR priority,
compare their IP addresses. The candidate BSR with the largest IP address will be
elected as the formal BSR.
3. Step 5: Configuring candidate RP
In PIM-SM, RP is the root of shared multicast tree. It is used to send multicast packets
to downstream receiver member of the group along shared multicast tree. There can
be only one formal RP in each one multicast group.
The default priority of candidate RP is 0. The larger the priority value, the higher the
priority of candidate RP.

Example
l

Configure static RP 10.1.1.1 for all groups.


ZXR10(config-router)#static-rp 10.1.1.1

Configure static RP 10.1.1.1 for multicast group 239.132.10.100 that is permitted by


ACL 10.
ZXR10(config-router)#static-rp 10.1.1.1 group-list 10
ZXR10(config-router)#exit
ZXR10(config)#ip access-list standard 10
ZXR10(config-std-acl)#permit 239.132.10.100 0.0.0.0

9-9
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

9.5.2 Configuring PIM-SM Parameters


When PIM-SM is running, different parameters have different default values. These
parameters can be set to optimize network.
Step

Format

Function

ZXR10(config)#router pimsm

Enter route configuration mode.

ZXR10(config-if)#spt-threshold infinity [ group-list <

Switch to source shortest path tree.

access-list-number> ]
3

ZXR10(config-if)#packet-count { begin | end}

Enable/disable the function of


counting upsent multicast packets.

ZXR10(config)#exit

Exit from route configuration mode.

ZXR10(config-router)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-router)#ip pim dr-priority < priority>

Set DR priority.

ZXR10(config-router)#ip pim bsr-border

Configure the interface to be PIM


domain border.

ZXR10(config-if)#ip pim query-interval < seconds>

Set the interval of sending hello


packets (30 seconds by default).

ZXR10(config-if)#ip pim neighbor-filter < access-list-number>

Limit PIM-SM neighbors.

In step 2, only the last DR and RP can switch to source shortest path tree actively.
By default, the switchover starts immediately when RP receives the first register
message. As for the last hop DR, configure the policy of setting source shortest path
tree swithover threshold with the single multicast group as the control granularity. If
the switchover threshold of a group is configured to infinite, switchover doesnt occur
and it is default to conduct switchover as long as traffics are available.
In step 6, it is necessary to select one DR in a shared (or multi-access) network
segment. The router with the highest priority will be selected as the DR. In case
multiple routers have the same priority, the router with the largest IP address will be
selected as DR.
In the shared network segment connected with multicast source, only DR can send
register message to RP; in the shared network segment connected with source, only
DR can response to IGMP join/leave message and send PIM join/pruning message
to upstream router.
The priority of router is contained in hello packet exchanged with neighbors. The
default value is 0.

Example
On the interface, forbid routers denied by ACL 10 to be PIM neighbor.
9-10
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration


ZXR10(config)#ip access-list standard 10
ZXR10(config-std-acl)#deny 10.1.1.1 0.0.0.0
ZXR10(config-std-acl)#exit
ZXR10(config)#interface fei_1/1
ZXR10(config-if)#ip pim neighbor-filter 10

9.5.3 Configuring PIM-SM Policy Control


To configure PIM-SM policy control, perform the following steps.
Step

Format

Function

ZXR10(config)#router pimsm

Enter route configuration mode.

ZXR10(config-router)#accept-register < access-list-number>

Filter the multicast packet


encapsulated in received register
message.

ZXR10(config-router)#accept-rp < access-list-number>

Filter the address of candidate RP


advertised in BSR message.

ZXR10(config-router)#exit

Exit from route configuration mode.

ZXR10(config)#interface < interface-name>

Enter interface configuration mode.

ZXR10(config-if)#ip pim neighbor-filter < access-list-number>

Limit PIM-SM neighbors.

Example
On the interface, forbid routers denied by ACL 10 to be PIM neighbor.
ZXR10(config)#ip access-list standard 10
ZXR10(config-std-acl)#deny 10.1.1.1 0.0.0.0
ZXR10(config-std-acl)#exit
ZXR10(config)#interface fei_1/1
ZXR10(config-if)#ip pim neighbor-filter 10

9.6 Configuring MSDP


9.6.1 Enabling MSDP
To enable MSDP, perform the following steps.
Step
1

Format

Function

ZXR10(config)#ip msdp peer < peer-address> connect-source <

This enables MSDP PEER and

interface-name>

configures one MSDP neighbor

9-11
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Step

Format

Function

ZXR10(config)#ip msdp default-peer < peer-address> [ list <

This enables MSDP DEFAULT-

acl-number> ]

PEER and define one default MSDP


neighbor

9.6.2 Configuring Extended MSDP


To configure extended MSDP, execute the following commands.
Step

Format

Function

ZXR10(config)#ip msdp description < peer-address> < desc-text>

Add description to MSDP neighbor.

ZXR10(config)#ip msdp originator-id < interface-name>

Use IP address of the designated


interface as RP address contained
in SA message.

ZXR10(config)#ip msdp sa-limit < peer-ad-dress> < sa-limit>

Limit the number of SA messages in


SA cache and sent from designated
MSDP neighbor.

ZXR10(config)#ip msdp ttl-threshold < peer-address> < ttl-value>

Limit the scope of MSDP neighbor, to


which multicast packet encapsulated
in SA packet is sent.

9.6.3 Configuring MSDP Policy


To configure MSDP policy, perform the following steps.
Step

Format

Function

ZXR10(config)#ip msdp redistribute [ list < acl-number> ]

Limit generation of SA message.

ZXR10(config)#ip msdp sa-filter in < peer-address> [ list <

Filter the SA message sent from a

acl-number> ]

designated MSDP neighbor.

ZXR10(config)#ip msdp sa-filter out < peer-address> [ list <

Filter the SA message sent to a

acl-number> ]

designated MSDP neighbor.

9.6.4 Clearing MSDP Status


To clear MSDP status, perform the following steps.
Step

Format

Function

ZXR10#clear ip msdp peer [ < peer-address> ]

This clears TCP connections


established with all or designated
MSDP neighbor
9-12

SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration

Step

Format

Function

ZXR10#clear ip msdp sa-cache [ < group-address> ]

This clears MSDP SA cache

ZXR10#clear ip msdp statistics [ < peer-address> ]

This clears statistics of an MSDP


neighbor

9.7 Configuring Multicast Maintenance and Diagnosis


9.7.1 Configuring Public Multicast Maintenance and Diagnosis
To configure public multicast maintenance and diagnosis, execute the following
commands.
Format

Function

ZXR10#show ip mroute [ group < group-address> ] [ source <

Show multicast routing table (it can be

source-address> ] [ summary]

used in all modes).

ZXR10#show ip forwarding mroute group-address < group-address> [

Show multicast forwarding table (it can

source-address < source-address> ]

be used in all modes except for user


mode).

ZXR10#show ip rpf < source-address>

Show RPF information (it can be used


in all modes).

ZXR10#clear ip mroute [ group-address < group-address> ]

Clear multicast routes.

9.7.2 Configuring IGMP Maintenance and Diagnosis


To configure IGMP maintenance and diagnosis, perform the following commands.
Format

Function

ZXR10#show ip igmp interface [ < interface-name> ]

Show IGMP information on the


interface.

ZXR10#show ip igmp groups [ < interface-name> ]

Show IGMP group joining on the


interface.

ZXR10#show ip rpf < source-address>

Provide the detail of this command.

Example
l

Show IGMP information on interface fei_1/1:


ZXR10#show ip igmp interface fei_1/1
fei_1/1
Internet address is 131.1.1.45, subnet mask is 255.255.255.0

9-13
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


IGMP is enabled on interface
Current IGMP version is 2
IGMP query interval is 125 seconds
IGMP last member query interval is 1 seconds
IGMP query max response time is 10 seconds
IGMP querier timeout period is 251 seconds
IGMP querier is 131.1.1.45, never expire
Inbound IGMP access group is not set
IGMP immediate leave control is not set

Show group memebers on interface fei_1/1:


ZXR10#show ip igmp groups fei_3/1
IGMP Connected Group Membership
Group addr

Interface

Present

Expire

Last Reporter

233.1.1.4

fei_3/1

01:07:49

never

30.1.1.43

233.1.1.147

fei_3/1

01:07:49

00:03:05

30.1.1.42

233.1.4.21

fei_3/1

01:07:49

00:03:05

30.1.1.42

9.7.3 Configuring PIM-SM Maintenance and Diagnosis


ZXR10 ZSR provides some commands to show PIM-SM state. The common commands
are as follows (they can be used in all modes).
Format

Function

ZXR10#show ip mroute [ group < group-address> ] [ source <

Show multicast route.

source-address> ] [ summary]
ZXR10#show ip pimsm interface [ < interface-name> ]

Show PIM-SM interface information.

ZXR10#show ip pimsm neighbor [ < interface-name> ]

Show PIM-SM neighbor information.

ZXR10#show ip pim bsr

Show BSR information.

ZXR10#show ip pim rp mapping

Show RP set information advertised by


BSR.

Example
l

This example shows the content of current IP multicast routing table.


ZXR10#show ip mrout
IP Multicast Routing Table
Flags:D -Dense,S -Sparse,C -Connected,L -Local,P -Pruned
R -RP-bit set,F -Register flag,T -SPT-bit set,J -Join SPT
U -Up Send,N -No Used,X -Proxy Join Timer Running
* -Assert flag

9-14
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration


Timers:Uptime/Expires
Interface state:Interface,Next-Hop or VCD,State/Mode

(*, 233.1.1.3),00:00:41/00:02:49,RP 43.43.43.43 ,0/0,flags:S


Incoming interface: tunnel22, RPF nbr 22.22.22.43
Outgoing interface list:
pos3_5/1, Forward/Sparse, 00:00:41/00:02:49

(*, 233.1.1.4),00:13:52/00:03:30,RP 43.43.43.43 ,1/1,flags:SC


Incoming interface: tunnel22, RPF nbr 22.22.22.43
Outgoing interface list:
fei_3/1, Forward/Sparse, 00:13:52/00:03:30 C

(*, 233.1.1.5),00:00:28/00:03:02,RP 43.43.43.43 ,0/0,flags:SC


Incoming interface: tunnel22, RPF nbr 22.22.22.43
Outgoing interface list:
fei_3/1, Forward/Sparse, 00:00:28/00:03:02 C
(*, 233.1.1.6),00:00:28/00:03:02,RP 43.43.43.43 ,0/0,flags:SC
Incoming interface: tunnel22, RPF nbr 22.22.22.43
Outgoing interface list:
fei_3/1, Forward/Sparse, 00:00:28/00:03:02 C

This example shows the configuration information of PIM-SIM interface.


ZXR10#show ip pimsm interface
Address

Interface

state Nbr Query

DR

DR

Count Intvl

Prior

131.1.1.45

pos3_5/1

Up

30

131.1.1.91

30.1.1.43

fei_3/1

Up

30

30.1.1.43

22.22.22.45

tunnel22

Up

30

22.22.22.45

This example shows neighbor information of PIM-SM interface.


ZXR10#show ip pimsm neighbor

Neighbor Address

Interface

DR Prio

Uptime

Expires

131.1.1.91

pos3_5/1

30000

00:19:34

00:01:29

22.22.22.43

tunnel22

03:21:25

00:01:16

This example shows BSR information.


ZXR10#show ip pim bsr
PIMSM Bootstrap information
BSR address: 131.1.1.45(?)--Uptime: 00:01:06, BSR Priority :200, Hash mask length:30
Expires:00:00:55

9-15
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)


This system is a candidate BSR
candidate BSR address: 131.1.1.45, priority: 200,
hash mask length:30
This System is Candidate_RP:
candidate RP address: 55.1.1.45(fei_3/1),priority:100,
Group acl:1
candidate RP address: 43.43.43.43(static),priority:0

This example shows RP set information advertised by BSR.


ZXR10#show ip pim rp mapping
Group

RP

uptime

expires

226.1.0.0

17.93.8.3

01:24:57

00:00:49

226.4.0.0

17.93.8.3

01:24:57

00:00:49

9.7.4 Configuring MSDP Maintenance and Diagnosis


To configure MSDP maintenance and diagnosis, perform the following commands.
Format

Function

ZXR10#show ip msdp peer [ < peer-address> ]

Show details of an MSDP neighbor (it


can be used in all modes).

ZXR10#show ip msdp sa-cache [ < group-address> [ < source-address> ] ]

Show (S,G) states of MSDP neighbors


(it can be used in all modes).

ZXR10#debug ip msdp message-recv

Show messages received by MSDP.

ZXR10#debug ip msdp

Show all information about MSDP.

Example
l

This example shows detailed information of an MSDP neighbor:


ZXR10#show ip msdp peer
MSDP Peer 55.1.1.42
Description:
Connection status:
State: Up, Resets: 0, Connection source: fei_1/5 (55.1.1.41)
Uptime(Downtime): 00:20:07, Messages sent/received: 21/21
Connection and counters cleared 00:24:09 ago
SA Filtering:
Input (S,G) filter: none
Output (S,G) filter: none
Peer ttl threshold: 0
SAs learned from this peer: 0

9-16
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration

This example shows (S,G) states of MSDP neighbors.


ZXR10#show ip msdp sa-cache
MSDP Source-Active Cache - 4 entries
(101.101.101.101, 224.1.1.1), RP 49.4.4.4, 00:21:45/ 00:05:57
(101.101.101.101, 224.1.1.2), RP 49.4.4.4, 00:21:45/ 00:05:57
(101.101.101.101, 226.1.1.1), RP 50.4.4.4, 00:09:04/ 00:04:57
(101.101.101.101, 226.1.1.2), RP 50.4.4.4, 00:09:04/ 00:04:57

This example shows messages received by MSDP.


ZXR10# debug ip msdp message-recv
MSDP: 105.2.2.2: Received 56-byte msg 2372 from peer
MSDP: 105.2.2.2: SA TLV, len: 56, ec: 4, RP: 103.4.4.4
MSDP: 105.2.2.2: Peer RPF check failed for 103.4.4.4, we are RP

This example shows all information about MSDP.


ZXR10# debug ip msdp
MSDP: Session to peer 102.2.2.2 going down
MSDP: 102.2.2.2: Peer reset, own IP address is changed
MSDP: Session to peer 142.3.3.3 going down
MSDP: 142.3.3.3: Peer reset, other side down
MSDP: 105.2.2.2: Received 56-byte msg 2372 from peer
MSDP: 105.2.2.2: SA TLV, len: 56, ec: 4, RP: 103.4.4.4
MSDP: 105.2.2.2: Peer RPF check failed for 103.4.4.4,we are RP

9.7.5 Configuring Static Multicast Maintenance and Diagnosis


To configure maintenance and diagnosis of static multicast, use the following command:
Format

Function

ZXR10#show ip route multicast

Show configured static multicast routing


information

9.8 Multicast Configuration Example


9.8.1 PIM-SM Configuration Example
A PIM-SM configuration instance is given in network topology as shown in Figure 9-1.

9-17
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Figure 9-1 Multicast Configuration

Configuration of R1:
ZXR10_R1(config)#interface loopback1
ZXR10_R1(config-if)#ip address

10.1.1.1 255.255.255.255

ZXR10_R1(config-if)#exit
ZXR10_R1(config)#ip multicast-routing
ZXR10_R1(config)#router pimsm
ZXR10_R1(config-router)#rp-candidate loopback1 priority 10
ZXR10_R1(config-router)#bsr-candidate loopback1 10 10
ZXR10_R1(config)#interface fei_1/1
ZXR10_R1(config-if)#ip address

10.10.10.1 255.255.255.0

ZXR10_R1(config-if)#ip pim sm
ZXR10_R1(config)#interface fei_1/2
ZXR10_R1(config-if)#ip address

10.10.20.1 255.255.255.0

ZXR10_R1(config-if)#ip pim sm
ZXR10_R1(config)#interface fei_1/3
ZXR10_R1(config-if)#ip address

10.10.30.1 255.255.255.0

ZXR10_R1(config-if)#ip pim sm
ZXR10_R1(config)#router ospf 1
ZXR10_R1(config-router)#network 10.0.0.0 255.255.255.0 area 0.0.0.0

Configuration of R2:
ZXR10_R2(config)#interface loopback1
ZXR10_R2(config-if)#ip address

10.1.1.2 255.255.255.255

ZXR10_R2(config)#ip multicast-routing
ZXR10_R2(config)#router pimsm
ZXR10_R2(config-router)#rp-candidate loopback1 priority 20
ZXR10_R2(config-router)#bsr-candidate loopback1 10 20
ZXR10_R2(config)#interface fei_1/1

9-18
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration


ZXR10_R2(config-if)#ip address

10.10.20.2 255.255.255.0

ZXR10_R2(config-if)#ip pim sm
ZXR10_R2(config)#interface fei_1/2
ZXR10_R2(config-if)#ip address

10.10.40.1 255.255.255.0

ZXR10_R2(config-if)#ip pim sm
ZXR10_R2(config)#interface fei_1/3
ZXR10_R2(config-if)#ip address

10.10.50.1 255.255.255.0

ZXR10_R2(config-if)#ip igmp access-group 10


ZXR10_R2(config)#router ospf 1
ZXR10_R2(config-router)#network 10.0.0.0 255.0.0.0 area 0.0.0.0
ZXR10_R2(config)#acl standard number 10
ZXR10_R2(config-std-acl)#permit any

Configuration of R3:
ZXR10_R3(config)#interface loopback1
ZXR10_R3(config-if)#ip address

10.1.1.3 255.255.255.255

ZXR10_R3(config)#ip multicast-routing
ZXR10_R3(config)#router pimsm
ZXR10_R3(config-router)#rp-candidate loopback1 priority 30
ZXR10_R3(config-router)#bsr-candidate loopback1 10 30
ZXR10_R3(config)#interface fei_1/1
ZXR10_R3(config-if)#ip address

10.10.30.2 255.255.255.0

ZXR10_R3(config-if)#ip pim sm
ZXR10_R3(config)#interface fei_1/2
ZXR10_R3(config-if)#ip address

10.10.40.2 255.255.255.0

ZXR10_R3(config-if)#ip pim sm
ZXR10_R3(config)#router ospf 1
ZXR10_R3(config-router)#network 10.0.0.0 255.255.255.0 area 0.0.0.0

9.8.2 MSDP Configuration Example


As shown in Figure 9-2, assign R1 and R2 to be in one PIM-SM domain and R2 to
be in another PIM-SM domain. Make multicast data flows in two PIM-SM domains
intercommunicate through MSDP.

9-19
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

Figure 9-2 Multicast Configuration

Configuration of R1:
ZXR10_R1(config)#interface loopback1
ZXR10_R1(config-if)#ip address

10.1.1.1 255.255.255.255

ZXR10_R1(config)#ip multicast-routing
ZXR10_R1(config)#router pimsm
ZXR10_R1(config-router)#rp-candidate loopback1 priority 10
ZXR10_R1(config-router)#bsr-candidate loopback1 10 10
ZXR10_R1(config)#interface fei_1/1
ZXR10_R1(config-if)#ip address

10.10.10.1 255.255.255.0

ZXR10_R1(config-if)#ip pim sm
ZXR10_R1(config)#interface fei_1/2
ZXR10_R1(config-if)#ip address

10.10.20.1 255.255.255.0

ZXR10_R1(config-if)#ip pim sm
ZXR10_R1(config-if)#ip pim bsr-border
ZXR10_R1(config)#interface fei_1/3
ZXR10_R1(config-if)#ip address

10.10.30.1 255.255.255.0

ZXR10_R1(config-if)#ip pim sm
ZXR10_R1(config)#router ospf 1
ZXR10_R1(config-router)#network 10.0.0.0 0.0.0.255 area 0.0.0.0
ZXR10_R1(config)#ip msdp peer 10.10.20.2 connect-source fei_1/2
ZXR10_R1(config)#ip msdp peer 10.10.30.2 connect-source fei_1/3

Configuration of R2:
ZXR10_R2(config)#interface loopback1
ZXR10_R2(config-if)#ip address

10.1.1.2 255.255.255.255

ZXR10_R2(config)#ip multicast-routing
ZXR10_R2(config)#router pimsm
ZXR10_R2(config-router)#rp-candidate loopback1 priority 20

9-20
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Chapter 9 Multicast Routing Configuration


ZXR10_R2(config-router)#bsr-candidate loopback1 10 20
ZXR10_R2(config)#interface fei_1/1
ZXR10_R2(config-if)#ip address

10.10.20.2 255.255.255.0

ZXR10_R2(config-if)#ip pim sm
ZXR10_R2(config)#interface fei_1/2
ZXR10_R2(config-if)#ip address

10.10.40.1 255.255.255.0

ZXR10_R2(config-if)#ip pim sm
ZXR10_R2(config)#interface fei_1/3
ZXR10_R2(config-if)#ip address

10.10.50.1 255.255.255.0

ZXR10_R2(config-if)#ip igmp access-group 10


ZXR10_R2(config)#router ospf 1
ZXR10_R2(config-router)#network 10.0.0.0 0.0.0.255 area 0.0.0.0
ZXR10_R2(config)#acl standard number 10
ZXR10_R2(config-std-acl)#permit any
ZXR10_R2(config-std-acl)#exit
ZXR10_R2(config)#ip msdp peer 10.10.20.1 connect-source fei_1/1
ZXR10_R2(config)#ip msdp peer 10.10.40.2 connect-source fei_1/2
ZXR10_R2(config)#ip msdp default-peer 10.10.20.1

Configuration of R3:
ZXR10_R3(config)#interface loopback1
ZXR10_R3(config-if)#ip address

10.1.1.3 255.255.255.255

ZXR10_R3(config)#ip multicast-routing
ZXR10_R3(config)#router pimsm
ZXR10_R3(config-router)#rp-candidate loopback1 priority 30
ZXR10_R3(config-router)#bsr-candidate loopback1 10 30
ZXR10_R3(config)#interface fei_1/1
ZXR10_R3(config-if)#ip address

10.10.30.2 255.255.255.0

ZXR10_R3(config-if)#ip pim sm
ZXR10_R3(config)#interface fei_1/2
ZXR10_R3(config-if)#ip address

10.10.40.2 255.255.255.0

ZXR10_R3(config-if)#ip pim sm
ZXR10_R3(config-if)#ip pim bsr-border
ZXR10_R3(config)#router ospf 1
ZXR10_R3(config-router)#network 10.0.0.0 0.0.0.255 area 0.0.0.0
ZXR10_R3(config)#ip msdp peer 10.10.40.1 connect-source fei_1/2
ZXR10_R3(config)#ip msdp peer 10.10.30.1 connect-source fei_1/1

9-21
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

ZXR10 ZSR User Manual (IPv4 Routing Volume)

This page intentionally left blank.

9-22
SJ-20110803091932-005|2011-08-30 (R2.0)

ZTE Proprietary and Confidential

Figures
Figure 2-1 Static Route Configuration ....................................................................... 2-2
Figure 2-2 Static Route Summary ............................................................................. 2-4
Figure 2-3 Default Route Configuration ..................................................................... 2-5
Figure 3-1 RIP Configuration Example...................................................................... 3-7
Figure 4-1 OSPF Router Type .................................................................................. 4-4
Figure 4-2 Basic OSPF Configuration ..................................................................... 4-16
Figure 4-3 Multi-Area OSPF Configuration.............................................................. 4-17
Figure 4-4 OSPF Virtual Link Configuration............................................................. 4-19
Figure 4-5 OSPF Authentication Configuration........................................................ 4-20
Figure 5-1 IS-IS Area ................................................................................................ 5-2
Figure 5-2 Single-Area IS-IS Configuration ............................................................... 5-7
Figure 6-1 Basic BGP Configuration ......................................................................... 6-3
Figure 6-2 BGP Route Advertisement ....................................................................... 6-4
Figure 6-3 BGP Route Aggregation........................................................................... 6-5
Figure 6-4 BGP Multi-hop Configuration.................................................................... 6-7
Figure 6-5 Filtering Router through NLRI .................................................................. 6-9
Figure 6-6 Configure LOCAL-PREF Attribute .......................................................... 6-11
Figure 6-7 Configure MED Attribute ........................................................................ 6-12
Figure 6-8 Configure BGP Synchronization............................................................. 6-16
Figure 6-9 Configure BGP Route Reflector ............................................................. 6-18
Figure 6-10

Configure BGP Confideration.............................................................. 6-20

Figure 6-11 BGP Configuration Example................................................................. 6-23


Figure 7-1 Packet Forwarding Bound with Policy Routing ......................................... 7-2
Figure 7-2 Policy Routing Configuration Example One.............................................. 7-5
Figure 7-3 Policy Routing Configuration Example Two .............................................. 7-6
Figure 8-1 Load Sharing Configuration ..................................................................... 8-4
Figure 8-2 Default ISIS Route Load Sharing Configuraiton ..................................... 8-11
Figure 8-3 Dynamic Load Sharing Configuration ..................................................... 8-14
Figure 9-1 Multicast Configuration .......................................................................... 9-18
Figure 9-2 Multicast Configuration .......................................................................... 9-20

Figures

This page intentionally left blank.

Tables
Table 1-1 SAFETY DESCRIPTION ........................................................................... 1-1

III

Tables

This page intentionally left blank.

Glossary
ABR
- Area Border Router
ACL
- Access Control List
AD
- Administrative Distance
AS
- Autonomous System
ASBR
- Autonomous System Boundary Router
BDR
- Backup Designate Router
BGP
- Border Gateway Protocol
BSR
- Bootstrap Router
CIDR
- Classless Inter-Domain Routing
CLNS
- ConnectionLess Network Sevice
DIS
- Designate IS
DR
- Designate Router
EBGP
- External Border Gateway Protocol
FR
- Frame Relay
FTP
- File Transfer Protocol
IBGP
- Interior Border Gateway Protocol
IGMP
- Internet Group Management Protocol
V

ZXR10 ZSR User Manual (IPv4 Routing Volume)

IGP
- Interior Gateway Protocol
IP
- Internet Protocol
IS-IS
- Intermediate System-to-Intermediate System
ISO
- International Organization for Standardization
ISP
- Internet Service Provider
LSA
- Link State Advertisement
LSP
- Link State Packet
LSU
- Link State Update
MAC
- Medium Access Control
MD5
- Message Digest 5 Algorithm
MED
- MULTI_EXIT_DISC
MSDP
- Multicast Source Discovery Protocol
NBMA
- Non-Broadcast Multiple Access
NLRI
- Network Layer Reachability Information
NSSA
- Not-So-Stubby Area
OSI
- Open System Interconnection
OSPF
- Open Shortest Path First
PDU
- Protocol Data Unit
PIM-SM
- Protocol Independent Multicast - Sparse Mode
VI

Glossary

RFC
- Request For Comments
RIP
- Routing Information Protocol
RP
- Rendezvous Point
RPF
- Reverse Path Forwarding
RR
- Router Reflector
SNP
- Sequence Num PDU
SPF
- Shortest Path First
TCP
- Transfer Control Protocol
ToS
- Type Of Service
UDP
- User Datagram Protocol
VLSM
- Variable Length Subnet Mask

VII