Huawei MPLS Layer3 VPN LAB

3/11/2025

In this Post , I am giving example of a complete MPLS Layer 3 Lab configuration using ENSP

Diagram:

Task 1: Connectivity and IP address assignment

First of All , Connect the network as explained above and assign the ip addresses in the depicted networks.

Task 2: BGP Configuration in CE_A1, CE_A2, CE_B1 & CE_B2

Configure Customer routers in BGP, by Putting CE-A1, CE-A2, CE-B1 & CE-B2 in AS 100,200,300,400 respectively. Then in another task put the core into AS 500.

!CE-A1

bgp 100

peer 172.18.0.2 as-number 500

ipv4-family unicast

network 172.16.0.0 255.255.0.0

peer 172.18.0.2 enable

!CE-B1

bgp 200

peer 172.19.0.2 as-number 500

ipv4-family unicast

network 172.17.0.0 255.255.0.0

peer 172.19.0.2 enable

!CE-A2

bgp 300

peer 172.22.0.1 as-number 500

ipv4-family unicast

network 172.20.0.0 255.255.0.0

peer 172.22.0.1 enable

!CE-B2

bgp 400

peer 172.23.0.1 as-number 500

ipv4-family unicast

network 172.21.0.0 255.255.0.0

peer 172.23.0.1 enable


Task 3: Configure OSPF as IGP in the ISP Core

Configure OSPF on the backbone network, and don’t forget to configure the loopback interfaces as their router-id

!PE1

Router id 1.1.1.1

Ospf 1

Area 0

Network 1.1.1.1 0.0.0.0

Network 172.24.0.0 0.0.255.255

!PE2

Router id 2.2.2.2

Ospf 1

Area 0

Network 2.2.2.2 0.0.0.0

Network 172.25.0.0 0.0.255.255

!P

Router id 3.3.3.3

Ospf 1

Area 0

Network 3.3.3.3 0.0.0.0

Network 172.25.0.0 0.0.255.255

Network 172.24.0.0 0.0.255.255

!Verification:

!P

Display ospf peer brief

OSPF Process 1 with Router ID 3.3.3.3

Peer Statistic Information

----------------------------------------------------------------------------

Area Id Interface Neighbor id State

0.0.0.0 Serial2/0/0 1.1.1.1 Full

0.0.0.0 Serial2/0/1 2.2.2.2 Full

---------------------------------------------------------------------------


Task 4:VPN Instances on the PE Side and assign interfaces to the relevant Instances

Configure two VPN instances in each one of the PEs, and assign the relevant interfaces to the equivalent VPN instance, and also don’t forget to configure the RD and route-target.

!PE1

Ip vpn-instance vpn1

Ipv4-family

Route-distinguisher 1:1

Vpn-target 1:1 export-extcommunity

Vpn-target 1:1 import-extcommunity

#

Ip vpn-instance vpn2

Ipv4-family

Route-distinguisher 2:2

Vpn-target 2:2 export-extcommunity

Vpn-target 2:2 import-extcommunity

#

Interface serial 1/0/0

Ip binding vpn-instance vpn1

Ip address 172.18.0.2 16

#

Interface serial 1/0/1

Ip binding vpn-instance vpn2

Ip address 172.19.0.2 16

#

!PE2

Ip vpn-instance vpn1

Ipv4-family

Route-distinguisher 1:1

Vpn-target 1:1 export-extcommunity

Vpn-target 1:1 import-extcommunity

#

Ip vpn-instance vpn2

Ipv4-family

Route-distinguisher 2:2

Vpn-target 2:2 export-extcommunity

Vpn-target 2:2 import-extcommunity

#

Interface serial 1/0/1

Ip binding vpn-instance vpn1

Ip address 172.22.0.1 16

#

Interface serial 2/0/0

Ip binding vpn-instance vpn2

Ip address 172.23.0.1 16

#




Task 5: Configure MP-BGP between PE1 & PE2 and BGP between PEs and CE2

Configure MP-BGP between PE1 & PE2, and configure BGP peer between PE and equivalent CE.

!PE1

Bgp 500

Peer 2.2.2.2 as-number 500

Peer 2.2.2.2 connect-interface lo0

Ipv4-family vpnv4

Peer 2.2.2.2 enable

#

Ipv4-family vpn-instance vpn1

Peer 172.18.0.1 as-number 100

#

Ipv4-family vpn-instance vpn2

Peer 172.19.0.1 as-number 200

#

!PE2

Bgp 500

Peer 1.1.1.1 as-number 500

Peer 1.1.1.1 connect-interface lo0

Ipv4-family vpnv4

Peer 1.1.1.1 enable

#

Ipv4-family vpn-instance vpn1

Peer 172.22.0.2 as-number 300

#

Ipv4-family vpn-instance vpn2

Peer 172.23.0.2 as-number 400

#



Task 6: MPLS Enable on the ISP Core

Enable MPLS in the backbone routers (PE1/PE2/P)

!PE1

Mpls lsr-id 1.1.1.1

Mpls

Mpls ldp

Interface s2/0/0

Mpls

Mpls ldp

!PE2

Mpls lsr-id 2.2.2.2

Mpls

Mpls ldp

Interface s1/0/0

Mpls

Mpls ldp

!P

Mpls lsr-id 3.3.3.3

Mpls

Mpls ldp

Interface s2/0/0

Mpls

Mpls ldp

Interface s2/0/1

Mpls

Mpls ldp



Final Verification:


The ping should work fine and smooth between PCs belonging to the same Customers.

Waleed Hashim Ali Adlan

CCIE#41999/HCIE#14518