H3C Technologies H3C S12500 Series Switches User Manual

Page 293

Advertising
background image

277

[PE3-msdp] peer 1.1.1.2 connect-interface loopback 1

# Configure a static route.

[PE3] ip route-static 1.1.1.2 32 vlan-interface 3 192.168.1.1

# Configure BGP.

[PE3] bgp 200

[PE3-bgp] import-route ospf 1

[PE3-bgp] group pe3-pe4 internal

[PE3-bgp] peer pe3-pe4 route-policy map2 export

[PE3-bgp] peer pe3-pe4 label-route-capability

[PE3-bgp] peer pe3-pe4 connect-interface loopback 1

[PE3-bgp] peer 1.1.1.4 group pe3-pe4

[PE3-bgp] group pe3-pe2 external

[PE3-bgp] peer pe3-pe2 as-number 100

[PE3-bgp] peer pe3-pe2 route-policy map1 export

[PE3-bgp] peer pe3-pe2 label-route-capability

[PE3-bgp] peer pe3-pe2 connect-interface loopback 1

[PE3-bgp] peer 1.1.1.2 group pe3-pe2

[PE3–bgp] quit

# Configure OSPF.

[PE3] ospf 1

[PE3-ospf-1] area 0.0.0.0

[PE3-ospf-1-area-0.0.0.0] network 1.1.1.3 0.0.0.0

[PE3-ospf-1-area-0.0.0.0] network 22.22.22.22 0.0.0.0

[PE3-ospf-1-area-0.0.0.0] network 10.10.0.0 0.0.255.255

[PE3-ospf-1-area-0.0.0.0] quit

[PE3-ospf-1] quit

# Configure a routing policy.

[PE3] route-policy map1 permit node 10

[PE3-route-policy] apply mpls-label

[PE3-route-policy] quit

[PE3] route-policy map2 permit node 10

[PE3-route-policy] if-match mpls-label

[PE3-route-policy] apply mpls-label

[PE3-route-policy] quit

4.

Configure PE 4:
# Configure a Router ID, enable IP multicast routing on the public network, configure an MPLS LSR
ID, and enable the LDP capability.

<PE4> system-view

[PE4] router id 1.1.1.4

[PE4] multicast routing-enable

[PE4] mpls lsr-id 1.1.1.4

[PE4] mpls

[PE4-mpls] quit

[PE4] mpls ldp

[PE4-mpls-ldp] quit

Advertising