- Table of Contents
-
- 08-IP Multicast Configuration Guide
- 00-Preface
- 01-Multicast Overview
- 02-IGMP Snooping Configuration
- 03-PIM Snooping Configuration
- 04-Multicast VLAN Configuration
- 05-Multicast Routing and Forwarding Configuration
- 06-IGMP Configuration
- 07-PIM Configuration
- 08-MSDP Configuration
- 09-MBGP Configuration
- 10-Multicast VPN Configuration
- 11-MLD Snooping Configuration
- 12-IPv6 PIM Snooping Configuration
- 13-IPv6 Multicast VLAN Configuration
- 14-IPv6 Multicast Routing and Forwarding Configuration
- 15-MLD Configuration
- 16-IPv6 PIM Configuration
- 17-IPv6 MBGP Configuration
- Related Documents
-
Title | Size | Download |
---|---|---|
11-MLD Snooping Configuration | 384.76 KB |
Contents
MLD snooping configuration task list
Configuring basic MLD snooping functions
Specifying MLD snooping version
Setting the maximum number of MLD snooping forwarding entries
Configuring MLD snooping port functions
Configuring aging timers for dynamic ports
Configuring a port as a simulated member host
Enabling MLD snooping fast-leave processing
Disabling a port from becoming a dynamic router port
Configuring MLD snooping querier
Configuring parameters for MLD queries and responses
Configuring the source IPv6 addresses for MLD queries
Configuring MLD snooping proxying
Enabling MLD snooping proxying
Configuring the source IPv6 address for the MLD messages sent by the proxy
Configuring an MLD snooping policy
Configuring an IPv6 multicast group filter
Configuring dropping unknown IPv6 multicast data
Enabling MLD report suppression
Setting the maximum number of multicast groups that a port can join
Enabling IPv6 multicast group replacement
Enabling the MLD snooping host tracking function
Displaying and maintaining MLD snooping
MLD snooping configuration examples
IPv6 group policy and simulated joining configuration example
Static port configuration example
MLD snooping querier configuration example
MLD snooping proxying configuration example
Layer 2 multicast forwarding cannot work
Configured IPv6 multicast group policy fails to take effect
Processing of IPv6 multicast protocol messages
Overview
As shown in Figure 1, when MLD snooping is not enabled, the Layer 2 switch floods IPv6 multicast packets to all hosts. When MLD snooping is enabled, the Layer 2 switch forwards multicast packets of known IPv6 multicast groups to only the receivers.
The term "router" in this document refers to both routers and Layer 3 switches.
Figure 1 Before and after MLD snooping is enabled on the Layer 2 device
MLD snooping enables the Layer 2 switch to forward IPv6 multicast data to only the receivers that require the data at Layer 2. It brings the following advantages:
· Reducing Layer 2 broadcast packets, thus saving network bandwidth
· Enhancing the security of multicast traffic
· Facilitating the implementation of per-host accounting
Basic MLD snooping concepts
MLD snooping related ports
As shown in Figure 2, MLD snooping runs on Switch A and Switch B, Host A and Host C are receivers in an IPv6 multicast group.
Figure 2 MLD snooping related ports
Ports involved in MLD snooping, as shown in Figure 2, are described as follows:
· Router port—Layer 3 multicast device-side port. Layer 3 multicast devices include designated routers and MLD queriers. In Figure 2, GigabitEthernet 3/0/1 of Switch A and GigabitEthernet 3/0/1 of Switch B are router ports. The switch registers all its local router ports in its router port list.
Do not confuse the "router port" in MLD snooping with the "routed interface" commonly known as the "Layer 3 interface." The router port in MLD snooping is a Layer 2 interface.
· Member port—Multicast receiver-side port. In Figure 2, GigabitEthernet 3/0/2 and GigabitEthernet 3/0/3 of Switch A and GigabitEthernet 3/0/2 of Switch B are member ports. The switch registers all the member ports on the local device in its MLD snooping forwarding table.
Unless otherwise specified, router ports and member ports in this document include both static and dynamic router ports and member ports.
|
NOTE: When MLD snooping is enabled, all ports that receive IPv6 PIM hello messages or MLD general queries with a source IP address other than 0::0 are considered dynamic router ports. For more information about IPv6 PIM hello messages, see "Configuring IPv6 PIM." |
Aging timers for dynamic ports in MLD snooping
Timer |
Description |
Message before expiration |
Action after expiration |
Dynamic router port aging timer. |
When a port receives an MLD general query with source address other than 0::0 or a PIM hello message, the switch starts or resets an aging timer for the port. When the timer expires, the dynamic router port ages out. |
MLD general query with the source address other than 0::0 or IPv6 PIM hello. |
The switch removes this port from its router port list. |
Dynamic member port aging timer. |
When a port dynamically joins a multicast group, the switch starts or resets an aging timer for the port. When the timer expires, the dynamic member port ages out. |
MLD report message. |
The switch removes this port from the MLD snooping forwarding table. |
|
NOTE: In MLD snooping, only dynamic ports age out. Static ports never age out. |
How MLD snooping operates
The ports in this section are dynamic ports. For information about how to configure and remove static ports, see "Configuring static ports."
MLD messages types are as follows: general query, MLD report, and done message. An MLD snooping-enabled switch performs differently depending on the MLD message.
General query
After receiving an MLD general query, the switch forwards it to all ports in the VLAN, except the port that received the query. The switch also performs one of the following actions:
· If the port that received the query is a dynamic router port in the router port list of the switch, the switch restarts the aging timer for the port.
· If the port is not in the router port list, the switch adds it into the router port list as a dynamic router port and starts an aging timer for the port.
MLD report
A host sends an MLD report to the MLD querier for the following purposes:
· Responds to queries if the host is an IPv6 multicast group member.
· Applies for an IPv6 multicast group membership.
After receiving an MLD report, the switch forwards it through all the router ports in the VLAN, resolves the address of the reported IPv6 multicast group, and performs one of the following actions:
· If no forwarding entry matches the group address, the switch creates a forwarding entry for the group, adds the port that received the MLD report as a dynamic member port to the forwarding entry for the group, and starts an aging timer for the port.
· If a forwarding entry matches the group address, but the port that received the MLD report is not in the forwarding entry for the group, the switch adds the port as a dynamic member port to the forwarding entry, and starts an aging timer for the port.
· If a forwarding entry matches the group address and the port that received the MLD report is in the forwarding entry for the group, the switch restarts the aging timer for the port.
A switch does not forward an MLD report through a non-router port. The reason is that if the switch forwards a report message through a member port, all the attached hosts that are listening to the reported IPv6 multicast address, according to the MLD report suppression mechanism, suppress their own reports after receiving this report. This prevents the switch from confirming whether the reported IPv6 multicast group still has active members attached to that port. For more information about the MLD report suppression mechanism, see "Configuring MLD."
Done message
When a host leaves an IPv6 multicast group, the host sends an MLD done message to the multicast routers. When the switch receives the MLD done message on a dynamic member port, the switch first checks whether a forwarding entry matches the IPv6 multicast group address in the message, and, if a match is found, whether the forwarding entry contains the dynamic member port.
· If no forwarding entry matches the IPv6 multicast group address, or if the forwarding entry does not contain the port, the switch directly discards the MLD done message.
· If a forwarding entry matches the IPv6 multicast group address and contains the port, the switch forwards the done message to all router ports in the native VLAN. Because the switch does not know whether any other hosts attached to the port are still listening to that IPv6 multicast group address, the switch does not immediately remove the port from the forwarding entry for that group. Instead, it restarts the aging timer for the port.
After receiving the MLD done message, the MLD querier resolves the IPv6 multicast group address in the message and sends an MLD multicast-address-specific query to that IPv6 multicast group through the port that received the MLD done message. After receiving the MLD multicast-address-specific query, the switch forwards it through all its router ports in the VLAN and all member ports of the IPv6 multicast group. The switch also performs the following judgment for the port that received the MLD done message:
· If the port (assuming that it is a dynamic member port) receives an MLD report in response to the MLD multicast-address-specific query before its aging timer expires, it indicates that some host attached to the port is receiving or expecting to receive IPv6 multicast data for that IPv6 multicast group. The switch restarts the aging timer for the port.
· If the port receives no MLD report in response to the MLD multicast-address-specific query before its aging timer expires, it indicates that no hosts attached to the port are still monitoring that IPv6 multicast group address. The switch removes the port from the forwarding entry for the IPv6 multicast group when the aging timer expires.
MLD snooping proxying
You can configure the MLD snooping proxying function on an edge device to reduce the number of MLD reports and done messages sent to its upstream device. The device configured with MLD snooping proxying is called an MLD snooping proxy. It is a host from the perspective of its upstream device.
|
NOTE: Even though an MLD snooping proxy is a host from the perspective of its upstream device, the MLD membership report suppression mechanism for hosts does not take effect on it. |
Figure 3 Network diagram for MLD snooping proxying
As shown in Figure 3, Switch A operates as an MLD snooping proxy. As a host from the perspective of the querier Router A, Switch A represents its attached hosts to send their membership reports and done messages to Router A.
Table 1 describes how an MLD snooping proxy processes MLD messages.
Table 1 MLD message processing on an MLD snooping proxy
MLD message |
Actions |
General query |
When receiving an MLD general query, the proxy forwards it to all ports but the port that received the query. In addition, the proxy generates a report according to the group memberships that it maintains and sends the report out of all router ports. |
Multicast-address-specific query |
In response to the MLD group-specific query for a certain IPv6 multicast group, the proxy sends the report to the group out of all router ports if the forwarding entry for the group still contains a member port. |
Report |
When receiving a report for an IPv6 multicast group, the proxy looks up the multicast forwarding table for the entry for the multicast group: · If a forwarding entry matches the IPv6 multicast group, and contains the receiving port as a dynamic member port, the proxy restarts the aging timer for the port. · If a forwarding entry matches the IPv6 multicast group but does not contain the receiving port, the proxy adds the port to the forwarding entry as a dynamic member port and starts an aging timer for the port. · If no forwarding entry matches the IPv6 multicast group, the proxy creates a forwarding entry for the group, adds the receiving port to the forwarding entry as a dynamic member port, and starts an aging timer for the port. Then, the switch sends the report to the group out of all router ports. |
Done |
In response to a done message for an IPv6 multicast group, the proxy sends a multicast-address-specific query for the group out of the receiving port. After making sure that no member port is contained in the forwarding entry for the IPv6 multicast group, the proxy sends a done message for the group out of all router ports. |
Protocols and standards
RFC 4541, Considerations for Internet Group Management Protocol (IGMP) and Multicast Listener Discovery (MLD) Snooping Switches
MLD snooping configuration task list
Task |
Remarks |
|
Required. |
||
Optional. |
||
Setting the maximum number of MLD snooping forwarding entries |
Optional. |
|
Optional. |
||
Optional. |
||
Optional. |
||
Optional. |
||
Optional. |
||
Optional. |
||
Optional. |
||
Optional. |
||
Optional. |
||
Configuring the source IPv6 address for the MLD messages sent by the proxy |
Optional. |
|
Optional. |
||
Optional. |
||
Optional. |
||
Setting the maximum number of multicast groups that a port can join |
Optional. |
|
Optional. |
||
Optional. |
For the configuration tasks in this section:
· The configurations made in MLD-snooping view take effect on all VLANs. The configurations made in VLAN view take effect on only the current VLAN. For a given VLAN, the configurations made in MLD-snooping view take effect only if you do not make the same configuration in VLAN view.
· The configurations made in MLD-snooping view take effect on all ports. The configurations made in Layer 2 Ethernet interface view or Layer 2 aggregate interface view take effect on only the current port. The configurations made in port group view take effect on only the ports in the current port group. For a given port, the configurations made in MLD-snooping view take effect only if you do not make the same configuration in Layer 2 Ethernet interface view, Layer 2 aggregate interface view, or port group view.
· For MLD snooping, the configurations made on a Layer 2 aggregate interface do not interfere with the configurations made on its member ports, nor do they participate in aggregation calculations. A configuration made on a member port of the aggregate group will take effect after the port leaves the aggregate group.
Configuring basic MLD snooping functions
Before you configure basic MLD snooping functions, complete the following tasks:
· Enable IPv6 forwarding.
· Configure the corresponding VLANs.
· Determine the version of MLD snooping.
Enabling MLD snooping
When you enable MLD snooping, follow these guidelines:
· You must enable MLD snooping globally before you enable it in a VLAN.
· If you enable MLD snooping for a VLAN, do not enable MLD or IPv6 PIM on the corresponding VLAN interface. If you enable MLD or IPv6 PIM for a VLAN interface, do not enable MLD snooping for the VLAN.
· MLD snooping for a VLAN works only on the ports in this VLAN.
To enable MLD snooping:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enable MLD snooping globally and enter MLD-snooping view. |
mld-snooping |
Disabled by default. |
3. Return to system view. |
quit |
N/A |
4. Enter VLAN view. |
vlan vlan-id |
N/A |
5. Enable MLD snooping in the VLAN. |
mld-snooping enable |
Disabled by default. |
Specifying MLD snooping version
Different versions of MLD snooping can process different versions of MLD messages:
· MLDv1 snooping can process MLDv1 messages, but flood MLDv2 messages in the VLAN instead of processing them.
· MLDv2 snooping can process MLDv1 and MLDv2 messages.
If you change MLDv2 snooping to MLDv1 snooping, the system does the following:
· Clears all MLD snooping forwarding entries that are dynamically created.
· Keeps static MLDv2 snooping forwarding entries (*, G).
· Clears static MLDv2 snooping forwarding entries (S, G), which will be restored when MLD snooping is switched back to MLDv2 snooping.
For more information about static MLD snooping forwarding entries, see "Configuring static ports."
To specify the version of MLD snooping:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter VLAN view. |
vlan vlan-id |
N/A |
3. Specify the version of MLD snooping. |
mld-snooping version version-number |
Version 1 by default. |
Setting the maximum number of MLD snooping forwarding entries
You can modify the maximum number of MLD snooping forwarding entries. When the number of forwarding entries on the device reaches the upper limit, the device gives a prompt asking you to manually remove the excessive entries. In this case, the device does not automatically remove any existing entries or create any new entries.
To set the maximum number of MLD snooping forwarding entries:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter MLD-snooping view. |
mld-snooping |
N/A |
3. Set the maximum number of MLD snooping forwarding entries. |
entry-limit limit |
2000 by default. |
Configuring MLD snooping port functions
Before you configure MLD snooping port functions, complete the following tasks:
· Enable MLD snooping in the VLAN.
· Configure the corresponding port groups.
· Determine the aging timer for dynamic router ports.
· Determine the aging timer for dynamic member ports.
· Determine the IPv6 multicast group and IPv6 multicast source addresses.
Configuring aging timers for dynamic ports
If a switch receives no MLD general queries or IPv6 PIM hello messages on a dynamic router port when the aging timer of the port expires, the switch removes the port from the router port list.
If the switch receives no MLD reports for an IPv6 multicast group on a dynamic member port when the aging timer of the port expires, the switch removes the port from the forwarding entry for the IPv6 multicast group.
If the memberships of IPv6 multicast groups change frequently, you can set a relatively small value for the aging timer of the dynamic member ports. If the memberships of IPv6 multicast groups change rarely, you can set a relatively large value.
Setting the global aging timers for dynamic ports
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter MLD-snooping view. |
mld-snooping |
N/A |
3. Set the global aging timer for dynamic router ports. |
router-aging-time interval |
260 seconds by default. |
4. Set the global aging timer for dynamic member ports. |
host-aging-time interval |
260 seconds by default. |
Setting the aging timers for the dynamic ports in a VLAN
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter VLAN view. |
vlan vlan-id |
N/A |
3. Set the aging timer for the dynamic router ports. |
mld-snooping router-aging-time interval |
260 seconds by default. |
4. Set the aging timer for the dynamic member ports. |
mld-snooping host-aging-time interval |
260 seconds by default. |
Configuring static ports
You can configure a port as a static router port, through which the switch can forward all IPv6 multicast data it received.
A static member port does not respond to queries from the MLD querier. When you configure a port as a static member port or cancel this configuration on the port, the port does not send an unsolicited MLD report or an MLD done message.
To configure static ports:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter Layer 2 Ethernet interface view or Layer 2 aggregate interface view, or enter port group view. |
· Enter Layer 2 Ethernet interface view or Layer
2 aggregate interface view: · Enter port group view: |
Use either method. |
3. Configure the port as a static member port. |
mld-snooping static-group ipv6-group-address [ source-ip ipv6-source-address ] vlan vlan-id |
No static member ports by default. |
4. Configure the port as a static router port. |
mld-snooping static-router-port vlan vlan-id |
No static router ports by default. |
|
NOTE: Static member ports and static router ports never age out. To remove such a port, you need to use the corresponding undo command. |
Configuring a port as a simulated member host
Generally, a host that runs MLD can respond to MLD queries. If a host fails to respond, the multicast router might deem that the IPv6 multicast group has no members on the subnet, and removes the corresponding forwarding path.
To avoid this situation, you can configure a port on the switch as a simulated member host for an IPv6 multicast group. When an MLD query is received, simulated host gives a response. Thus, the switch can continue receiving IPv6 multicast data.
A simulated host acts like a real host, as follows:
· If a port is configured as a simulated member host, the switch sends an unsolicited MLD report through the port, and can respond to MLD general queries with MLD reports through the port.
· If the simulated joining configuration is canceled on the port, the switch sends an MLD done message through that port.
To configure a port as a simulated member host:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter Layer 2 Ethernet interface view or Layer 2 aggregate interface view, or enter port group view. |
· Enter Layer 2 Ethernet interface view or Layer
2 aggregate interface view: · Enter port group view: |
Use either method. |
3. Configure the port as a simulated member host. |
mld-snooping host-join ipv6-group-address [ source-ip ipv6-source-address ] vlan vlan-id |
A port is not a simulated member host by default. |
|
NOTE: Unlike a static member port, a port configured as a simulated member host will age out like a dynamic member port. |
Enabling MLD snooping fast-leave processing
The MLD snooping fast-leave processing feature enables the switch to process MLD done messages quickly. After the MLD snooping fast-leave processing feature is enabled, when the switch receives an MLD done message on a port, it immediately removes that port from the forwarding entry for the multicast group specified in the message. Then, when the switch receives MLD multicast-address-specific queries for that multicast group, it does not forward them to that port.
On a port that has only one host attached, you can enable MLD snooping fast-leave processing to save bandwidth and resources. However, on a port that has multiple hosts attached, do not enable MLD snooping fast-leave processing if you have enabled dropping unknown IPv6 multicast data globally or for the port. Otherwise, if a host on the port leaves an IPv6 multicast group, the other hosts attached to the port in the same IPv6 multicast group cannot receive the IPv6 multicast data for the group.
Enabling MLD snooping fast-leave processing globally
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter MLD-snooping view. |
mld-snooping |
N/A |
3. Enable fast-leave processing. |
fast-leave [ vlan vlan-list ] |
Disabled by default. |
Enabling MLD snooping fast-leave processing on a port
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter Layer 2 Ethernet interface view or Layer 2 aggregate interface view, or enter port group view. |
· Enter Layer 2 Ethernet interface view or Layer
2 aggregate interface view: · Enter port group view: |
Use either method. |
3. Enable fast-leave processing. |
mld-snooping fast-leave [ vlan vlan-list ] |
Disabled by default. |
Disabling a port from becoming a dynamic router port
The following problems exist in a multicast access network:
· After receiving an MLD general query or IPv6 PIM hello message from a connected host, a router port becomes a dynamic router port. Before its timer expires, this dynamic router port will receive all multicast packets within the VLAN to which it belongs and forward then to the host, thus affecting normal multicast reception of the host.
· In addition, the MLD general query and IPv6 PIM hello message sent from the host affects the multicast routing protocol state on Layer 3 devices, such as the MLD querier or DR election, and might further cause network interruption.
To solve these problems, you can disable the router port from becoming a dynamic router port after receiving an MLD general query or IPv6 PIM hello message, so as to enhance network security and the control over multicast users.
To disable a port from becoming a dynamic router port:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter Layer 2 Ethernet interface view or Layer 2 aggregate interface view, or enter port group view. |
· Enter Layer 2 Ethernet interface view or Layer
2 aggregate interface view: · Enter port group view: |
Use either method. |
3. Disable the port from becoming a dynamic router port. |
mld-snooping router-port-deny [ vlan vlan-list ] |
By default, a port can become a dynamic router port. |
|
NOTE: This configuration does not affect the static router port configuration. |
Configuring MLD snooping querier
Before you configure MLD snooping querier, complete the following tasks:
· Enable MLD snooping in the VLAN.
· Determine the MLD general query interval.
· Determine the MLD last-listener query interval.
· Determine the maximum response delay for MLD general queries.
· Determine the source IPv6 address of MLD general queries.
· Determine the source IPv6 address of MLD multicast-address-specific queries.
Enabling MLD snooping querier
In an IPv6 multicast network that run MLD, a multicast router or Layer 3 multicast switch is responsible for sending MLD general queries periodically, so that all Layer 3 multicast devices can establish and maintain multicast forwarding entries, in order to forward multicast traffic correctly at the network layer. This router or Layer 3 switch is called the "MLD querier." For more information about MLD querier, see "Configuring MLD."
However, a Layer 2 multicast switch does not support MLD and it cannot send MLD general queries by default. In a network where multicast traffic is only switched at the data link layer and no Layer 3 multicast devices are present, you can enable MLD snooping querier on a Layer 2 switch so that the Layer 2 switch can send MLD queries periodically and establish and maintain multicast forwarding entries for IPv6 multicast forwarding at the data link layer.
|
IMPORTANT: Do not configure an MLD snooping querier in an IPv6 multicast network running MLD. Although an MLD snooping querier does not take part in MLD querier elections, it might affect MLD querier elections because it sends MLD general queries with a low source IPv6 address. |
To enable the MLD snooping querier:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter VLAN view. |
vlan vlan-id |
N/A |
3. Enable the MLD snooping querier. |
mld-snooping querier |
Disabled by default. |
Configuring parameters for MLD queries and responses
|
CAUTION: Make sure the MLD query interval is greater than the maximum response delay for MLD general queries. Otherwise, undesired deletion of IPv6 multicast members might occur. |
You can modify the MLD general query interval based on the actual condition of the network.
A multicast listening host starts a timer for each IPv6 multicast group that it has joined when it receives an MLD query (general query or multicast-address-specific query). This timer is initialized to a random value in the range of 0 to the maximum response delay advertised in the MLD query message. When the timer value decreases to 0, the host sends an MLD report to the IPv6 multicast group.
To speed up the response of hosts to MLD queries and avoid simultaneous timer expirations causing MLD report traffic bursts, you must correctly set the maximum response delay.
· The maximum response delay for MLD general queries is set by the max-response-time command.
· The maximum response delay for MLD multicast-address-specific queries equals the MLD last-listener query interval.
Configuring the global parameters for MLD queries and responses
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter MLD-snooping view. |
mld-snooping |
N/A |
3. Set the maximum response delay for MLD general queries. |
max-response-time interval |
10 seconds by default. |
4. Set the MLD last-listener query interval. |
last-listener-query-interval interval |
1 second by default. |
Configuring the parameters for MLD queries and responses in a VLAN
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter VLAN view. |
vlan vlan-id |
N/A |
3. Configure MLD query interval. |
mld-snooping query-interval interval |
125 seconds by default. |
4. Set the maximum response delay for MLD general queries. |
mld-snooping max-response-time interval |
10 seconds by default. |
5. Set the MLD last-listener query interval. |
mld-snooping last-listener-query-interval interval |
1 second by default. |
Configuring the source IPv6 addresses for MLD queries
|
CAUTION: The source IPv6 address of MLD queries might affect MLD querier election within the subnet. |
To configure the source IPv6 addresses for MLD queries:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter VLAN view. |
vlan vlan-id |
N/A |
3. Configure the source IPv6 address for MLD general queries. |
mld-snooping general-query source-ip { ipv6-address | current-interface } |
FE80::02FF:FFFF:FE00:0001 by default. |
4. Configure the source IPv6 address for MLD multicast-address-specific queries. |
mld-snooping special-query source-ip { ipv6-address | current-interface } |
FE80::02FF:FFFF:FE00:0001 by default. |
Configuring MLD snooping proxying
Before you configure MLD snooping proxying in a VLAN, complete the following tasks:
· Enable MLD snooping for the VLAN.
· Determine the source IPv6 address for the MLD reports sent by the proxy.
· Determine the source IPv6 address for the MLD done messages sent by the proxy.
Enabling MLD snooping proxying
The MLD snooping proxying function operates on a per-VLAN basis. After you enable the function in a VLAN, the device operates as the MLD snooping proxy for the downstream hosts and upstream router in the VLAN.
To enable MLD snooping proxying in a VLAN:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter VLAN view. |
vlan vlan-id |
N/A |
3. Enable MLD snooping proxying in the VLAN. |
mld-snooping proxying enable |
Disabled by default. |
Configuring the source IPv6 address for the MLD messages sent by the proxy
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter VLAN view. |
vlan vlan-id |
N/A |
3. Configure the source IPv6 address for the MLD reports sent by the proxy. |
mld-snooping report source-ip { ipv6-address | current-interface } |
The default is FE80::02FF:FFFF:FE00:0001. |
4. Configure the source IPv6 address for the MLD done messages sent by the proxy. |
mld-snooping done source-ip { ipv6-address | current-interface } |
The default is FE80::02FF:FFFF:FE00:0001. |
Configuring an MLD snooping policy
Before you configure an MLD snooping policy, complete the following tasks:
· Enable MLD snooping for the VLAN.
· Determine the IPv6 ACL for IPv6 multicast group filtering.
· Determine the maximum number of IPv6 multicast groups that a port can join.
Configuring an IPv6 multicast group filter
On a MLD snooping-enabled switch, you can configure an IPv6 multicast group filter to limit multicast programs available to different users.
In an application, when a user requests a multicast program, the user's host initiates an MLD report. After receiving this report message, the switch resolves the IPv6 multicast group address in the report and looks up the ACL. If a match is found to permit the port that received the report can join this IPv6 multicast group, the switch creates an MLD snooping forwarding entry for the IPv6 multicast group and adds the port to the entry. Otherwise, the switch drops this report message, in which case, the IPv6 multicast data for the IPv6 multicast group is not sent to this port, and the user cannot retrieve the program.
Configuring an IPv6 multicast group filter globally
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter MLD-snooping view. |
mld-snooping |
N/A |
3. Configure an IPv6 multicast group filter. |
group-policy acl6-number [ vlan vlan-list ] |
By default, no IPv6 group filter is globally configured, and the hosts in a VLAN can join any valid IPv6 multicast group. |
Configuring an IPv6 multicast group filter on a port
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter Layer 2 Ethernet interface view or Layer 2 aggregate interface view, or enter port group view. |
· Enter Layer 2 Ethernet interface view or Layer
2 aggregate interface view: · Enter port group view: |
Use either method. |
3. Configure an IPv6 multicast group filter on the port. |
mld-snooping group-policy acl6-number [ vlan vlan-list ] |
By default, no IPv6 group filter is configured for the port, and the hosts on the port can join any valid IPv6 multicast group. |
Configuring dropping unknown IPv6 multicast data
Unknown IPv6 multicast data refers to IPv6 multicast data for which no forwarding entries exist in the MLD snooping forwarding table. When the switch receives such IPv6 multicast traffic, one of the following occurs:
· When the function of dropping unknown IPv6 multicast data is disabled, the switch floods unknown IPv6 multicast data in the VLAN to which the data belongs.
· When the function of dropping unknown IPv6 multicast data is enabled, the switch drops all received unknown IPv6 multicast data.
To enable dropping unknown IPv6 multicast data in a VLAN:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter VLAN view. |
vlan vlan-id |
N/A |
3. Enable dropping unknown IPv6 multicast data. |
mld-snooping drop-unknown |
Disabled by default. |
|
NOTE: · After you enable dropping unknown IPv6 multicast data, the switch does not drop the unknown IPv6 multicast data with the multicast MAC address of 3333-0000-00xx or 3333-FFxx-xxxx (where x represents a hexadecimal number from 0 to F). Instead, the switch floods the IPv6 multicast data in the VLAN to which they belong. · After you enable dropping unknown IPv6 multicast data, the switch still forwards unknown IPv6 multicast data to other router ports in the VLAN. |
Enabling MLD report suppression
When a Layer 2 switch receives an MLD report from an IPv6 multicast group member, the Layer 2 switch forwards the message to the Layer 3 device that directly connects to the Layer 2 switch. When multiple members of an IPv6 multicast group are attached to the Layer 2 switch, the Layer 3 device might receive duplicate MLD reports for the IPv6 multicast group from these members.
With the MLD report suppression function enabled, within a query interval, the Layer 2 switch forwards only the first MLD report for the IPv6 multicast group to the Layer 3 device. It does not forward subsequent MLD reports for the same IPv6 multicast group to the Layer 3 device. This helps reduce the number of packets being transmitted over the network.
|
IMPORTANT: On an MLD snooping proxy, MLD membership reports are suppressed if the entries for the corresponding groups exist in the forwarding table, no matter the suppression function is enabled or not. |
To enable MLD report suppression:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter MLD-snooping view. |
mld-snooping |
N/A |
3. Enable MLD report suppression. |
report-aggregation |
Enabled by default. |
Setting the maximum number of multicast groups that a port can join
You can set the maximum number of IPv6 multicast groups that a port can join to regulate the traffic on the port.
When you configure this maximum number, if the number of IPv6 multicast groups the port has joined exceeds the configured maximum value, the system deletes all the forwarding entries for the port from the MLD snooping forwarding table, and the hosts on this port join IPv6 multicast groups again until the number of IPv6 multicast groups that the port joins reaches the maximum value. When the port joins an IPv6 multicast group, if the port has been configured as a static member port, the system applies the configurations to the port again. If you have configured simulated joining on the port, the system creates corresponding forwarding entry for the port after receiving a report from the simulated member host.
To set the maximum number of IPv6 multicast groups that a port can join:
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter Layer 2 Ethernet interface view or Layer 2 aggregate interface view, or enter port group view. |
· Enter Layer 2 Ethernet interface view or Layer
2 aggregate interface view: · Enter port group view: |
Use either method. |
3. Configure the maximum number of IPv6 multicast groups that a port can join. |
mld-snooping group-limit limit [ vlan vlan-list ] |
1024 by default. |
Enabling IPv6 multicast group replacement
For various reasons, the number of IPv6 multicast groups that a switch or a port can join might exceed the upper limit. In addition, in some specific applications, an IPv6 multicast group that the switch newly joins must replace an existing IPv6 multicast group automatically. A typical example is channel switching. To view a new TV channel, a user switches from the current IPv6 multicast group to the new one.
To realize such requirements, you can enable the IPv6 multicast group replacement function on the switch or on a certain port. When the number of IPv6 multicast groups that the switch or the port has joined reaches the limit, one of the following occurs:
· If the IPv6 multicast group replacement feature is disabled, new MLD reports are automatically discarded.
· If the IPv6 multicast group replacement feature is enabled, the IPv6 multicast group that the switch or the port newly joins automatically replaces an existing IPv6 multicast group that has the lowest IPv6 address.
|
IMPORTANT: To make the IPv6 multicast group replacement function take effect, configure the maximum number of IPv6 multicast groups that a port can join to a value other than the default one (see "Setting the maximum number of multicast groups that a port can join") before enabling IPv6 multicast group replacement. |
Enabling IPv6 multicast group replacement globally
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter MLD-snooping view. |
mld-snooping |
N/A |
3. Enable IPv6 multicast group replacement. |
overflow-replace [ vlan vlan-list ] |
Disabled by default. |
Enabling IPv6 multicast group replacement on a port
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter Layer 2 Ethernet interface view or Layer 2 aggregate interface view, or enter port group view. |
· Enter Layer 2 Ethernet interface view or Layer
2 aggregate interface view: · Enter port group view: |
Use either method. |
3. Enable IPv6 multicast group replacement. |
mld-snooping overflow-replace [ vlan vlan-list ] |
Disabled by default. |
Enabling the MLD snooping host tracking function
With the MLD snooping host tracking function, the switch can record the information of the member hosts that are receiving IPv6 multicast traffic, including the host IPv6 address, running duration, and timeout time. You can monitor and manage the member hosts according to the recorded information.
Enabling the MLD snooping host tracking function globally
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter MLD-snooping view. |
mld-snooping |
N/A |
3. Enable the MLD snooping host tracking function globally. |
host-tracking |
Disabled by default. |
Enabling the MLD snooping host tracking function in a VLAN
Step |
Command |
Remarks |
1. Enter system view. |
system-view |
N/A |
2. Enter VLAN view. |
vlan vlan-id |
N/A |
3. Enable the MLD snooping host tracking function in the VLAN. |
mld-snooping host-tracking |
Disabled by default. |
Displaying and maintaining MLD snooping
Task |
Command |
Remarks |
Display MLD snooping group information (in standalone mode). |
display mld-snooping group [ vlan vlan-id ] [ slot slot-number ] [ verbose ] [ | { begin | exclude | include } regular-expression ] |
Available in any view. |
Display MLD snooping group information (in IRF mode). |
display mld-snooping group [ vlan vlan-id ] [ chassis chassis-number slot slot-number ] [ verbose ] [ | { begin | exclude | include } regular-expression ] |
Available in any view. |
Display information about the hosts tracked by MLD snooping (in standalone mode). |
display mld-snooping host vlan vlan-id group ipv6-group-address [ source ipv6-source-address ] [ slot slot-number ] [ | { begin | exclude | include } regular-expression ] |
Available in any view. |
Display information about the hosts tracked by MLD snooping (in IRF mode). |
display mld-snooping host vlan vlan-id group ipv6-group-address [ source ipv6-source-address ] [ chassis chassis-number slot slot-number ] [ | { begin | exclude | include } regular-expression ] |
Available in any view. |
Display statistics for MLD messages learned through MLD snooping. |
display mld-snooping statistics [ | { begin | exclude | include } regular-expression ] |
Available in any view. |
Remove dynamic group entries of an MLD snooping group or all MLD snooping groups. |
reset mld-snooping group { ipv6-group-address | all } [ vlan vlan-id ] |
Available in user view. |
Clear statistics for all MLD messages learned through MLD snooping. |
reset mld-snooping statistics |
Available in user view. |
MLD snooping configuration examples
IMPORTANT: By default, Ethernet interfaces, VLAN interfaces, and aggregate interfaces are in the state of DOWN. To configure such an interface, use the undo shutdown commands to bring it up first. |
IPv6 group policy and simulated joining configuration example
Network requirements
As shown in Figure 4, MLDv1 runs on Router A, MLDv1 snooping required on Switch A, and Router A acts as the MLD querier on the subnet. The receivers, Host A and Host B can receive IPv6 multicast traffic addressed to IPv6 multicast group FF1E::101 only.
IPv6 multicast data for group FF1E::101 can be forwarded through GigabitEthernet 3/0/3 and GigabitEthernet 3/0/4 of Switch A even if Host A and Host B temporarily stop receiving IPv6 multicast data. Switch A drops unknown IPv6 multicast data and does not broadcast the data to the VLAN where Switch A resides.
Configuration procedure
1. Enable IPv6 forwarding and configure an IPv6 address and prefix length for each interface as shown in Figure 4. (Details not shown.)
2. On Router A, enable IPv6 multicast routing, enable IPv6 PIM-DM on each interface, and enable MLDv1 on GigabitEthernet 3/1/1.
<RouterA> system-view
[RouterA] multicast ipv6 routing-enable
[RouterA] interface GigabitEthernet 3/1/1
[RouterA-GigabitEthernet3/1/1] mld enable
[RouterA-GigabitEthernet3/1/1] pim ipv6 dm
[RouterA-GigabitEthernet3/1/1] quit
[RouterA] interface Gigabitethernet 3/1/2
[RouterA-GigabitEthernet3/1/2] pim ipv6 dm
[RouterA-GigabitEthernet3/1/2] quit
3. Configure Switch A:
# Enable MLD snooping globally.
<SwitchA> system-view
[SwitchA] mld-snooping
[SwitchA-mld-snooping] quit
# Create VLAN 100, assign GigabitEthernet 3/0/1 through GigabitEthernet 3/0/4 to this VLAN, and enable MLD snooping and the function of dropping IPv6 unknown multicast traffic in the VLAN.
[SwitchA] vlan 100
[SwitchA-vlan100] port GigabitEthernet 3/0/1 to GigabitEthernet 3/0/4
[SwitchA-vlan100] mld-snooping enable
[SwitchA-vlan100] mld-snooping drop-unknown
[SwitchA-vlan100] quit
# Configure an IPv6 multicast group filter so that the hosts in VLAN 100 can join only the IPv6 multicast group FF1E::101.
[SwitchA] acl ipv6 number 2001
[SwitchA-acl6-basic-2001] rule permit source ff1e::101 128
[SwitchA-acl6-basic-2001] quit
[SwitchA] mld-snooping
[SwitchA–mld-snooping] group-policy 2001 vlan 100
[SwitchA–mld-snooping] quit
# Configure GigabitEthernet 3/0/3 and GigabitEthernet 3/0/4 as simulated hosts for IPv6 multicast group FF1E::101.
[SwitchA] interface GigabitEthernet 3/0/3
[SwitchA-GigabitEthernet3/0/3] mld-snooping host-join ff1e::101 vlan 100
[SwitchA-GigabitEthernet3/0/3] quit
[SwitchA] interface GigabitEthernet 3/0/4
[SwitchA-GigabitEthernet3/0/4] mld-snooping host-join ff1e::101 vlan 100
[SwitchA-GigabitEthernet3/0/4] quit
Verifying the configuration
# Display the detailed MLD snooping group information in VLAN 100 on Switch A.
[SwitchA] display mld-snooping group vlan 100
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Port flags: D-Dynamic port, S-Static port, C-Copy port, P-PIM port
Subvlan flags: R-Real VLAN, C-Copy VLAN
Vlan(id):100.
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Router port(s):total 1 port(s).
GE3/0/1 (D)
IP group(s):the following ip group(s) match to one mac group.
IP group address:FF1E::101
(::, FF1E::101):
Attribute: Host Port
Host port(s):total 2 port(s).
GE3/0/3 (D)
GE3/0/4 (D)
MAC group(s):
MAC group address:3333-0000-0101
Host port(s):total 2 port(s).
GE3/0/3
GE3/0/4
The output shows that GigabitEthernet 3/0/3 and GigabitEthernet 3/0/4 of Switch A have joined IPv6 multicast group FF1E::101.
Static port configuration example
Network requirements
As shown in Figure 5, MLDv1 runs on Router A, and MLDv1 snooping runs on Switch A, Switch B and Switch C. Router A acts as the MLD querier.
Host A and host C are permanent receivers of IPv6 multicast group FF1E::101. GigabitEthernet 3/0/3 and GigabitEthernet 3/0/5 on Switch C are required to be configured as static member ports for multicast group FF1E::101 to enhance the reliability of multicast traffic transmission.
Suppose STP runs on the network. To avoid data loops, the forwarding path from Switch A to Switch C is blocked under normal conditions, and IPv6 multicast traffic flows to the receivers attached to Switch C only along the path of Switch A—Switch B—Switch C. Configure GigabitEthernet 3/0/3 on Switch C as a static router port, so that IPv6 multicast traffic can flow to the receivers nearly uninterruptedly along the path of Switch A—Switch C in the case that the path of Switch A—Switch B—Switch C is blocked.
|
NOTE: If no static router port is configured, when the path of Switch A—Switch B—Switch C gets blocked, at least one MLD query-response cycle must be completed before the IPv6 multicast data can flow to the receivers along the new path of Switch A—Switch C. IPv6 multicast delivery will be interrupted during this process. |
For more information about STP, see Layer 2—LAN Switching Configuration Guide.
Configuration procedure
1. Enable IPv6 forwarding and configure an IPv6 address and prefix length for each interface as shown in Figure 5.
2. On Router A, enable IPv6 multicast routing, enable IPv6 PIM-DM on each interface, and enable MLD on GigabitEthernet 3/1/1.
<RouterA> system-view
[RouterA] multicast ipv6 routing-enable
[RouterA] interface GigabitEthernet 3/1/1
[RouterA-GigabitEthernet3/1/1] mld enable
[RouterA-GigabitEthernet3/1/1] pim ipv6 dm
[RouterA-GigabitEthernet3/1/1] quit
[RouterA] interface Gigabitethernet 3/1/2
[RouterA-GigabitEthernet3/1/2] pim ipv6 dm
[RouterA-GigabitEthernet3/1/2] quit
3. Configure Switch A:
# Enable MLD snooping globally.
<SwitchA> system-view
[SwitchA] mld-snooping
[SwitchA-mld-snooping] quit
# Create VLAN 100, assign GigabitEthernet 3/0/1 through GigabitEthernet 3/0/3 to this VLAN, and enable MLD snooping in the VLAN.
[SwitchA] vlan 100
[SwitchA-vlan100] port GigabitEthernet 3/0/1 to GigabitEthernet 3/0/3
[SwitchA-vlan100] mld-snooping enable
[SwitchA-vlan100] quit
# Configure GigabitEthernet 3/0/3 to be a static router port.
[SwitchA] interface GigabitEthernet 3/0/3
[SwitchA-GigabitEthernet3/0/3] mld-snooping static-router-port vlan 100
[SwitchA-GigabitEthernet3/0/3] quit
4. Configure Switch B:
# Enable MLD snooping globally.
<SwitchB> system-view
[SwitchB] mld-snooping
[SwitchB-mld-snooping] quit
# Create VLAN 100, assign GigabitEthernet 3/0/1 and GigabitEthernet 3/0/2 to this VLAN, and enable MLD snooping in the VLAN.
[SwitchB] vlan 100
[SwitchB-vlan100] port GigabitEthernet 3/0/1 GigabitEthernet 3/0/2
[SwitchB-vlan100] mld-snooping enable
[SwitchB-vlan100] quit
5. Configure Switch C:
# Enable MLD snooping globally.
<SwitchC> system-view
[SwitchC] mld-snooping
[SwitchC-mld-snooping] quit
# Create VLAN 100, assign GigabitEthernet 3/0/1 through GigabitEthernet 3/0/5 to this VLAN, and enable MLD snooping in the VLAN.
[SwitchC] vlan 100
[SwitchC-vlan100] port GigabitEthernet 3/0/1 to GigabitEthernet 3/0/5
[SwitchC-vlan100] mld-snooping enable
[SwitchC-vlan100] quit
# Configure GigabitEthernet 3/0/3 and GigabitEthernet 3/0/5 as static member ports for IPv6 multicast group FF1E::101.
[SwitchC] interface GigabitEthernet 3/0/3
[SwitchC-GigabitEthernet3/0/3] mld-snooping static-group ff1e::101 vlan 100
[SwitchC-GigabitEthernet3/0/3] quit
[SwitchC] interface GigabitEthernet 3/0/5
[SwitchC-GigabitEthernet3/0/5] mld-snooping static-group ff1e::101 vlan 100
[SwitchC-GigabitEthernet3/0/5] quit
Verifying the configuration
# Display the detailed MLD snooping group information in VLAN 100 on Switch A.
[SwitchA] display mld-snooping group vlan 100 verbose
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Port flags: D-Dynamic port, S-Static port, C-Copy port, P-PIM port
Subvlan flags: R-Real VLAN, C-Copy VLAN
Vlan(id):100.
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Router port(s):total 2 port(s).
GE3/0/1 (D)
GE3/0/3 (S)
IP group(s):the following ip group(s) match to one mac group.
IP group address:FF1E::101
(::, FF1E::101):
Attribute: Host Port
Host port(s):total 1 port(s).
GE3/0/2 (D)
MAC group(s):
MAC group address:3333-0000-0101
Host port(s):total 1 port(s).
GE3/0/2
The output shows that GigabitEthernet 3/0/3 of Switch A has become a static router port.
# Display the detailed MLD snooping group information in VLAN 100 on Switch C.
[SwitchC] display mld-snooping group vlan 100 verbose
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Port flags: D-Dynamic port, S-Static port, C-Copy port, P-PIM port
Subvlan flags: R-Real VLAN, C-Copy VLAN
Vlan(id):100.
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Router port(s):total 1 port(s).
GE3/0/2 (D)
IP group(s):the following ip group(s) match to one mac group.
IP group address:FF1E::101
(::, FF1E::101):
Attribute: Host Port
Host port(s):total 2 port(s).
GE3/0/3 (S)
GE3/0/5 (S)
MAC group(s):
MAC group address:3333-0000-0101
Host port(s):total 2 port(s).
GE3/0/3
GE3/0/5
The output shows that GigabitEthernet 3/0/3 and GigabitEthernet 3/0/5 on Switch C have become static member ports for IPv6 multicast group FF1E::101.
MLD snooping querier configuration example
Network requirements
As shown in Figure 6, in a Layer-2-only network environment, Source 1 sends IPv6 multicast data to the multicast group FF1E::101, and Source 2 sends IPv6 multicast data to the multicast group FF1E::102. Host A and Host C are receivers of multicast group FF1E::101, and Host B and Host D are receivers of multicast group FF1E::102. MLDv1 runs on all the receivers and MLDv1 snooping runs on all the switches. Switch A, which is close to the multicast sources, is chosen as the MLD snooping querier.
To prevent flooding of IPv6 unknown multicast traffic within the VLAN, be sure to configure all the switches to drop IPv6 unknown multicast data packets.
Configuration procedure
1. Configure Switch A:
# Enable IPv6 forwarding and enable MLD snooping globally.
<SwitchA> system-view
[SwitchA] ipv6
[SwitchA] mld-snooping
[SwitchA-mld-snooping] quit
# Create VLAN 100 and assign GigabitEthernet 3/0/1 through GigabitEthernet 3/0/3 to VLAN 100.
[SwitchA] vlan 100
[SwitchA-vlan100] port GigabitEthernet 3/0/1 to GigabitEthernet 3/0/3
# Enable MLD snooping and the function of dropping unknown IPv6 multicast data packets in VLAN 100.
[SwitchA-vlan100] mld-snooping enable
[SwitchA-vlan100] mld-snooping drop-unknown
# Configure MLD snooping querier feature in VLAN 100.
[SwitchA-vlan100] mld-snooping querier
[SwitchA-vlan100] quit
2. Configure Switch B:
# Enable IPv6 forwarding and enable MLD snooping globally.
<SwitchB> system-view
[SwitchB] ipv6
[SwitchB] mld-snooping
[SwitchB-mld-snooping] quit
# Create VLAN 100, add GigabitEthernet 3/0/1 through GigabitEthernet 3/0/4 into VLAN 100.
[SwitchB] vlan 100
[SwitchB-vlan100] port GigabitEthernet 3/0/1 to GigabitEthernet 3/0/4
# Enable the MLD snooping feature and the function of dropping unknown IPv6 multicast data packets in VLAN 100.
[SwitchB-vlan100] mld-snooping enable
[SwitchB-vlan100] mld-snooping drop-unknown
[SwitchB-vlan100] quit
3. Configure Switch C and Switch D in the same way as you configure Switch B.
Verifying the configuration
When the MLD snooping querier starts to work, all the switches but the querier receive MLD general queries.
# Display the MLD message statistics on Switch B.
[SwitchB-vlan100] display mld-snooping statistics
Received MLD general queries:3.
Received MLDv1 specific queries:0.
Received MLDv1 reports:12.
Received MLD dones:0.
Sent MLDv1 specific queries:0.
Received MLDv2 reports:0.
Received MLDv2 reports with right and wrong records:0.
Received MLDv2 specific queries:0.
Received MLDv2 specific sg queries:0.
Sent MLDv2 specific queries:0.
Sent MLDv2 specific sg queries:0.
Received error MLD messages:0.
MLD snooping proxying configuration example
Network requirements
As shown in Figure 7, MLDv1 runs on Router A and MLDv1 snooping runs on Switch A. Router A acts as the MLD querier.
Configure MLD snooping proxying on Switch A, enabling the switch to forward MLD reports and done messages on behalf of attached hosts and to respond to MLD queries from Router A and forward the queries to the hosts on behalf of Router A.
Configuration procedure
1. Configure an IP address and prefix length for each interface as shown in Figure 7. (Details not shown.)
2. On Router A, enable IPv6 multicast routing, enable IPv6 PIM-DM on each interface, and enable MLD on port GigabitEthernet 3/1/1.
<RouterA> system-view
[RouterA] multicast ipv6 routing-enable
[RouterA] interface Gigabitethernet 3/1/1
[RouterA-GigabitEthernet3/1/1] mld enable
[RouterA-GigabitEthernet3/1/1] pim ipv6 dm
[RouterA-GigabitEthernet3/1/1] quit
[RouterA] interface Gigabitethernet 3/1/2
[RouterA-GigabitEthernet3/1/2] pim ipv6 dm
[RouterA-GigabitEthernet3/1/2] quit
3. Configure Switch A:
# Enable MLD snooping globally.
<SwitchA> system-view
[SwitchA] mld-snooping
[SwitchA-mld-snooping] quit
# Create VLAN 100, assign ports GigabitEthernet 3/0/1 through GigabitEthernet 3/0/4 to this VLAN, and enable MLD snooping and MLD snooping proxying in the VLAN.
[SwitchA] vlan 100
[SwitchA-vlan100] port Gigabitethernet 3/0/1 to Gigabitethernet 3/0/4
[SwitchA-vlan100] mld-snooping enable
[SwitchA-vlan100] mld-snooping proxying enable
[SwitchA-vlan100] quit
Verifying the configuration
After the configuration is completed, Host A and Host B send MLD join messages addressed to group FF1E::101. When receiving the messages, Switch A sends a join message for the group out of port GigabitEthernet 3/0/1 (a router port) to Router A. Use the display mld-snooping group command and the display mld group command to display information about MLD snooping groups and MLD multicast groups. For example:
# Display information about MLD snooping groups on Switch A.
[SwitchA] display mld-snooping group
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Port flags: D-Dynamic port, S-Static port, C-Copy port, P-PIM port
Subvlan flags: R-Real VLAN, C-Copy VLAN
Vlan(id):100.
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Router port(s):total 1 port(s).
GE3/0/1 (D)
IP group(s):the following ip group(s) match to one mac group.
IP group address:FF1E::101
(::, FF1E::101):
Host port(s):total 2 port(s).
GE3/0/3 (D)
GE3/0/4 (D)
MAC group(s):
MAC group address:3333-0000-0101
Host port(s):total 2 port(s).
GE3/0/3
GE3/0/4
# Display information about MLD multicast groups on Router A.
[RouterA] display mld group
Total 1 MLD Group(s).
Interface group report information
GigabitEthernet3/1/1(2001::1):
Total 1 MLD Group reported
Group Address: FF1E::1
Last Reporter: FE80::2FF:FFFF:FE00:1
Uptime: 00:00:03
Expires: 00:04:17
When Host A leaves the IPv6 multicast group, it sends an MLD done message to Switch A. Receiving the message, Switch A removes port GigabitEthernet 3/0/3 from the member port list of the forwarding entry for the group; however, it does not remove the group or forward the done message to Router A because Host B is still in the group. Use the display mld-snooping group command to display information about MLD snooping groups. For example:
# Display information about MLD snooping groups on Switch A.
[SwitchA] display mld-snooping group
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Port flags: D-Dynamic port, S-Static port, C-Copy port, P-PIM port
Subvlan flags: R-Real VLAN, C-Copy VLAN
Vlan(id):100.
Total 1 IP Group(s).
Total 1 IP Source(s).
Total 1 MAC Group(s).
Router port(s):total 1 port(s).
GE3/0/1 (D)
IP group(s):the following ip group(s) match to one mac group.
IP group address:FF1E::101
(::, FF1E::101):
Host port(s):total 1 port(s).
GE3/0/4 (D)
MAC group(s):
MAC group address:3333-0000-0101
Host port(s):total 1 port(s).
GE3/0/4
Troubleshooting MLD snooping
Layer 2 multicast forwarding cannot work
Symptom
Layer 2 multicast forwarding cannot work.
Analysis
MLD snooping is not enabled.
Solution
1. Use display current-configuration command to view the running status of MLD snooping.
2. If MLD snooping is not enabled, use the mld-snooping command to enable MLD snooping globally, and then use the mld-snooping enable command to enable MLD snooping in VLAN view.
3. If MLD snooping is disabled only for the corresponding VLAN, use the mld-snooping enable command in VLAN view to enable MLD snooping in the corresponding VLAN.
Configured IPv6 multicast group policy fails to take effect
Symptom
Although an IPv6 multicast group policy has been configured to allow hosts to join specific IPv6 multicast groups, the hosts can still receive IPv6 multicast data addressed to other groups.
Analysis
· The IPv6 ACL rule is incorrectly configured.
· The IPv6 multicast group policy is not correctly applied.
· The function of dropping unknown IPv6 multicast data is not enabled, so unknown IPv6 multicast data is flooded.
Solution
1. Use the display acl ipv6 command to check the configured IPv6 ACL rule. Make sure that the IPv6 ACL rule conforms to the IPv6 multicast group policy to be implemented.
2. Use the display this command in MLD-snooping view or the corresponding interface view to check whether the correct IPv6 multicast group policy has been applied. If not, use the group-policy or mld-snooping group-policy command to apply the correct IPv6 multicast group policy.
3. Use the display current-configuration command to check whether the function of dropping unknown IPv6 multicast data is enabled. If not, use the drop-unknown or mld-snooping drop-unknown command to enable the function of dropping unknown IPv6 multicast data.
Appendix
Processing of IPv6 multicast protocol messages
With Layer 3 multicast routing enabled, an MLD snooping-enabled switch processes IPv6 multicast protocol messages differently under different conditions, as follows:
· If only MLD is enabled on the switch, or if both MLD and IPv6 PIM are enabled on the switch, the switch does the following:
¡ Maintains dynamic member ports or dynamic router ports according to MLD packets
¡ Maintains dynamic router ports according to IPv6 PIM hello packets
· If only IPv6 PIM is enabled on the switch, the following occurs:
¡ The switch broadcasts MLD messages as unknown messages in the VLAN.
¡ After receiving an IPv6 PIM hello message, the switch maintains the corresponding dynamic router port.
· If MLD is disabled on the switch, one of the following occurs:
¡ If IPv6 PIM is disabled, the switch deletes all its dynamic member ports and dynamic router ports.
¡ If IPv6 PIM is enabled, the switch deletes only its dynamic member ports but not its dynamic router ports.
|
NOTE: On a switch with Layer 3 IPv6 multicast routing enabled, use the display mld group port-info command to display Layer 2 port information. |
· If IPv6 PIM is disabled on the switch, one of the following occurs:
¡ If MLD is disabled, the switch deletes all its dynamic router ports.
¡ If MLD is enabled, the switch maintains all its dynamic member ports and dynamic router ports.