06-IP Multicast Configuration Guide

HomeSupportResource CenterConfigure & DeployConfiguration GuidesH3C S12500-X & S12500X-AF Switch Series Configuration Guides(R115x)-6W10206-IP Multicast Configuration Guide
03-Multicast routing and forwarding configuration

Configuring multicast routing and forwarding

Overview

The following tables are involved in multicast routing and forwarding:

·          Multicast routing table of each multicast routing protocol, such as the PIM routing table.

·          General multicast routing table that summarizes multicast routing information generated by different multicast routing protocols. The multicast routing information from multicast sources to multicast groups are stored in a set of (S, G) routing entries.

·          Multicast forwarding table that guides multicast forwarding. The optimal routing entries in the multicast routing table are added to the multicast forwarding table.

The term "interface" in this chapter collectively refers to VLAN interfaces and Layer 3 Ethernet interfaces. You can set an Ethernet port as a Layer 3 interface by using the port link-mode route command (see Layer 2—LAN Switching Configuration Guide).

RPF check mechanism

A multicast routing protocol creates multicast routing entries based on the existing unicast routes or static multicast routes. During the process, the reverse path forwarding (RPF) check mechanism ensures the multicast data delivery along the correct paths and avoids data loops.

A multicast routing protocol uses the following tables to perform an RPF check:

·          Unicast routing table—Contains unicast routing information.

·          Static multicast routing table—Contains RPF routes that are manually configured.

Static multicast routing table is used for RPF check rather than multicast routing.

RPF check process

A multicast router performs the RPF check on a multicast packet as follows:

1.        The router chooses an optimal route back to the packet source separately from the unicast routing table and the static multicast routing table.

The term "packet source" means different things in different situations:

¡  For a packet that travels along the SPT, the packet source is the multicast source.

¡  For a packet that travels along the RPT, the packet source is the RP.

¡  For a bootstrap message originated from the BSR, the packet source is the BSR.

For more information about the concepts of SPT, RPT, source-side RPT, RP, and BSR, see "Configuring PIM."

2.        The router selects one of the two optimal routes as the multicast RPF route as follows:

¡  If the router uses the longest prefix match principle, the route with higher subnet mask becomes the RPF route. If the routes have the same mask, the route with higher route preference becomes the RPF route. If the routes have the same route preference, the unicast route becomes the RPF route.

For more information about the route preference, see Layer 3—IP Routing Configuration Guide.

¡  If the router does not use the longest prefix match principle, the route with higher route preference becomes the RPF route. If the routes have the same preference, the unicast route becomes the RPF route.

The RPF route contains the RPF interface and RPF neighbor information.

¡  If the RPF route is a unicast route, the outgoing interface is the RPF interface and the next hop is the RPF neighbor.

¡  If the RPF route is a static multicast route, the RPF interface and RPF neighbor are specified in the route.

3.        The router checks whether the packet arrived at the RPF interface. If yes, the RPF check succeeds and the packet is forwarded. If not, the RPF check fails and the packet is discarded.

RPF check implementation in multicast

Implementing an RPF check on each received multicast packet brings a big burden to the router. The use of a multicast forwarding table is the solution to this issue. When the router creates a multicast forwarding entry for a multicast packet, it sets the RPF interface of the packet as the incoming interface of the forwarding entry. After the router receives a multicast packet on an interface, it looks up its multicast forwarding table for a matching entry as follows:

·          If no match is found, the router first determines the RPF route back to the packet source. Then, it creates a forwarding entry with the RPF interface as the incoming interface and performs one of the following actions:

¡  If the receiving interface is the RPF interface, the RPF check succeeds and the router forwards the packet out of all the outgoing interfaces.

¡  If the receiving interface is not the RPF interface, the RPF check fails and the router discards the packet.

·          If a match is found and the receiving interface that received the packet is the incoming interface of the forwarding entry, the router forwards the packet out of all the outgoing interfaces.

·          If a match is found but the receiving interface is not the incoming interface of the forwarding entry, the router first determines the RPF route back to the packet source. Then, the router performs one of the following actions:

¡  If the RPF interface is the incoming interface, the forwarding entry is correct but the packet traveled along a wrong path. The router discards the packet.

¡  If the RPF interface is not the incoming interface, the forwarding entry has expired. The router replaces the incoming interface with the RPF interface. In this case, if the receiving interface is the RPF interface, the router forwards the packet out of all outgoing interfaces. Otherwise, it discards the packet.

Figure 1 RPF check process

 

As shown in Figure 1, assume that unicast routes are available in the network, and no static multicast routes have been configured on Switch C. A multicast packet (S, G) travels along the SPT from the multicast source to the receivers. The multicast forwarding table on Switch C contains the (S, G) entry, with VLAN-interface 20 as the incoming interface.

·          If a multicast packet arrives at Switch C on VLAN-interface 20, the receiving interface is the incoming interface of the (S, G) entry. Switch C forwards the packet out of all outgoing interfaces.

·          If a multicast packet arrives at Switch C on VLAN-interface 20, the receiving interface is not the incoming interface of the (S, G) entry. Switch C looks up its unicast routing table and finds that the outgoing interface to the source is VLAN-interface 20. It means that the (S, G) entry is correct, but the packet traveled along a wrong path. The packet fails the RPF check and Switch C discards the packet.

Static multicast routes

Depending on the application environment, a static multicast route can change an RPF route or create an RPF route.

Changing an RPF route

Typically, the topology structure of a multicast network is the same as that of a unicast network, and multicast traffic follows the same transmission path as unicast traffic does. You can configure a static multicast route for a multicast source to change the RPF route. In this way, the router creates a transmission path for multicast traffic that is different from the transmission path for unicast traffic.

Figure 2 Changing an RPF route

 

As shown in Figure 2, when no static multicast route is configured, Switch C's RPF neighbor on the path back to the source is Switch A. The multicast data from the source travels through Switch A to Switch C. You can configure a static multicast route on Router C and specify Router B as Router C's RPF neighbor on the path back to the source. The multicast data from the source will travel along the path: Switch A to Switch B and then to Switch C.

Creating an RPF route

When a unicast route is blocked, multicast forwarding might be stopped due to lack of an RPF route. You can configure a static multicast route for a multicast source to create an RPF route. In this way, a multicast routing entry is created to guide multicast forwarding.

Figure 3 Creating an RPF route

 

As shown in Figure 3, the RIP domain and the OSPF domain are unicast isolated from each other. For the receiver hosts in the OSPF domain to receive multicast packets from the multicast source in the RIP domain, you must configure Switch C and Switch D as follows:

·          On Switch C, configure a static multicast route for the multicast source and specify Switch B as the RPF neighbor.

·          On Switch D, configure a static multicast route for the multicast source and specify Switch C as the RPF neighbor.

 

 

NOTE:

A static multicast route takes effect only on the multicast router on which it is configured, and will not be advertised throughout the network or redistributed to other routers.

 

Configuration task list

Tasks at a glance

(Required.) Enabling IP multicast routing

(Optional.) Configuring multicast routing and forwarding:

·         (Optional.) Configuring static multicast routes

·         (Optional.) Specifying the longest prefix match principle

·         (Optional.) Configuring multicast load splitting

·         (Optional.) Configuring a multicast forwarding boundary

·         (Optional.) Configuring static multicast MAC address entries

·         (Optional.) Setting the hardware resource multicast mode

 

 

NOTE:

The device can route and forward multicast data only through the primary IP addresses of interfaces, rather than their secondary addresses or unnumbered IP addresses. For more information about primary and secondary IP addresses, and IP unnumbered, see Layer 3—IP Services Configuration Guide.

 

Enabling IP multicast routing

Enable IP multicast routing before you configure any Layer 3 multicast functionality on the public network or VPN instance.

To enable IP multicast routing:

 

Step

Command

Remarks

1.       Enter system view.

system-view

N/A

2.       Enable IP multicast routing and enter MRIB view.

multicast routing [ vpn-instance vpn-instance-name ]

By default, IP multicast routing is disabled.

 

Configuring multicast routing and forwarding

Before you configure multicast routing and forwarding, complete the following tasks:

·          Configure a unicast routing protocol so that all devices in the domain are interoperable at the network layer.

·          Enable PIM-DM or PIM-SM.

Configuring static multicast routes

To configure a static multicast route for a multicast source, you can specify an RPF interface or an RPF neighbor for the multicast traffic from that source.

To configure a static multicast route:

 

Step

Command

Remarks

1.       Enter system view.

system-view

N/A

2.       Configure a static multicast route.

ip rpf-route-static  [ vpn-instance vpn-instance-name ] source-address { mask-length | mask } { rpf-nbr-address | interface-type interface-number } [ preference preference ]

By default, no static multicast route exists.

3.       (Optional.) Delete static multicast routes.

·         Delete a specific static multicast route:
undo ip rpf-route-static [ vpn-instance vpn-instance-name ]
source-address { mask-length | mask } { rpf-nbr-address | interface-type interface-number }

·         Delete all static multicast routes:
delete ip rpf-route-static
[ vpn-instance vpn-instance-name ]

N/A

 

Specifying the longest prefix match principle

You can configure the switch to use the longest prefix match principle for RPF route selection. For more information about RPF route selection, see "RPF check process."

To specify the longest prefix match principle:

 

Step

Command

Remarks

1.       Enter system view.

system-view

N/A

2.       Enter MRIB view.

multicast routing [ vpn-instance vpn-instance-name ]

N/A

3.       Specify the longest prefix match principle.

longest-match

By default, the route preference principle is used.

 

Configuring multicast load splitting

You can enable the switch to split multiple data flows on a per-source basis or on a per-source-and-group basis. This optimizes the traffic delivery.

To configure multicast load splitting:

 

Step

Command

Remarks

1.       Enter system view.

system-view

N/A

2.       Enter MRIB view.

multicast routing [ vpn-instance vpn-instance-name ]

N/A

3.       Configure multicast load splitting.

load-splitting { source | source-group }

By default, multicast load splitting is disabled.

 

Configuring a multicast forwarding boundary

You can configure an interface as a multicast forwarding boundary for a multicast group range. The interface cannot receive or forward multicast packets for the group range.

 

TIP:

You do not need to enable IP multicast routing before this configuration.

 

To configure a multicast forwarding boundary:

 

Step

Command

Remarks

1.       Enter system view.

system-view

N/A

2.       Enter interface view.

interface interface-type interface-number

N/A

3.       Configure the interface as a multicast forwarding boundary for a multicast group range.

multicast boundary group-address { mask-length | mask }

By default, the interface is not configured as a multicast forwarding boundary.

 

Configuring static multicast MAC address entries

In Layer 2 multicast, multicast MAC address entries can be dynamically created or added through Layer 2 multicast protocols (such as IGMP snooping). You can also manually configure static multicast MAC address entries to bind multicast MAC addresses and ports to control the destination ports of the multicast data.

 

TIP

TIP:

·      You do not need to enable IP multicast routing before this configuration.

·      The multicast MAC address that can be manually configured in a multicast MAC address entry must be an unused multicast MAC address except 0100-5Exx-xxxx. The octet x represents any hexadecimal number from 0 to F. A multicast MAC address is the MAC address in which the least significant bit of the most significant octet is 1.

 

You can configure static multicast MAC address entries on the specified interface in system view, or on the current interface in interface view.

To configure a static multicast MAC address entry in system view:

 

Step

Command

Remarks

1.       Enter system view.

system-view

N/A

2.       Configure a static multicast MAC address entry.

mac-address multicast mac-address interface interface-list vlan vlan-id

By default, no static multicast MAC address entries exist.

 

To configure a static multicast MAC address entry in interface view:

 

Step

Command

Remarks

1.       Enter system view.

system-view

N/A

2.       Enter Ethernet interface/Layer 2 aggregate interface view.

interface interface-type interface-number

N/A

3.       Configure a static multicast MAC address entry.

mac-address multicast mac-address vlan vlan-id

By default, no static multicast MAC address entries exist.

 

Setting the hardware resource multicast mode

Hardware resource multicast has the following modes:

·          Normal—The switching fabric modules replicate multicast and broadcast traffic to all LPUs. This mode consumes a large amount of bandwidth.

·          EnhanceThe switching fabric modules replicate multicast traffic only to LPUs that join the associated multicast groups.

For this feature to take effect, you must save the configuration and reboot the switch.

To set the hardware resource multicast mode:

 

Step

Command

Remarks

1.       Enter system view.

system-view

N/A

2.       Set the hardware resource multicast mode.

hardware-resource mcast { normal | enhance }

By default, the hardware resource multicast mode is normal.

For this command to take effect, you must save the configuration and reboot the switch.

 

Displaying and maintaining multicast routing and forwarding

CAUTION:

The reset commands might cause multicast data transmission failures.

 

Execute display commands in any view and reset commands in user view.

 

Task

Command

Display static multicast MAC address entries.

display mac-address [ mac-address [ vlan vlan-id ] | [ multicast ] [ vlan vlan-id ] [ count ] ]

Display information about the interfaces maintained by the MRIB.

display mrib [ vpn-instance vpn-instance-name ] interface [ interface-type interface-number ]

Display multicast boundary information.

display multicast [ vpn-instance vpn-instance-name ] boundary [ group-address [ mask-length | mask ] ] [ interface interface-type interface-number ]

Display statistics for multicast forwarding events (in standalone mode).

display multicast [ vpn-instance vpn-instance-name ] forwarding event [ slot slot-number ]

Display statistics for multicast forwarding events (in IRF mode).

display multicast [ vpn-instance vpn-instance-name ] forwarding event [ chassis chassis-number slot slot-number ]

Display multicast forwarding entries (in standalone mode).

display multicast [ vpn-instance vpn-instance-name ] forwarding-table [ source-address [ mask { mask-length | mask } ] | group-address [ mask { mask-length | mask } ] | incoming-interface interface-type interface-number | outgoing-interface { exclude | include | match } interface-type interface-number | slot slot-number | statistics ] *

Display multicast forwarding entries (in IRF mode).

display multicast [ vpn-instance vpn-instance-name ] forwarding-table [ source-address [ mask { mask-length | mask } ] | group-address [ mask { mask-length | mask } ] | chassis chassis-number slot slot-number | incoming-interface interface-type interface-number | outgoing-interface { exclude | include | match } interface-type interface-number | statistics ] *

Display multicast routing entries.

display multicast [ vpn-instance vpn-instance-name ] routing-table [ source-address [ mask { mask-length | mask } ] | group-address [ mask { mask-length | mask } ] | incoming-interface interface-type interface-number | outgoing-interface { exclude | include | match } interface-type interface-number ] *

Display static multicast routing entries.

display multicast [ vpn-instance vpn-instance-name ] routing-table static [ source-address { mask-length | mask } ]

Display RPF route information for a multicast source.

display multicast [ vpn-instance vpn-instance-name ] rpf-info source-address [ group-address ]

Clear statistics for multicast forwarding events.

reset multicast [ vpn-instance vpn-instance-name ] forwarding event

Clear multicast forwarding entries.

reset multicast [ vpn-instance vpn-instance-name ] forwarding-table { { source-address [ mask { mask-length | mask } ] | group-address [ mask { mask-length | mask } ] | incoming-interface { interface-type interface-number } } * | all }

Clear multicast routing entries.

reset multicast [ vpn-instance vpn-instance-name ] routing-table { { source-address [ mask { mask-length | mask } ] | group-address [ mask { mask-length | mask } ] | incoming-interface interface-type interface-number } * | all }

 

 

NOTE:

·      When you delete a multicast routing entry, the associated forwarding entry is also removed.

·      When you delete a multicast forwarding entry, the associated routing entry is also removed.

 

Configuration examples

Changing an RPF route

Network requirements

As shown in Figure 4:

·          PIM-DM runs in the network.

·          All switches in the network support multicast.

·          Switch A, Switch B and Switch C run OSPF.

·          Typically, the receiver host can receive the multicast data from the source through the path: Switch A to Switch B, which is the same as the unicast route.

Configure the switches so that the multicast data from Source travels to the receiver along the following path: Switch A to Switch C to Switch B. This is different than the unicast route.

Figure 4 Network diagram

 

Configuration procedure

1.        Assign an IP address and subnet mask to each interface according to Figure 4. (Details not shown.)

2.        Enable OSPF on the switches in the PIM-DM domain to make sure the following conditions are met: (Details not shown.)

¡  The switches are interoperable at the network layer.

¡  The switches can dynamically update their routing information.

3.        Enable IP multicast routing, and enable IGMP and PIM-DM:

# On Switch B, enable IP multicast routing.

<SwitchB> system-view

[SwitchB] multicast routing

[SwitchB-mrib] quit

# Enable IGMP on the receiver-side interface (VLAN-interface 100).

[SwitchB] interface vlan-interface 100

[SwitchB-Vlan-interface100] igmp enable

[SwitchB-Vlan-interface100] quit

# Enable PIM-DM on the other interfaces.

[SwitchB] interface vlan-interface 101

[SwitchB-Vlan-interface101] pim dm

[SwitchB-Vlan-interface101] quit

[SwitchB] interface vlan-interface 102

[SwitchB-Vlan-interface102] pim dm

[SwitchB-Vlan-interface102] quit

# On Switch A, enable IP multicast routing, and enable PIM-DM on each interface.

<SwitchA> system-view

[SwitchA] multicast routing

[SwitchA-mrib] quit

[SwitchA] interface vlan-interface 200

[SwitchA-Vlan-interface200] pim dm

[SwitchA-Vlan-interface200] quit

[SwitchA] interface vlan-interface 102

[SwitchA-Vlan-interface102] pim dm

[SwitchA-Vlan-interface102] quit

[SwitchA] interface vlan-interface 103

[SwitchA-Vlan-interface103] pim dm

[SwitchA-Vlan-interface103] quit

# Enable IP multicast routing and PIM-DM on Switch C in the same way Switch A is configured. (Details not shown.)

4.        Display the RPF route to Source on Switch B.

[SwitchB] display multicast rpf-info 50.1.1.100

 RPF information about source 50.1.1.100:

     RPF interface: Vlan-interface102, RPF neighbor: 30.1.1.2

     Referenced route/mask: 50.1.1.0/24

     Referenced route type: igp

     Route selection rule: preference-preferred

     Load splitting rule: disable

The output shows that the current RPF route on Switch B is contributed by a unicast routing protocol and the RPF neighbor is Switch A.

5.        Configure a static multicast route on Switch B and specify Switch C as its RPF neighbor on the route to the source.

[SwitchB] ip rpf-route-static 50.1.1.100 24 20.1.1.2

Verifying the configuration

# Display RPF information for Source on Switch B.

[SwitchB] display multicast rpf-info 50.1.1.100

 RPF information about source 50.1.1.100:

     RPF interface: Vlan-interface101, RPF neighbor: 20.1.1.2

     Referenced route/mask: 50.1.1.0/24

     Referenced route type: multicast static

     Route selection rule: preference-preferred

     Load splitting rule: disable

The output shows the following information:

·          The RPF route on Switch B is the configured static multicast route.

·          The RPF neighbor of Switch B is Switch C.

Creating an RPF route

Network requirements

As shown in Figure 5:

·          PIM-DM runs in the network and all switches in the network support IP multicast.

·          Switch B and Switch C run OSPF, and have no unicast routes to Switch A.

·          Typically, the receiver host receives the multicast data from Source 1 in the OSPF domain.

Configure the switches so that the receiver host receives multicast data from Source 2, which is outside the OSPF domain.

Figure 5 Network diagram

 

Configuration procedure

1.        Assign an IP address and subnet mask to each interface according to Figure 5. (Details not shown.)

2.        Enable OSPF on Switch B and Switch C to make sure the following conditions are met: (Details not shown.)

¡  The switches are interoperable at the network layer.

¡  The switches can dynamically update their routing information.

3.        Enable IP multicast routing, and enable IGMP and PIM-DM:

# On Switch C, enable IP multicast routing.

<SwitchC> system-view

[SwitchC] multicast routing

[SwitchC-mrib] quit

# Enable IGMP on the receiver-side interface (VLAN-interface 100).

[SwitchC] interface vlan-interface 100

[SwitchC-Vlan-interface100] igmp enable

[SwitchC-Vlan-interface100] quit

# Enable PIM-DM on VLAN-interface 101.

[SwitchC] interface vlan-interface 101

[SwitchC-Vlan-interface101] pim dm

[SwitchC-Vlan-interface101] quit

# On Switch A, enable IP multicast routing, and enable PIM-DM on each interface.

<SwitchA> system-view

[SwitchA] multicast routing

[SwitchA-mrib] quit

[SwitchA] interface vlan-interface 300

[SwitchA-Vlan-interface300] pim dm

[SwitchA-Vlan-interface300] quit

[SwitchA] interface vlan-interface 102

[SwitchA-Vlan-interface102] pim dm

[SwitchA-Vlan-interface102] quit

# Enable IP multicast routing and PIM-DM on Switch B in the same way Switch A is configured. (Details not shown.)

4.        Display information about their RPF routes to Source 2 on Switch B and Switch C.

[SwitchB] display multicast rpf-info 50.1.1.100

[SwitchC] display multicast rpf-info 50.1.1.100

No output is displayed, because no RPF routes to the source 2 exist on Switch B or Switch C.

5.        Configure a static multicast route:

# Configure a static multicast route on Switch B, and specify Switch A as its RPF neighbor on the route to Source 2.

[SwitchB] ip rpf-route-static 50.1.1.100 24 30.1.1.2

# Configure a static multicast route on Switch C, and specify Switch B as its RPF neighbor on the route to Source 2.

[SwitchC] ip rpf-route-static 10.1.1.100 24 20.1.1.2

Verifying the configuration

# Display RPF information for Source 2 on Switch B and Switch C.

[SwitchB] display multicast rpf-info 50.1.1.100

 RPF information about source 50.1.1.100:

     RPF interface: Vlan-interface102, RPF neighbor: 30.1.1.2

     Referenced route/mask: 50.1.1.0/24

     Referenced route type: multicast static

     Route selection rule: preference-preferred

     Load splitting rule: disable

[SwitchC] display multicast rpf-info 50.1.1.100

 RPF information about source 50.1.1.100:

     RPF interface: Vlan-interface101, RPF neighbor: 20.1.1.2

     Referenced route/mask: 50.1.1.0/24

     Referenced route type: multicast static

     Route selection rule: preference-preferred

     Load splitting rule: disable

The output shows that the RPF routes to Source 2 exist on Switch B and Switch C. The routes are the configured static routes.

Troubleshooting multicast routing and forwarding

Static multicast route failure

Symptom

No dynamic routing protocol is enabled on the routers, and the physical status and link layer status of interfaces are both up, but the static multicast route fails.

Solution

To resolve the problem:

1.        Use the display multicast routing-table static command to display information about static multicast routes. Verify that the static multicast route has been correctly configured and the route entry exists in the static multicast routing table.

2.        Check the type of interface that connects to the RPF neighbor. If the interface is not a point-to-point interface, specify the RPF neighbor by its IP address in the static multicast route.

3.        If the problem persists, contact H3C Support.

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
All Support
  • Become a Partner
  • Partner Resources
  • Partner Business Management
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网