265
[PE4–bgp-default] address-family vpnv4
[PE4–bgp-default-vpnv4] peer 3.3.3.3 enable
[PE4–bgp-default-vpnv4] quit
[PE4-bgp-default] address-family ipv4 mdt
[PE4-bgp-default-mdt] peer 3.3.3.3 enable
[PE4-bgp-default-mdt] quit
[PE4–bgp-default] quit
# Configure OSPF.
[PE4] ospf 1
[PE4-ospf-1] area 0.0.0.0
[PE4-ospf-1-area-0.0.0.0] network 4.4.4.4 0.0.0.0
[PE4-ospf-1-area-0.0.0.0] network 10.5.1.0 0.0.0.255
[PE4-ospf-1-area-0.0.0.0] quit
[PE4-ospf-1] quit
[PE4] ospf 2 vpn-instance a
[PE4-ospf-2] area 0.0.0.0
[PE4-ospf-2-area-0.0.0.0] network 11.3.1.0 0.0.0.255
[PE4-ospf-2-area-0.0.0.0] quit
[PE4-ospf-2] quit
[PE4] ospf 3 vpn-instance b
[PE4-ospf-3] area 0.0.0.0
[PE4-ospf-3-area-0.0.0.0] network 11.4.1.0 0.0.0.255
[PE4-ospf-3-area-0.0.0.0] quit
[PE4-ospf-3] quit
5.
Configure P 1:
# Enable IP multicast routing on the public network.
<P1> system-view
[P1] multicast routing
[P1-mrib] quit
# Configure an LSR ID, and enable LDP globally.
[P1] mpls lsr-id 5.5.5.5
[P1] mpls ldp
[P1-ldp] quit
# Assign an IP address to VLAN-interface 2.
[P1] interface vlan-interface 2
[P1-Vlan-interface2] ip address 10.1.1.2 24
# Enable PIM-SM, MPLS, and IPv4 LDP on VLAN-interface 2.
[P1-Vlan-interface2] pim sm
[P1-Vlan-interface2] mpls enable
[P1-Vlan-interface2] mpls ldp enable
[P1-Vlan-interface2] quit
# Assign an IP address to VLAN-interface 3.
[P1] interface vlan-interface 3
[P1-Vlan-interface3] ip address 10.2.1.1 24
# Enable PIM-SM, MPLS, and IPv4 LDP on VLAN-interface 3.
[P1-Vlan-interface3] pim sm
[P1-Vlan-interface3] mpls enable
[P1-Vlan-interface3] mpls ldp enable