286
# Configure an IP address for Loopback 2, and enable PIM-SM.
[PE3] interface loopback 2
[PE3-LoopBack2] ip address 22.22.22.22 32
[PE3-LoopBack2] pim sm
[PE3-LoopBack2] quit
# Configure Loopback 2 as a C-BSR and a C-RP for the public network instance.
[PE3] pim
[PE3-pim] c-bsr loopback 2
[PE3-pim] c-rp loopback 2
[PE3-pim] quit
# Configure a BSR message boundary.
[PE3] interface vlan-interface 3
[PE3-Vlan-interface3] pim bsr-boundary
[PE3-Vlan-interface3] quit
# Establish an MSDP peering relationship.
[PE3] msdp
[PE3-msdp] encap-data-enable
[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