Professional Documents
Culture Documents
Guide
NE Series Routers - BGP MPLS VPN Practice Guide
Contents
Typical Usage Scenarios of BGP MPLS VPN................................................................... 1
Experiment Description..................................................................................................... 2
Environment Introduction .................................................................................................................. 2
Objectives ......................................................................................................................................... 2
References ....................................................................................................................................... 2
Topology ........................................................................................................................................... 2
Tasks ................................................................................................................................................ 3
Data Plan.......................................................................................................................................... 3
Configuration Preparation ................................................................................................................. 3
Configuration Flowchart .................................................................................................................... 3
Configure CE2............................................................................................................................ 11
Verify the Configuration ..............................................................................................................12
Step 6: Configure MP-BGP on PEA and PEB ...................................................................................12
Configuration Description ...........................................................................................................12
Configure PEA ...........................................................................................................................12
Configure PEB ...........................................................................................................................12
Verify the Configuration ..............................................................................................................13
Step 7: Import Routes ......................................................................................................................13
Configuration Description ...........................................................................................................13
Configure CE1............................................................................................................................13
Configure CE2............................................................................................................................13
Verify the Configuration ..............................................................................................................13
FAQ ................................................................................................................................... 15
Answers ............................................................................................................................ 16
Based on the application of BGP MPLS VPN on live networks, this chapter describes how to configure BGP MPLS VPN
on NE Series routers.
Experiment Description
Environment Introduction
This guide describes the implementation and application of MPLS L3VPN. This guide also
describes how to configure MPLS L3VPN. Router Visio 1.6.7 is used to build an experiment
environment.
Objectives
Configure BGP MPLS VPN.
Troubleshoot BGP MPLS VPN faults.
References
NE40E&NE80E Command Reference 04
Topology
In the topology, CE1 and CE2 on VPNA are connected using BGP MPLS VPN. The CEs'
Loopback 0 addresses are used to simulate network segment routes. The backbone network is
located in AS 100. OSPF runs in the MPLS domain. CE1 and CE2 are located in AS 64520 and AS
64530, respectively. Directly connected interfaces are used to establish EBGP peer relationships
between CE1 and PEA and between CE2 and PEB. For details about planned IP addresses, see
the topology.
Tasks
Task Description
1 Run OSPF to implement interworking between the devices in the MPLS domain.
2 Create a VPN according to the sub-interface plan in the topology, configure BGP MPLS
VPN, and ensure that the simulated network IP addresses of CE1 and CE2 are
reachable.
Data Plan
PEA: RD 100:1; RT (import/export) 200:1
PEB: RD 300:1; RT (import/export) 200:1
Configuration Preparation
Before you configure BGP MPLS VPN, complete the following operations:
Connect and power on devices.
Configure interface IP addresses and loopback interface addresses.
Configuration Flowchart
Configuration Description
Operation View Command
Configure an IP [Quidway-Ethernet0/0/0] ip-address ip-address mask | mask-length
address.
Configure CE1
<Quidway>system-view
[Quidway]sysname CE1
[CE1]interface Ethernet 0/0/0
[CE1-Ethernet0/0/0]ip address 21.1.1.1 30
[CE1-Ethernet0/0/0]undo shutdown
[CE1-Ethernet0/0/0]quit
[CE1]interface LoopBack 1
[CE1-LoopBack1]ip address 11.11.11.11 32
Configure PEA
<Quidway>system-view
[Quidway]sysname PEA
[PEA]interface Ethernet 0/0/0
[PEA-Ethernet0/0/0]ip address 21.1.1.2 30
[PEA-Ethernet0/0/0]undo shutdown
[PEA-Ethernet0/0/0]quit
[PEA]interface Ethernet 0/0/2
[PEA-Ethernet0/0/2]ip address 13.1.1.1 30
[PEA-Ethernet0/0/2]undo shutdown
[PEA-Ethernet0/0/2]quit
[PEA]interface LoopBack 0
[PEA-LoopBack0]ip address 1.1.1.1 32
Configure PEB
<Quidway>system-view
[Quidway]sysname PEB
[PEB]interface Ethernet 0/0/2
[PEB-Ethernet0/0/2]ip address 13.1.1.2 30
[PEB-Ethernet0/0/2]undo shutdown
[PEB-Ethernet0/0/2]quit
[PEB]interface Ethernet 0/0/0
[PEB-Ethernet0/0/0]ip address 32.1.1.2 30
[PEB-Ethernet0/0/0]undo shutdown
[PEB-Ethernet0/0/0]quit
[PEB]interface LoopBack 0
[PEB-LoopBack0]ip address 3.3.3.3 32
Configure CE2
<Quidway>system-view
[Quidway]sysname CE2
[CE2]interface Ethernet 0/0/0
[CE2-Ethernet0/0/0]ip address 32.1.1.1 30
[CE2-Ethernet0/0/0]undo shutdown
[CE2-Ethernet0/0/0]quit
[CE2]interface LoopBack 1
[CE2-LoopBack1]ip address 21.21.21.21 32
The command output shows that the communication between PEA and PEB is normal. Use
this method to check direct link connectivity between routers.
Configuration Description
Operation View Command
Configure a Router ID. [Quidway] router id router-id
Configure PEA
[PEA]router id 1.1.1.1
[PEA]ospf 1
[PEA-ospf-1]area 0
[PEA-ospf-1-area-0.0.0.0]network 13.1.1.0 0.0.0.3
[PEA-ospf-1-area-0.0.0.0]network 1.1.1.1 0.0.0.0
Configure PEB
[PEB]router id 3.3.3.3
[PEB]ospf 1
[PEB-ospf-1]area 0
[PEB-ospf-1-area-0.0.0.0]network 13.1.1.0 0.0.0.3
[PEB-ospf-1-area-0.0.0.0]network 3.3.3.3 0.0.0.0
The command output shows that State is Full. That is, OSPF neighbor relationship of PEA is
normal.
2. Run the display ip routing-table protocol ospf command to view OSPF routing information
in the routing table. The following uses PEB as an example.
[PEB]display ip routing-table protocol ospf
Route Flags: R - relay, D - download to fib
-----------------------------------------------------------------
Public routing table : OSPF
Destinations : 1 Routes : 1
OSPF routing table status : <Active>
Destinations : 1 Routes : 1
Destination/Mask Proto Pre Cost Flags NextHop Interface
1.1.1.1/32 OSPF 10 1 D 13.1.1.1 Ethernet0/0/2
OSPF routing table status : <Inactive>
Destinations : 0 Routes : 0
The command output shows that PEB has learned the route to PEA's loopback interface from
the OSPF neighbor.
3. Run the ping command to check link connectivity. For example, run the ping command on
PEA to ping PEB's loopback address.
[PEA]ping 3.3.3.3
PING 3.3.3.3: 56 data bytes, press CTRL_C to break
Reply from 3.3.3.3: bytes=56 Sequence=1 ttl=255 time=50 ms
Reply from 3.3.3.3: bytes=56 Sequence=2 ttl=255 time=30 ms
Reply from 3.3.3.3: bytes=56 Sequence=3 ttl=255 time=60 ms
Reply from 3.3.3.3: bytes=56 Sequence=4 ttl=255 time=60 ms
Reply from 3.3.3.3: bytes=56 Sequence=5 ttl=255 time=60 ms
--- 3.3.3.3 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 30/52/60 ms
Configuration Description
Operation View Command
Configure an LSR ID. [Quidway] mpls lsr-id x.x.x.x
Configure PEA
[PEA]mpls lsr-id 1.1.1.1
Configure PEB
[PEB]mpls lsr-id 3.3.3.3
[PEB]mpls
[PEB-mpls]quit
[PEB]interface Ethernet 0/0/2
[PEB-Ethernet0/0/2]mpls
[PEB-Ethernet0/0/2]quit
[PEB]mpls ldp
[PEB-mpls-ldp]quit
[PEB]interface Ethernet 0/0/2
[PEB-Ethernet0/0/2]mpls ldp
[PEB-Ethernet0/0/2]quit
2. Run the display mpls ldp lsp command to view information about MPLS LDP LSPs. The
following uses PEA as an example.
[PEA]display mpls ldp lsp
LDP LSP Information
-----------------------------------------------------------------
DestAddress/Mask In/OutLabel UpstreamPeer NextHopOut Interface
1.1.1.1/32 3/NULL 3.3.3.3 127.0.0.1 InLoop0
*1.1.1.1/32 Liberal/1024 DS/3.3.3.3
3.3.3.3/32 NULL/3 - 13.1.1.2 Eth0/0/2
3.3.3.3/32 1024/3 3.3.3.3 13.1.1.2 Eth0/0/2
-----------------------------------------------------------------
TOTAL: 3 Normal LSP(s) Found.
TOTAL: 1 Liberal LSP(s) Found.
TOTAL: 0 Frr LSP(s) Found.
A '*' before an LSP means the LSP is not established
A '*' before a Label means the USCB or DSCB is stale
A '*' before an UpstreamPeer means the session is in GR state
A '*' before a DS means the session is in GR state
A '*' before a NextHop means the LSP is FRR LSP
The command output shows that MPLS LDP has allocated labels to the peer 3.3.3.3 and the
LSPs are formed.
Configuration Description
According to the experiment requirements, a VPN instance needs to be created. The name of the VPN instance is
VPNA. The RDs of PEA and PEB are 100:1 and 300:1, respectively. The RTs of both PEA and PEB are 200:1.
Configure PEA.
[PEA]ip vpn-instance VPNA
[PEA-vpn-instance-VPNA]route-distinguisher 100:1
[PEA-vpn-instance-VPNa-af-ipv4]quit
After an interface is bound to a VPN instance, the IP address configured in the interface is deleted. Therefore, you must
reconfigure an IP address for the interface.
Configure PEB
[PEB]ip vpn-instance VPNA
[PEB-vpn-instance-VPNA]route-distinguisher 300:1
[PEB-vpn-instance-VPNA-af-ipv4]quit
[PEB-vpn-instance-VPNA]vpn-target 200:1
[PEB-vpn-instance-VPNA]quit
[PEB]interface Ethernet 0/0/0
[PEB-Ethernet0/0/0]ip binding vpn-instance VPNA
[PEB-Ethernet0/0/0]ip address 32.1.1.2 30
Configuration Description
Operation View Command
Run BGP. [Quidway] bgp as-number
Configure PEA
[PEA]bgp 100
[PEA-bgp]peer 3.3.3.3 as-number 100
[PEA-bgp]peer 3.3.3.3 connect-interface LoopBack 0
[PEA-bgp]ipv4-family vpn-instance VPNA
Configure CE1
[CE1]bgp 64520
[CE1-bgp]peer 21.1.1.2 as-number 100
Configure PEB
[PEB]bgp 100
[PEB-bgp]peer 1.1.1.1 as-number 100
[PEB-bgp]peer 1.1.1.1 connect-interface LoopBack 0
[PEB-bgp]ipv4-family vpn-instance VPNA
[PEB-bgp-VPNA]peer 32.1.1.1 as-number 64530
Configure CE2
[CE2]bgp 64530
[CE2-bgp]peer 32.1.1.2 as-number 100
Configuration Description
Traditional BGP can manage IPv4 routes but not the routes of VPNs with overlapping address space. That is, VPNv4
routes cannot be supported. To correctly process VPN routes, MP-BGP uses the address family to differentiate network
layer protocols. An address family can be a traditional IPv4 address family or a VPN-IPv4 address family.
Configure PEA
[PEA]bgp 100
[PEA-bgp]ipv4-family vpnv4
Configure PEB
[PEB]bgp 100
[PEB-bgp]ipv4-family vpnv4
[PEB-bgp-af-vpnv4]peer 1.1.1.1 enable
Configuration Description
Operation View Command
Import a route. [Quidway-bgp] network ip-address netmask
Configure CE1
[CE1]bgp 64520
[CE1-bgp]network 11.11.11.11 255.255.255.255
Configure CE2
[CE2]bgp 64530
[CE2-bgp]network 21.21.21.21 255.255.255.255
FAQ
1. Which of the following commands can be used to view the routing table information of the
VPN instance named huawei? ( )
− display ip routing-table
− display ip routing-table huawei
− display ip routing-table vpn-instance huawei
2. What are the precautions for MP-BGP configuration?
3. Can I set the same RD on PEA and PEB?
Answers
1. C
2. You need to establish a BGP IPv4 peer relationship and then run the following commands to
enable VPNv4 route exchange in the VPNv4 address family: