269
# Configure a Router ID, enable IP multicast routing on the public network, configure an MPLS
LSR ID, and enable the LDP capability.
<PE1> system-view
[PE1] router id 1.1.1.1
[PE1] multicast routing-enable
[PE1] mpls lsr-id 1.1.1.1
[PE1] mpls
[PE1-mpls] quit
[PE1] mpls ldp
[PE1-mpls-ldp] quit
# Create VPN instance a, configure an RD and route target attributes for it.
[PE1] ip vpn-instance a
[PE1-vpn-instance-a] route-distinguisher 100:1
[PE1-vpn-instance-a] vpn-target 100:1 export-extcommunity
[PE1-vpn-instance-a] vpn-target 100:1 import-extcommunity
# Enable IP multicast routing in VPN instance a, configure a share-group address, and
associate an MTI with the VPN instance.
[PE1-vpn-instance-a] multicast routing-enable
[PE1-vpn-instance-a] multicast-domain share-group 239.1.1.1 binding mtunnel 0
[PE1-vpn-instance-a] quit
# Create service loopback group 1, and specify its service type as
multicast tunnel
.
[PE1] service-loopback group 1 type multicast-tunnel
# Select an available port not in use, disable spanning tree protocols, LLDP and NDP on the
port, and add the port to service loopback group 1.
[PE1] interface gigabitethernet1/0/3
[PE1-GigabitEthernet1/0/3] undo stp enable
[PE1-GigabitEthernet1/0/3] undo ndp enable
[PE1-GigabitEthernet1/0/3] undo lldp enable
[PE1-GigabitEthernet1/0/3] port service-loopback group 1
[PE1-GigabitEthernet1/0/3] quit
# Configure an IP address, and enable PIM-SM and LDP capability on the public network
interface VLAN-interface 12.
[PE1] interface vlan-interface 12
[PE1-Vlan-interface12] ip address 192.168.6.1 24
[PE1-Vlan-interface12] pim sm
[PE1-Vlan-interface12] mpls
[PE1-Vlan-interface12] mpls ldp
[PE1-Vlan-interface12] quit
# Bind VLAN-interface 20 with VPN instance
a
, configure an IP address and enable IGMP and
PIM-SM on the interface.
[PE1] interface vlan-interface 20
[PE1-Vlan-interface20] ip binding vpn-instance a
[PE1-Vlan-interface20] ip address 10.110.1.1 24
[PE1-Vlan-interface20] igmp enable
[PE1-Vlan-interface20] pim sm
[PE1-Vlan-interface20] quit
# Bind VLAN-interface 11 with VPN instance
a
, configure an IP address and enable PIM-SM on
the interface.
[PE1] interface vlan-interface 11