- Table of Contents
- Related Documents
-
Title | Size | Download |
---|---|---|
03-MPLS L2VPN Configuration | 284.95 KB |
Table of Contents
MPLS L2VPN Configuration Task List
Configuring a PE Interface Connecting a CE
Configuring a PE Interface Connecting a CE to Use Ethernet
Configuring a PE Interface Connecting a CE to Use VLAN
Configuring Martini MPLS L2VPN
Configuring Kompella MPLS L2VPN
Displaying and Maintaining MPLS L2VPN
Displaying the Operation of MPLS L2VPN
Resetting BGP L2VPN Connections
MPLS L2VPN Configuration Examples
Example for Configuring a Remote CCC Connection
Example for Configuring SVC MPLS L2VPN
Example for Configuring Martini MPLS L2VPN
Example for Configuring Kompella MPLS L2VPN
When configuring MPLS L2VPN, go to these sections for information you are interested in:
l MPLS L2VPN Configuration Task List
l Displaying and Maintaining MPLS L2VPN
l MPLS L2VPN Configuration Examples
l The term router in this document refers to a router in a generic sense or a Layer 3 switch.
l At present, to support MPLS or MPLS-based functions, S7500E series Ethernet switches must use the LSQ1SRP1CB engine or use no other LPUs but the EA series.
MPLS L2VPN Overview
This section covers these topics:
Introduction to MPLS L2VPN
Traditional VPN
Traditional VPNs based on Asynchronous Transfer Mode (ATM) or Frame Relay (FR) are quite popular. They share the network infrastructure of carriers. However, they have some inherent disadvantages:
l Dependence on dedicated media: To provide both ATM-based and FR-based VPN services, carriers must establish two separate infrastructures across the whole service scope, one ATM infrastructure and one FR infrastructure. Apparently, the cost is very high and the infrastructures are not utilized efficiently.
l Complicated deployment: To add a site to an existing VPN, you have to modify the configurations of all edge nodes connected with the VPN site.
MPLS L2VPN is developed as a solution to address the above disadvantages.
MPLS L2VPN
MPLS L2VPN provides Layer 2 VPN services on the MPLS network. It allows carriers to establish L2VPNs on different data link layer protocols, including ATM, FR, VLAN, Ethernet and PPP.
MPLS L2VPN transfers Layer 2 user data transparently on the MPLS network. For users, the MPLS network is a Layer 2 switched network and can be used to establish Layer 2 connections between nodes.
Consider ATM as an example. Each customer edge device (CE) can connect to the MPLS network through an ATM virtual circuit (VC) to communicate with another CE. This is similar to that on an ATM network.
Figure 1-1 Network diagram for MPLS L2VPN
Comparison with MPLS L3VPN
Compared with MPLS L3VPN, MPLS L2VPN has the following advantages:
l High scalability: MPLS L2VPN establishes only Layer 2 connections. It does not involve the routing information of users. This greatly reduces the load of the PEs and even the load of the whole service provider network, enabling carriers to support more VPNs and to service more users.
l Guaranteed reliability and private routing information security: As no routing information of users is involved, MPLS L2VPN neither tries to obtain nor processes the routing information of users, guaranteeing the security of the user VPN routing information.
l Support for multiple network layer protocols, such as IP, IPX, and SNA.
Basic concepts of MPLS L2VPN
In MPLS L2VPN, the concepts and principles of CE, PE and P are the same as those in MPLS L3VPN:
l Customer edge device (CE): A CE resides on a customer network and has one or more interfaces directly connected with service provider networks. It can be a router, a switch, or a host. It cannot "sense" the existence of any VPN, neither does it need to support MPLS.
l Provider edge router (PE): A PE resides on a service provider network and connects one or more CEs to the network. On an MPLS network, all VPN processing occurs on the PEs.
l Provider (P) router: A P router is a backbone router on a service provider network. It is not directly connected with any CE. It only needs to be equipped with basic MPLS forwarding capability.
MPLS L2VPN uses label stacks to implement the transparent transmission of user packets in the MPLS network.
l Outer label, also called tunnel label, is used to transfer packets from one PE to another.
l Inner label, also called VC label, is used to identify different connections between VPNs.
l Upon receiving packets, a PE determines to which CE the packets are to be forwarded according to the VC labels.
Figure 1-2 illustrates how the label stack changes in the MPLS L2VPN forwarding process.
Figure 1-2 MPLS L2VPN label stack processing
1) L2 PDU: Layer 2 protocol data unit |
2) T represents tunnel label. V represents VC label. T’ represents swapped tunnel label. |
Implementation of MPLS L2VPN
Currently, there is no official standard for MPLS L2VPN. The Provider-Provisioned Virtual Private Network (PPVPN) working group of the IETF has drafted several framework protocols. Two of the most important ones are Martini draft and Kompella draft:
l draft-martini-l2circuit-trans-mpls
l draft-kompella-ppvpn-l2vpn
The Martini draft defines a method for establishing PPP links to implement MPLS L2VPN. It uses Label Distribution Protocol (LDP) as a signaling protocol to transfer VC labels.
The Kompella draft defines a CE-to-CE mode for implementing MPLS L2VPN on the MPLS network. It uses extended BGP as the signaling protocol to advertise Layer 2 reachability information and VC labels.
In addition, MPLS L2VPN can also be implemented by configuring VC labels statically. Circuit Cross Connect (CCC) and Static Virtual Circuit (SVC) are two of the static implementation methods.
The following sections describe the characteristics of these implementation methods for MPLS L2VPN.
CCC MPLS L2VPN
Unlike common MPLS L2VPN, Circuit Cross Connect (CCC) employs just one level of label to transfer user data. Therefore, it uses label switched paths (LSPs) exclusively. That is, a CCC LSP can be used to transfer only the data of the CCC connection; it can neither be used for other MPLS L2VPN connections, nor for MPLS L3VPN or common IP packets.
The most significant advantage of this method is that no label signaling is required for transferring Layer 2 VPN information. As long as MPLS forwarding is supported and service provider networks are interconnected, this method works perfectly. In addition, since LSPs are dedicated, this method supports QoS services.
There are two types of CCC connections:
l Local connection: A local connection is established between two local CEs that are connected to the same PE. The PE functions like a Layer 2 switch and can directly switch packets between the CEs without any static LSP.
l Remote connection: A remote connection is established between a local CE and a remote CE, which are connected to different PEs. In this case, a static LSP is required to transport packets from one PE to another.
l Only remote connection is supported by S7500E Series Ethernet Switches.
l You must configure for each remote CCC connection two LSPs, one for inbound and the other for outbound, on the P device along the remote connection.
SVC MPLS L2VPN
Static Virtual Circuit (SVC) also implements MPLS L2VPN by static configuration. It transfers L2VPN information without using any signaling protocol.
The SVC method resembles the Martini method closely and is in fact a static implementation of the Martini method. The difference is that it does not use LDP to transfer Layer 2 VC and link information. You only need to configure VC label information.
The labels for CCC and SVC range from 16 to 1023, which are reserved for static LSPs.
Martini MPLS L2VPN
The key of the Martini method is to set up VCs between CEs.
Martini MPLS L2VPN employs VC type and VC ID to identify a VC. The VC type indicates the encapsulation type of the VC, which can be ATM, VLAN, or PPP. The VC ID uniquely identifies the VC among the VCs of the same VC type on a PE.
The PEs connecting the two CEs of a VC exchange VC labels through LDP, and bind their respective CE by the VC ID.
Once LDP establishes an LSP between the two PEs and the label exchange and the binding to CE are finished, a VC is set up and ready to transfer Layer 2 data.
To allow the exchange of VC labels between PEs, the Martini method extended LDP by adding the forwarding equivalence class (FEC) type of VC FEC. Moreover, as the two PEs exchanging VC labels may not be connected directly, a remote LDP session must be set up to transfer the VC FEC and VC labels.
With Martini MPLS L2VPN, only PEs need to maintain a small amount of VC labels and LSP mappings and no P device contains Layer 2 VPN information. Therefore, it has high scalability. In addition, to add a new VC, you only need to configure a one-way VC for each of the PEs. Your configuration will not affect the operation of the network.
The Martini method applies to scenarios with sparse Layer 2 connections, such as a scenario with a star topology.
Kompella MPLS L2VPN
Kompella MPLS L2VPN is different from Martini MPLS L2VPN in that it does not operate on the connections between CEs directly. It organizes different VPNs in the whole service provider network and encodes each CE in a VPN. For a connection to be established between two CEs, you only need to perform these tasks on the PEs:
l Configuring CE IDs of the local and remote CEs respectively
l Specifying the circuit ID that the local CE assigns to the connection, such as the VPI/VCI with ATM.
Kompella MPLS L2VPN uses extended BGP as the signaling protocol to distribute VC labels. Its label block mode allows it to assign labels to multiple connections at a time.
With Kompella MPLS L2VPN, you can specify a local CE range to indicate how many CEs can be connected with a CE. Then, the system assigns a label block of a size equal to the CE range for the CE. In this way, you can reserve some labels for the VPN for future use. This wastes some label resources in a short term, but can reduce the VPN deployment and configuration workload in the case of expansion.
Imagine that an enterprise VPN contains 10 CEs and the number may increase to 20 in future service expansion. In this case, you can set the CE range of each CE to 20. Thus, when you need to add a CE to the VPN later, you only need to modify the configurations of the PE to which the new CE is connected. No change is required for the other PEs. This makes VPN expansion extremely simple.
Similar to MPLS L3VPN, Kompella MPLS L2VPN also uses VPN targets to identify VPNs. This brings excellent VPN networking flexibility.
Kompella supports local connections and remote connections, while the S7500E series switches support only the latter.
MPLS L2VPN Configuration Task List
Complete the following tasks to configure MPLS L2VPN:
Task |
Remarks |
Required |
|
Required |
|
Required Use one of the approaches according to the MPLS L2VPN implementation method |
|
Configuring MPLS L2VPN
You can select any of the implementation methods for MPLS L2VPN as needed. However, no matter what method you select, you must complete these two tasks:
l Configuring MPLS basic capability
l Enabling MPLS L2VPN
Follow these steps to complete the above two tasks:
To do… |
Use the command… |
Remarks |
Enter system view |
system-view |
— |
Configure the LSR ID |
mpls lsr-id |
Required |
Configure MPLS basic capability and enter MPLS view |
mpls |
Required |
Return to system view |
quit |
— |
Enable MPLS L2VPN |
mpls l2vpn |
Required |
Configuring a PE Interface Connecting a CE
A PE interface connecting a CE can use these encapsulation types:
l Ethernet
l VLAN
Configuring a PE Interface Connecting a CE to Use Ethernet
l An Ethernet interface can use the encapsulation type of Ethernet. For Ethernet interface configuration information, refer to Ethernet Interface Configuration in the Access Volume.
l A VLAN interface using the link type of access can use the encapsulation type of Ethernet. For configuration information about VLAN interface and link type, refer to VLAN Configuration in the Access Volume.
Configuring a PE Interface Connecting a CE to Use VLAN
l An Ethernet subinterface can use the encapsulation type of VLAN. For Ethernet subinterface configuration information, refer to Logical Interface Configuration in the Access Volume.
l A VLAN interface using the link type of trunk or hybrid can use the encapsulation type of VLAN (the VLAN interface and the CE must reside in the same VLAN). For configuration information about VLAN interface and link type, refer to VLAN Configuration in the Access Volume.
Configuring CCC MPLS L2VPN
Configuration Prerequisites
Before configuring CCC L2VPN, complete these tasks:
l Configuring MPLS basic capability for the MPLS backbone on the PEs and P devices.
l Enabling MPLS L2VPN on PEs of the MPLS backbone. You do not need to enable MPLS L2VPN on the P devices.
To configure CCC MPLS L2VPN, you need the following data:
l Name for the CCC connection
l Connection type: local or remote
l For a local CCC connection: the types and numbers of the incoming and outgoing interfaces
l For a remote CCC connection: the type and number of the incoming interface, the address of the next hop or the type and number of the outgoing interface, and the incoming and outgoing labels of the LSRs along the CCC connection
When configuring a remote connection, if the link that the outgoing interface connects is not a point-to-point link (for example, when the outgoing interface is a VLAN interface), you need to specify the IP address of the next hop. If not, you need to specify the outgoing interface.
Configuration Procedure
Configuring the remote CCC connection
1) Configure the PEs
Follow these steps to configure a PE:
To do… |
Use the command… |
Remarks |
Enter system view |
system-view |
— |
Create a remote CCC connection between CEs connected to different PEs |
ccc ccc-connection-name interface interface-type interface-number in-label in-label-value out-label out-label-value nexthop ip-address [ control-word | no-control-word ] |
Required |
You do not need to configure two static LSPs for each remote CCC connection. Instead, you only need to configure the incoming and outgoing labels, where the incoming label must be exclusively for the CCC connection. The labels function as static LSPs.
Follow these steps to configure a P device:
To do… |
Use the command… |
Remarks |
Enter system view |
system-view |
— |
Configure a transit static LSP |
static-lsp transit lsp-name incoming-interface interface-type interface-number in-label in-label nexthop next-hop-addr out-label out-label |
Required |
l With CCC, no static LSPs are required on the PEs but dedicated bidirectional static LSPs are required on all the P devices between the PEs for transmitting the data of the CCC connection.
l For static LSP configuration commands, refer to MPLS Basics Commands in the MPLS Volume.
Configuring SVC MPLS L2VPN
SVC MPLS L2VPN does not use any signaling protocol to transfer L2VPN information. Instead, it uses tunnels to transport data between PEs.
SVC supports these tunnel types: LDP LSP.
Configuration Prerequisites
Before configuring SVC MPLS L2VPN, complete these tasks:
l Configuring IGP on the PEs and P devices to guarantee the IP connectivity of the MPLS backbone
l Configuring MPLS basic capability and MPLS LDP for the MPLS backbone on the PEs and P devices to establish LDP LSPs
l Enabling MPLS L2VPN on the PEs
l For VLAN access, configuring a subinterface
l Establishing the tunnels between PEs according to the tunneling policy.
To configure SVC MPLS L2VPN, you need the following data:
l Types and numbers of the interfaces connecting the CEs
l Destination LSR ID of SVC
l Incoming and outgoing labels of the L2VPN connection
l SVC tunneling policy
Configuration Procedure
Follow these steps to configure SVC MPLS L2VPN on the PE:
To do… |
Use the command… |
Remarks |
Enter system view |
system-view |
— |
Enter interface view for the interface connecting the CE |
interface interface-type interface-number |
— |
Create an SVC MPLS L2VPN connection |
mpls static-l2vc destination destination-router-id transmit-vpn-label transmit-label-value receive-vpn-label receive-label-value [ tunnel-policy tunnel-policy-name ] [ control-word | no-control-word ] |
Required |
Configuring Martini MPLS L2VPN
Martini MPLS L2VPN uses extended LDP to transfer Layer 2 information and VC labels. To configure Martini MPLS L2VPN, you need to:
l Create a Martini MPLS L2VPN connection
After you create a Martini MPLS L2VPN connection on a Layer 3 interface, packets received on the interface will be forwarded through the connection.
l Configure the remote peer PE
In Martini MPLS L2VPN implementation, VC labels need to be exchanged between PEs. As two PEs may not be connected to each other directly, you need to establish a remote session between the two PEs, so that VC FECs and VC labels can be transferred through the session.
Configuration Prerequisites
Before configuring Martini MPLS L2VPN, complete these tasks:
l Configuring IGP on the PEs and P devices to guarantee the IP connectivity of the MPLS backbone
l Configuring MPLS basic capability and MPLS LDP for the MPLS backbone on the PEs and P devices to establish LDP LSPs
l Enabling MPLS L2VPN on the PEs
l Establishing remote LDP sessions between PEs
l For VLAN access, configuring a subinterface
To configure Martini MPLS L2VPN, you need the following data:
l Types and numbers of the interfaces connecting the CEs
l L2VC destination address and VC ID
l Tunneling policy
Configuration Procedure
Follow these steps to configure Martini MPLS L2VPN on the PE:
To do… |
Use the command… |
Remarks |
Enter system view |
system-view |
— |
Enter interface view for the interface connecting the CE |
interface interface-type interface-number |
— |
Create a Martini MPLS L2VPN connection |
mpls l2vc destination vcid [ tunnel-policy tunnel-policy-name ] [ control-word | no-control-word ] |
Required |
Return to system view |
quit |
— |
Configure the remote peer |
mpls ldp remote-peer remote-peer-name |
Required |
remote-ip ip-address |
Required |
For remote peer configuration information, refer to MPLS Basics Configuration in the MPLS Volume.
For a Martini connection, there are two main parameters: one is the IP address of the peer PE, the other is the VC ID. The combination of the VC ID and the encapsulation type must be unique on a PE. Changing the encapsulation type may result in VC ID conflicts.
Configuring Kompella MPLS L2VPN
Kompella MPLS L2VPN uses extended BGP as the signaling protocol to transfer L2VPN information between PEs.
To create a Kompella local connection, you only need to configure the VPN and CE connection on the PE. Neither IGP nor BGP L2VPN capability is required.
Configuration Prerequisites
Before configuring Kompella MPLS L2VPN, complete these tasks:
l Configuring IGP on the PEs and P devices to guarantee the IP connectivity of the MPLS backbone
l Configuring MPLS basic capability and MPLS LDP for the MPLS backbone on the PEs and P devices to establish LDP LSPs
l Enabling MPLS L2VPN on the PEs
To configure Kompella MPLS L2VPN, you need the following data:
l AS numbers of the local PE and the peer PE
l Name, RD, and VPN Target attributes of the L2VPN connection
l CE name, CE ID, and CE range
l CE offset
Configuration Procedure
Configuring BGP L2VPN capability
Follow these steps to configure BGP L2VPN capability:
To do… |
Use the command… |
Remarks |
Enter system view |
system-view |
— |
Enter BGP view |
bgp as-number |
— |
Establish the peer relationship with the peer PE |
peer { group-name | ip-address } as-number as-number |
Required |
Specify the interface for the TCP connection |
peer { group-name | ip-address } connect-interface interface-type interface-number |
Required |
Enter BGP L2VPN address family view |
l2vpn-family |
Required |
Enable the filtering by the VPN target extended community attributes for the received routing information |
policy vpn-target |
Optional Enabled by default |
Enable the specified peer or peers to exchange BGP routing information of the BGP-L2VPN address family |
peer { group-name | ip-address } enable |
Required |
For information about the configuration of BGP-L2VPN address family, refer to MPLS L3VPN Configuration in the MPLS Volume.
Configuring VPN
Follow these steps to configure VPN:
To do… |
Use the command… |
Remarks |
Enter system view |
system-view |
— |
Create a VPN and enter MPLS L2VPN view |
mpls l2vpn vpn-name [ encapsulation { ethernet | vlan } [ control-word | no-control-word ] ] |
Required |
Configure an RD for the L2VPN |
route-distinguisher route-distinguisher |
Required |
Associate a particular VPN with one or more VPN targets |
vpn-target vpn-target&<1-16> [ both | export-extcommunity | import-extcommunity ] |
Required |
Set the Layer 2 MTU for the VPN |
mtu mtu |
Optional |
l The mtu command is not recommended. It affects only parameter negotiation, which may occur; it does not affect data forwarding.
l With Kompella MPLS L2VPN, you must create on the PE an L2VPN instance for each VPN where a directly connected CE resides. When creating an L2VPN, you must specify an encapsulation type matching that of the CE side interface.
l The configuration of the VPN targets and RD are the same as that for MPLS L3VPN. For Kompella MPLS L2VPN, the RD is required. Once configured, an RD cannot be changed, unless you delete the L2VPN and then re-create it.
Creating a CE Connection
CE ID is used for identifying a CE uniquely in a VPN. To facilitate the configuration, it is recommended to encode the CE IDs in continuous natural numbers starting from 1.
The CE range of a CE indicates the maximum number of CEs that the CE can connect with. You can configure a CE range greater than what is required based on your estimate of the future VPN expansion if the label resources are abundant (they are usually abundant). This can reduce the configuration modification required when CEs are added in the VPN in future.
When creating a CE connection, if you do not specify the CE offset, the following are true:
l For the first connection of the CE, the CE offset is the value specified by the default-offset parameter in the ce command.
l For any other connection of the CE, the CE offset is that of the former connection plus 1.
l When planning a VPN, you are recommended to encode CE IDs in incremental sequence starting from 1. When configuring connections, you are recommended to adopt the sequence of the CE IDs, in which case you can omit the ce-offset portion from most of the required commands. This simplifies the configuration.
Note that you can only increase the CE range. For example, if the original CE range is 10, you can increase it to 20, but cannot reduce it to 5. The only way to reduce the CE range is to delete the CE and re-create it.
When you increase the CE range, for example, from 10 to 20, the system does not release the original label block and then re-apply for a new label block of the size of 20. Instead, the system applies for a supplementary label block of the size of 10. This ensures that the existing services will not be interrupted.
Follow these steps to create a CE connection:
To do… |
Use the command… |
Remarks |
Enter system view |
system-view |
— |
Enter MPLS L2VPN view |
mpls l2vpn vpn-name |
— |
Create a CE for a VPN and enter MPLS L2VPN CE view |
ce ce-name [ id ce-id [ range ce-range ] [ default-offset ce-offset ] ] |
Required |
Create a Kompella connection |
connection [ ce-offset id ] interface interface-type interface-number [ tunnel-policy tunnel-policy-name ] |
Required |
Displaying and Maintaining MPLS L2VPN
Displaying the Operation of MPLS L2VPN
To do… |
Use the command… |
Remarks |
Display information about CCC connections |
display ccc [ ccc-name ccc-name | type { local | remote } ] |
Available in any view |
Display information about specified L2VPN VC interfaces |
display l2vpn ccc-interface vc-type { all | bgp-vc | ccc | ldp-vc | static-vc } [ up | down ] |
Available in any view |
Display information about static VCs configured on the router |
display mpls static-l2vc [ interface interface-type interface-number ] |
Available in any view |
Display information about Martini VCs configured on the router |
display mpls l2vc [ interface interface-type interface-number | remote-info] |
Available in any view |
Display information about Kompella L2VPN connections |
display mpls l2vpn connection [ vpn-name vpn-name [ remote-ce ce-id | down | up | verbose ] | summary | interface interface-type interface-number ] |
Available in any view |
Display information about L2VPN in the BGP routing table |
display bgp l2vpn { all | group [ group-name ] | peer [ [ ip-address ] verbose ] | route-distinguisher rd [ ce-id ce-id [ label-offset label-offset ] ] } |
Available in any view |
Display L2VPN information on a PE |
display mpls l2vpn [ export-route-target-list | import-route-target-list | vpn-name vpn-name [ local-ce | remote-ce ] ] |
Available in any view |
Display MPLS L2VPN forwarding information |
display mpls l2vpn forwarding-info [ vc-label ] interface interface-type interface-number [ | { begin | exclude | include } regular-expression ] |
Available in any view |
Display the MPLS L2VPN packet statistics of an interface |
display interface interface-type interface-number |
Available in any view |
Resetting BGP L2VPN Connections
To do… |
Use the command… |
Remarks |
Reset BGP L2VPN connections |
reset bgp l2vpn { as-number | ip-address | all | external | internal } |
Available in user view |
MPLS L2VPN Configuration Examples
Example for Configuring a Remote CCC Connection
Network requirements
l The CEs are connected to the PEs through VLAN interfaces.
l A remote CCC connection is created between CE 1 and CE 2.
The main steps for configuring a CCC remote connection are:
l Create remote CCC connections on the PEs. No static LSP is required on the PEs.
l Configure two static LSPs on the P device for packets to be transferred in both directions.
Network diagram
Figure 1-3 Network diagram for configuring a remote CCC connection
Device |
Interface |
IP address |
Device |
Interface |
IP address |
CE 1 |
Vlan-int10 |
100.1.1.1/24 |
P |
Loop0 |
10.0.0.2/32 |
PE 1 |
Loop0 |
10.0.0.1/32 |
|
Vlan-int20 |
10.2.2.2/24 |
|
Vlan-int30 |
10.1.1.1/24 |
|
Vlan-int30 |
10.1.1.2/24 |
CE 2 |
Vlan-int10 |
100.1.1.2/24 |
PE 2 |
Loop0 |
10.0.0.3/32 |
|
|
|
|
Vlan-int10 |
10.2.2.1/24 |
Configuration procedure
1) Configure CE 1
<Sysname> system-view
[Sysname] sysname CE1
[CE1] interface vlan-interface 10
[CE1-Vlan-interface10] ip address 100.1.1.1 24
2) Configure PE 1
# Configure the LSR ID and enable MPLS globally.
<Sysname> system-view
[Sysname] sysname PE1
[PE1] interface loopback 0
[PE1-LoopBack0] ip address 10.0.0.1 32
[PE1-LoopBack0] quit
[PE1] mpls lsr-id 10.0.0.1
[PE1] mpls
[PE1-mpls] quit
# Enable MPLS L2VPN globally.
[PE1] mpls l2vpn
# Configure interface VLAN-interface 30 and enable MPLS.
[PE1] interface vlan-interface 30
[PE1-Vlan-interface30] ip address 10.1.1.1 24
[PE1-Vlan-interface30] mpls
[PE1-Vlan-interface30] quit
# Create a remote connection from CE 1 to CE 2, using the interface connecting CE 1 as the incoming interface and that connecting the P device as the outgoing interface, setting the incoming label to 100 and the outgoing label to 200.
[PE1] ccc ce1-ce2 interface vlan-interface 10 in-label 100 out-label 200 next-hop 10.1.1.2
3) Configure the P device
# Configure the LSR ID and enable MPLS globally.
<Sysname> system-view
[Sysname] sysname P
[P] interface loopback 0
[P-LoopBack0] ip address 10.0.0.2 32
[P-LoopBack0] quit
[P] mpls lsr-id 10.0.0.2
[P] mpls
[P-mpls] quit
# Configure interface VLAN-interface 30 and enable MPLS.
[P] interface vlan-interface 30
[P-Vlan-interface30] ip address 10.1.1.2 24
[P-Vlan-interface30] mpls
[P-Vlan-interface30] quit
# Configure interface VLAN-interface 20 and enable MPLS.
[P] interface vlan-interface 20
[P-Vlan-interface20] ip address 10.2.2.2 24
[P-Vlan-interface20] mpls
[P-Vlan-interface20] quit
# Create a static LSP for forwarding packets from PE 1 to PE 2.
[P] static-lsp transit pe1_pe2 incoming-interface vlan-interface 10 in-label 200 next-hop 10.2.2.1 out-label 201
# Create a static LSP for forwarding packets from PE 2 to PE 1.
[P] static-lsp transit pe2_pe1 incoming-interface vlan-interface 20 in-label 101 next-hop 10.1.1.1 out-label 100
4) Configure PE 2
# Configure the LSR ID and enable MPLS globally.
<Sysname> system-view
[Sysname] sysname PE2
[PE2] interface loopback 0
[PE2-LoopBack0] ip address 10.0.0.3 32
[PE2-LoopBack0] quit
[PE2] mpls lsr-id 10.0.0.3
[PE2] mpls
[PE2-mpls] quit
# Enable MPLS L2VPN globally.
[PE2] mpls l2vpn
# Configure interface VLAN-interface 10.
[PE2] interface vlan-interface 10
[PE2-Vlan-interface20] quit
# Configure interface VLAN-interface 20 and enable MPLS.
[PE2] interface vlan-interface 20
[PE2-Vlan-interface20] ip address 10.2.2.1 24
[PE2-Vlan-interface20] mpls
[PE2-Vlan-interface20] quit
# Create a remote connection from CE 2 to CE 1, using the interface connecting CE 2 as the incoming interface and that connecting the P device as the outgoing interface, setting the incoming label to 201 and the outgoing label to 101.
[PE2] ccc ce2-ce1 interface vlan-interface 10 in-label 201 out-label 101 next-hop 10.2.2.2
5) Configure CE 2
<Sysname> system-view
[Sysname] sysname CE2
[CE2] interface vlan-interface 10
[CE2-Vlan-interface10] ip address 100.1.1.2 24
6) Verify your configuration
After completing the above configurations, you can display CCC connection information on PE 1. There should be one local CCC connection established. CE 1 and CE 2 should be able to ping each other.
# Display CCC connection information on PE 1.
[PE1] display ccc
Total ccc vc : 1
Local ccc vc : 0, 0 up
Remote ccc vc : 1, 1 up
***Name : ce1-ce2
Type : remote
State : up
Intf : Vlan-interface10 (up)
In-label : 100
Out-label : 200
Nexthop : 10.1.1.2
# Ping CE 2 from CE 1.
[CE1] ping 100.1.1.2
PING 100.1.1.2: 56 data bytes, press CTRL_C to break
Reply from 100.1.1.2: bytes=56 Sequence=1 ttl=255 time=180 ms
Reply from 100.1.1.2: bytes=56 Sequence=2 ttl=255 time=60 ms
Reply from 100.1.1.2: bytes=56 Sequence=3 ttl=255 time=10 ms
Reply from 100.1.1.2: bytes=56 Sequence=4 ttl=255 time=70 ms
Reply from 100.1.1.2: bytes=56 Sequence=5 ttl=255 time=60 ms
--- 100.1.1.2 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 10/76/180 ms
Example for Configuring SVC MPLS L2VPN
Network requirements
l CEs are connected to PEs through VLAN interfaces.
l An SVC MPLS L2VPN is established between CE 1 and CE 2.
Network diagram
Figure 1-4 Network diagram for configuring SVC MPLS L2VPN
Device |
Interface |
IP address |
Device |
Interface |
IP address |
CE 1 |
Vlan-int10 |
100.1.1.1/24 |
P |
Loop0 |
192.4.4.4/32 |
PE 1 |
Loop0 |
192.2.2.2/32 |
|
Vlan-int30 |
10.2.2.2/24 |
|
Vlan-int20 |
10.1.1.1/24 |
|
Vlan-int20 |
10.1.1.2/24 |
CE 2 |
Vlan-int10 |
100.1.1.2/24 |
PE 2 |
Loop0 |
192.3.3.3/32 |
|
|
|
|
Vlan-int30 |
10.2.2.1/24 |
Configuration procedure
The main steps are the following two:
l Configure MPLS basic forwarding capability on the PEs and P device. This includes configuring the LSR ID, enabling MPLS and LDP, and running IGP (OSPF in this example) between PE 1, the P device, and PE 2 to establish LSPs.
l Establish an SVC MPLS L2VPN connection. This includes enabling MPLS L2VPN on PE 1 and PE 2 and establishing an SVC connection and specifying the VC labels.
The detailed configuration procedure is as follows:
1) Configure CE 1
<Sysname> system-view
[Sysname] sysname CE1
[CE1] interface vlan-interface 10
[CE1-Vlan-interface10] ip address 100.1.1.1 24
2) Configure PE 1
# Configure the LSR ID and enable MPLS globally.
<Sysname> system-view
[Sysname] sysname PE1
[PE1] interface loopback 0
[PE1-LoopBack0] ip address 192.2.2.2 32
[PE1-LoopBack0] quit
[PE1] mpls lsr-id 192.2.2.2
[PE1] mpls
# Configure the LSP establishment triggering policy.
[PE1-mpls] lsp-trigger all
[PE1-mpls] quit
# Enable MPLS L2VPN and LDP globally.
[PE1] mpls l2vpn
[PE1] mpls ldp
[PE1-mpls-ldp] quit
# Configure the interface connected with the P device, namely VLAN-interface 20, and enable LDP on the interface.
[PE1] interface vlan-interface 20
[PE1-Vlan-interface20] ip address 10.1.1.1 24
[PE1-Vlan-interface20] mpls
[PE1-Vlan-interface20] mpls ldp
[PE1-Vlan-interface20] quit
# Configure OSPF on PE 1 for establishing LSPs.
[PE1] ospf
[PE1-ospf-1] area 0
[PE1-ospf-1-area-0.0.0.0] network 10.1.1.1 0.0.0.255
[PE1-ospf-1-area-0.0.0.0] network 192.2.2.2 0.0.0.0
[PE1-ospf-1-area-0.0.0.0] quit
[PE1-ospf-1] quit
# On the interface connecting CE 1, namely VLAN-interface 10, create an SVC MPLS L2VPN connection. The interface requires no IP address.
[PE1] interface vlan-interface 10
[PE1-Vlan-interface10] mpls static-l2vc destination 192.3.3.3 transmit-vpn-label 100 receive-vpn-label 200
[PE1-Vlan-interface10] quit
3) Configure the P device
# Configure the LSR ID and enable MPLS globally.
<Sysname> system-view
[Sysname] sysname P
[P] interface loopback 0
[P-LoopBack0] ip address 192.4.4.4 32
[P-LoopBack0] quit
[P] mpls lsr-id 192.4.4.4
[P] mpls
# Configure the LSP establishment triggering policy.
[P-mpls] lsp-trigger all
[P-mpls] quit
# Enable LDP globally.
[P] mpls ldp
[P-mpls-ldp] quit
# Configure the interface connected with PE 1, namely VLAN-interface 20, and enable LDP on the interface.
[P] interface vlan-interface 20
[P-Vlan-interface20] ip address 10.1.1.2 24
[P-Vlan-interface20] mpls
[P-Vlan-interface20] mpls ldp
[P-Vlan-interface20] quit
# Configure the interface connected with PE 2, namely VLAN-interface 30, and enable LDP on the interface.
[P] interface vlan-interface 30
[P-Vlan-interface30] link-protocol ppp
[P-Vlan-interface30] ip address 10.2.2.2 24
[P-Vlan-interface30] mpls
[P-Vlan-interface30] mpls ldp
[P-Vlan-interface30] quit
# Configure OSPF on the P device for establishing LSPs.
[P] ospf
[P-ospf-1] area 0
[P-ospf-1-area-0.0.0.0] network 10.1.1.2 0.0.0.255
[P-ospf-1-area-0.0.0.0] network 10.2.2.2 0.0.0.255
[P-ospf-1-area-0.0.0.0] network 192.4.4.4 0.0.0.0
[P-ospf-1-area-0.0.0.0] quit
[P-ospf-1] quit
4) Configure PE 2
# Configure the LSR ID and enable MPLS globally.
<Sysname> system-view
[Sysname] sysname PE2
[PE2] interface loopback 0
[PE2-LoopBack0] ip address 192.3.3.3 32
[PE2-LoopBack0] quit
[PE2] mpls lsr-id 192.3.3.3
[PE2] mpls
# Configure the LSP establishment triggering policy.
[PE2-mpls] lsp-trigger all
[PE2-mpls] quit
# Enable MPLS L2VPN and LDP globally.
[PE2] mpls l2vpn
[PE2] mpls ldp
[PE2-mpls-ldp] quit
# Configure the interface connected with the P device, namely VLAN-interface 30, and enable LDP on the interface.
[PE2] interface vlan-interface 30
[PE2-Vlan-interface30] ip address 10.2.2.1 24
[PE2-Vlan-interface30] mpls
[PE2-Vlan-interface30] mpls ldp
[PE2-Vlan-interface30] quit
# Configure OSPF on PE 2 for establishing LSPs.
[PE2] ospf
[PE2-ospf-1] area 0
[PE2-ospf-1-area-0.0.0.0] network 10.2.2.1 0.0.0.255
[PE2-ospf-1-area-0.0.0.0] network 192.3.3.3 0.0.0.0
[PE2-ospf-1-area-0.0.0.0] quit
[PE2-ospf-1] quit
# On the interface connecting CE 2, namely VLAN-interface 10, create an SVC MPLS L2VPN connection. The interface requires no IP address.
[PE2] interface vlan-interface 10
[PE2-Vlan-interface10] mpls static-l2vc destination 192.2.2.2 transmit-vpn-label 200 receive-vpn-label 100
[PE2-Vlan-interface10] quit
5) Configure CE 2
<Sysname> system-view
[Sysname] sysname CE2
[CE2] interface vlan-interface 10
[CE2-Vlan-interface10] ip address 100.1.1.2 24
6) Verify your configuration
After completing the above configurations, you can display SVC L2VPN connection information on PE 1 or PE 2. There should be one L2VPN connection established. CE 1 and CE 2 should be able to ping each other.
# Display SVC L2VPN connection information on PE 1.
[PE1] display mpls static-l2vc
Total connections: 1, 1 up, 0 down
ce-intf state destination tr-label rcv-label tnl-policy
Vlan10 up 192.3.3.3 100 200 default
# Display SVC L2VPN connection information on PE 2.
[PE2] display mpls static-l2vc
Total connections: 1, 1 up, 0 down
ce-intf state destination tr-label rcv-label tnl-policy
Vlan20 up 192.2.2.2 200 100 default
# Ping CE 2 from CE 1.
[CE1] ping 100.1.1.2
PING 100.1.1.2: 56 data bytes, press CTRL_C to break
Reply from 100.1.1.2: bytes=56 Sequence=1 ttl=255 time=150 ms
Reply from 100.1.1.2: bytes=56 Sequence=2 ttl=255 time=130 ms
Reply from 100.1.1.2: bytes=56 Sequence=3 ttl=255 time=130 ms
Reply from 100.1.1.2: bytes=56 Sequence=4 ttl=255 time=140 ms
Reply from 100.1.1.2: bytes=56 Sequence=5 ttl=255 time=80 ms
--- 100.1.1.2 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 80/126/150 ms
Example for Configuring Martini MPLS L2VPN
Network requirements
l CEs are connected to PEs through VLAN interfaces.
l A Martini MPLS L2VPN is established between CE 1 and CE 2.
Network diagram
Figure 1-5 Network diagram for configuring Martini MPLS L2VPN
Device |
Interface |
IP address |
Device |
Interface |
IP address |
CE 1 |
Vlan-int10 |
100.1.1.1/24 |
P |
Loop0 |
192.4.4.4/32 |
PE 1 |
Loop0 |
192.2.2.2/32 |
|
Vlan-int20 |
10.1.1.2/24 |
|
Vlan-int20 |
10.1.1.1/24 |
|
Vlan-int30 |
10.2.2.2/24 |
CE 2 |
Vlan-int10 |
100.1.1.2/24 |
PE 2 |
Loop0 |
192.3.3.3/32 |
|
|
|
|
Vlan-int30 |
10.2.2.1/24 |
Configuration procedure
1) Configure CE 1
<Sysname> system-view
[Sysname] sysname CE1
[CE1] interface vlan-interface 10
[CE1-Vlan-interface10] ip address 100.1.1.1 24
2) Configure PE 1
# Configure the LSR ID and enable MPLS globally.
<Sysname> system-view
[Sysname] sysname PE1
[PE1] interface loopback 0
[PE1-LoopBack0] ip address 192.2.2.2 32
[PE1-LoopBack0] quit
[PE1] mpls lsr-id 192.2.2.2
[PE1] mpls
# Configure the LSP establishment triggering policy.
[PE1-mpls] lsp-trigger all
[PE1-mpls] quit
# Enable MPLS L2VPN and LDP globally.
[PE1] mpls l2vpn
[PE1] mpls ldp
[PE1-mpls-ldp] quit
# Establish a remote session between PE 1 and PE 2.
[PE1] mpls ldp remote-peer 1
[PE1-mpls-ldp-remote-1] remote-ip 192.3.3.3
[PE1-mpls-ldp-remote-1] quit
# Configure the interface connected with the P device, namely VLAN-interface 20, and enable LDP on the interface.
[PE1] interface vlan-interface 20
[PE1-Vlan-interface20] ip address 10.1.1.1 24
[PE1-Vlan-interface20] mpls
[PE1-Vlan-interface20] mpls ldp
[PE1-Vlan-interface20] quit
# Configure OSPF on PE 1 for establishing LSPs.
[PE1] ospf
[PE1-ospf-1] area 0
[PE1-ospf-1-area-0.0.0.0] network 10.1.1.1 0.0.0.255
[PE1-ospf-1-area-0.0.0.0] network 192.2.2.2 0.0.0.0
[PE1-ospf-1-area-0.0.0.0] quit
[PE1-ospf-1] quit
# On the interface connecting CE 1, namely VLAN-interface 10, create a Martini MPLS L2VPN connection. The interface requires no IP address.
[PE1] interface vlan-interface 10
[PE1-Vlan-interface10] mpls l2vc 192.3.3.3 101
[PE1-Vlan-interface10] quit
3) Configure the P device
# Configure the LSR ID and enable MPLS globally.
<Sysname> system-view
[Sysname] sysname P
[P] interface loopback 0
[P-LoopBack0] ip address 192.4.4.4 32
[P-LoopBack0] quit
[P] mpls lsr-id 192.4.4.4
[P] mpls
# Configure the LSP establishment triggering policy.
[P-mpls] lsp-trigger all
[P-mpls] quit
# Enable LDP globally.
[P] mpls ldp
[P-mpls-ldp] quit
# Configure the interface connected with PE 1, namely VLAN-interface 20, and enable LDP on the interface.
[P] interface vlan-interface 20
[P-Vlan-interface20] ip address 10.1.1.2 24
[P-Vlan-interface20] mpls
[P-Vlan-interface20] mpls ldp
[P-Vlan-interface20] quit
# Configure the interface connected with PE 2, namely VLAN-interface 30, and enable LDP on the interface.
[P] interface vlan-interface 30
[P-Vlan-interface30] ip address 10.2.2.2 24
[P-Vlan-interface30] mpls
[P-Vlan-interface30] mpls ldp
[P-Vlan-interface30] quit
# Configure OSPF on the P device for establishing LSPs.
[P] ospf
[P-ospf-1] area 0
[P-ospf-1-area-0.0.0.0] network 10.1.1.2 0.0.0.255
[P-ospf-1-area-0.0.0.0] network 10.2.2.2 0.0.0.255
[P-ospf-1-area-0.0.0.0] network 192.4.4.4 0.0.0.0
[P-ospf-1-area-0.0.0.0] quit
[P-ospf-1] quit
4) Configure PE 2
# Configure the LSR ID and enable MPLS globally.
<Sysname> system-view
[Sysname] sysname PE2
[PE2] interface loopback 0
[PE2-LoopBack0] ip address 192.3.3.3 32
[PE2-LoopBack0] quit
[PE2] mpls lsr-id 192.3.3.3
[PE2] mpls
# Configure the LSP establishment triggering policy.
[PE2-mpls] lsp-trigger all
[PE2-mpls] quit
# Enable MPLS L2VPN and LDP globally.
[PE2] mpls l2vpn
[PE2] mpls ldp
[PE2-mpls-ldp] quit
# Configure an LDP remote session between PE 2 and PE 1.
[PE2] mpls ldp remote-peer 2
[PE2-mpls-ldp-remote-2] remote-ip 192.2.2.2
[PE2-mpls-ldp-remote-2] quit
# Configure the interface connected with the P device, namely VLAN-interface 30, and enable LDP on the interface.
[PE2] interface vlan-interface 30
[PE2-Vlan-interface30] ip address 10.2.2.1 24
[PE2-Vlan-interface30] mpls
[PE2-Vlan-interface30] mpls ldp
[PE2-Vlan-interface30] quit
# Configure OSPF on PE 2 for establishing LSPs.
[PE2] ospf
[PE2-ospf-1] area 0
[PE2-ospf-1-area-0.0.0.0] network 192.3.3.3 0.0.0.0
[PE2-ospf-1-area-0.0.0.0] network 10.2.2.0 0.0.0.255
[PE2-ospf-1-area-0.0.0.0] quit
[PE2-ospf-1] quit
# On the interface connecting CE 2, namely VLAN-interface 10, create a L2VPN connection. The interface requires no IP address.
[PE2] interface vlan-interface 10
[PE2-Vlan-interface10] mpls l2vc 192.2.2.2 101
[PE2-Vlan-interface10] quit
5) Configure CE 2
<Sysname> system-view
[Sysname] sysname CE2
[CE2] interface vlan-interface 10
[CE2-Vlan-interface10] ip address 100.1.1.2 24
6) Verify your configuration
After completing the above configurations, you can display L2VPN connection information on PE 1 or PE 2. There should be one L2VC established. CE 1 and CE 2 should be able to ping each other.
# Display L2VPN connection information on PE 1.
[PE1] display mpls l2vc
Total ldp vc : 1 1 up 0 down
Transport Client VC Local Remote Tunnel
VC ID Intf State VC Label VC Label Policy
101 Vlan10 up 8193 8192 default
# Display L2VPN connection information on PE 2.
[PE2] display mpls l2vc
Total ldp vc : 1 1 up 0 down
Transport Client VC Local Remote Tunnel
VC ID Intf State VC Label VC Label Policy
101 Vlan10 up 8192 8193 default
# Ping CE 2 from CE 1.
[CE1] ping 100.1.1.2
PING 100.1.1.2: 56 data bytes, press CTRL_C to break
Reply from 100.1.1.2: bytes=56 Sequence=1 ttl=255 time=30 ms
Reply from 100.1.1.2: bytes=56 Sequence=2 ttl=255 time=60 ms
Reply from 100.1.1.2: bytes=56 Sequence=3 ttl=255 time=50 ms
Reply from 100.1.1.2: bytes=56 Sequence=4 ttl=255 time=40 ms
Reply from 100.1.1.2: bytes=56 Sequence=5 ttl=255 time=70 ms
--- 100.1.1.2 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 30/50/70 ms
Example for Configuring Kompella MPLS L2VPN
Network requirements
l CEs are connected to PEs through VLAN interfaces.
l A Kompella MPLS L2VPN is established between CE 1 and CE 2.
Network diagram
Figure 1-6 Network diagram for configuring Kompella MPLS L2VPN
Device |
Interface |
IP address |
Device |
Interface |
IP address |
CE 1 |
Vlan-int10 |
100.1.1.1/24 |
P |
Loop0 |
3.3.3.3/32 |
PE 1 |
Loop0 |
2.2.2.2/32 |
|
Vlan-int20 |
10.1.1.2/24 |
|
Vlan-int20 |
10.1.1.1/24 |
|
Vlan-int30 |
10.2.2.2/24 |
CE 2 |
Vlan-int10 |
100.1.1.2/24 |
PE 2 |
Loop0 |
4.4.4.4/32 |
|
|
|
|
Vlan-int30 |
10.2.2.1/24 |
Configuration procedure
1) Configure IGP on the MPLS backbone
This example uses OSPF. The detailed configuration steps are omitted.
After configuration, issuing the display ip routing-table command on each LSR, you should see that it has learned the routes to the LSR IDs of the other LSRs. Issuing the display ospf peer command, you should see that OSPF adjacencies have been established and reached the state of Full.
2) Configure MPLS basic capability and LDP to establish LDP LSPs
The detailed configuration steps are omitted.
After configuration, you can issue the display mpls ldp session and display mpls ldp peer commands to view the LDP sessions and peer relationship established, or the display mpls lsp command to view the LSPs established.
3) Configure BGP L2VPN capability
# Configure PE 1.
<Sysname> system-view
[Sysname] sysname PE1
[PE1] mpls l2vpn
[PE1] bgp 100
[PE1-bgp] peer 4.4.4.4 as-number 100
[PE1-bgp] peer 4.4.4.4 connect-interface loopback 0
[PE1-bgp] l2vpn-family
[PE1-bgp-af-l2vpn] policy vpn-target
[PE1-bgp-af-l2vpn] peer 4.4.4.4 enable
[PE1-bgp-af-l2vpn] quit
[PE1-bgp] quit
# Configure PE 2.
<Sysname> system-view
[Sysname] sysname PE2
[PE2] mpls l2vpn
[PE2] bgp 100
[PE2-bgp] peer 2.2.2.2 as-number 100
[PE2-bgp] peer 2.2.2.2 connect-interface loopback 0
[PE2-bgp] l2vpn-family
[PE2-bgp-af-l2vpn] policy vpn-target
[PE2-bgp-af-l2vpn] peer 2.2.2.2 enable
[PE2-bgp-af-l2vpn] quit
[PE2-bgp] quit
After completing the above configurations, you can issue the display bgp l2vpn peer command on PE 1 and PE 2 to view the peer relationship established between the PEs. The status should be Established. The following takes PE 1 as an example:
[PE1] display bgp l2vpn peer
BGP local router ID : 2.2.2.2
Local AS number : 100
Total number of peers : 1 Peers in established state : 1
Peer V AS MsgRcvd MsgSent OutQ PrefRcv Up/Down State
4.4.4.4 4 100 2 5 0 0 00:01:07 Established
4) Configure the L2VPN and the CE connection
# Configure PE 1. The configurations of the VLAN interfaces are similar to those for Martini MPLS L2VPN and are omitted.
[PE1] mpls l2vpn vpn1 encapsulation vlan
[PE1-mpls-l2vpn-vpn1] route-distinguisher 100:1
[PE1-mpls-l2vpn-vpn1] vpn-target 1:1
[PE1-mpls-l2vpn-vpn1] ce ce1 id 1 range 10
[PE1-mpls-l2vpn-ce-vpn1-ce1] connection ce-offset 2 interface vlan-interface 10
[PE1-mpls-l2vpn-ce-vpn1-ce1] quit
[PE1-mpls-l2vpn-vpn1] quit
# Configure PE 2.
[PE2] mpls l2vpn vpn1 encapsulation vlan
[PE2-mpls-l2vpn-vpn1] route-distinguisher 100:1
[PE2-mpls-l2vpn-vpn1] vpn-target 1:1
[PE2-mpls-l2vpn-vpn1] ce ce2 id 2 range 10
[PE2-mpls-l2vpn-ce-vpn1-ce2] connection ce-offset 1 interface vlan-interface 10
[PE2-mpls-l2vpn-ce-vpn1-ce2] quit
[PE2-mpls-l2vpn-vpn1] quit
5) Verify your configuration
After completing the above configurations, you can issue the display mpls l2vpn connection command on the PEs. You should see that an L2VPN connection is established between the PEs and the connection is up. CE 1 and CE 2 should be able to ping each other. The following takes PE 1 as an example:
# Display the MPLS L2VPN connection information on PE 1.
[PE1] display mpls l2vpn connection
1 total connections,
connections: 1 up, 0 down, 0 local, 1 remote, 0 unknown
VPN name: vpn1,
1 total connections,
connections: 1 up, 0 down, 0 local, 1 remote, 0 unknown
CE name: ce1, id: 1,
Rid type status peer-id route-distinguisher intf
2 rmt up 4.4.4.4 100:1 Vlan10
# Ping CE 2 from CE 1.
[CE1] ping 100.1.1.2
PING 100.1.1.2: 56 data bytes, press CTRL_C to break
Reply from 100.1.1.2: bytes=56 Sequence=1 ttl=255 time=90 ms
Reply from 100.1.1.2: bytes=56 Sequence=2 ttl=255 time=77 ms
Reply from 100.1.1.2: bytes=56 Sequence=3 ttl=255 time=34 ms
Reply from 100.1.1.2: bytes=56 Sequence=4 ttl=255 time=46 ms
Reply from 100.1.1.2: bytes=56 Sequence=5 ttl=255 time=94 ms
--- 100.1.1.2 ping statistics ---
5 packet(s) transmitted
5 packet(s) received
0.00% packet loss
round-trip min/avg/max = 34/68/94 ms
Troubleshooting MPLS L2VPN
Symptom:
After the L2VPN configuration, the peer PEs cannot ping each other. The output of the display mpls l2vc command shows that the VC is down and the remote VC label is invalid.
Analysis:
The reason the VC is down may be that the PEs are configured with different encapsulation types.
Solution:
l Check whether the local PE and the peer PE are configured with the same encapsulation type. If not, the connection is destined to fail.
l Check whether the PEs are configured with the Remote argument and whether the peer addresses are correctly configured.