H3C Technologies H3C S6800 Series Switches User Manual
Page 364
351
[P-LoopBack0] ip address 192.4.4.4 32
[P-LoopBack0] quit
[P] mpls lsr-id 192.4.4.4
# Configure VLAN-interface 20 (the interface connected to PE 1), and enable MPLS on the
interface.
[P] interface vlan-interface 20
[P-Vlan-interface20] ip address 10.1.1.2 24
[P-Vlan-interface20] mpls enable
[P-Vlan-interface20] quit
# Configure VLAN-interface 30 (the interface connected to PE 2), and enable MPLS on the
interface.
[P] interface vlan-interface 30
[P-Vlan-interface30] ip address 10.2.2.2 24
[P-Vlan-interface30] mpls enable
[P-Vlan-interface30] quit
# Configure a static LSP to forward packets from PE 1 to PE 2.
[P] static-lsp transit pe1-pe2 in-label 201 nexthop 10.2.2.1 out-label 202
# Configure a static LSP to forward packets from PE 2 to PE 1.
[P] static-lsp transit pe2-pe1 in-label 102 nexthop 10.1.1.1 out-label 101
4.
Configure PE 2:
# Configure an LSR ID.
[PE2] interface loopback 0
[PE2-LoopBack0] ip address 192.3.3.3 32
[PE2-LoopBack0] quit
[PE2] mpls lsr-id 192.3.3.3
# Enable L2VPN.
[PE2] l2vpn enable
# Configure VLAN-interface 30 (the interface connected to P), and enable MPLS on the interface.
[PE2] interface vlan-interface 30
[PE2-Vlan-interface30] ip address 10.2.2.1 24
[PE2-Vlan-interface30] mpls enable
[PE2-Vlan-interface30] quit
# Create VLAN 10 and assign FortyGigE 1/0/1 to the VLAN.
[PE2] vlan 10
[PE2-vlan10] port fortygige 1/0/1
[PE2-vlan10] quit
# Create service instance 10 on FortyGigE 1/0/1 to match packets that have an outer VLAN ID
of 10.
[PE2] interface fortygige1/0/1
[PE2-FortyGigE1/0/1] service-instance 10
[PE2-FortyGigE1/0/1-srv10] encapsulation s-vid 10
[PE2-FortyGigE1/0/1-srv10] quit
[PE2-FortyGigE1/0/1] quit
# Create a cross-connect group named ccc, and create a remote CCC connection that has
incoming label 202, outgoing label 102, and next hop 10.2.2.2.