Skip to content
Ask AI

MLD Snooping Configuration

[Command]

**show vlan mld-snooping ** [ vlan-id ]

[Purpose]

Display MLD snooping information

[View]

System view

[Use Cases]

sonic(config)# do show vlan mld-snooping
+-----------+-----------+----------+-----------+--------------+-----------+--------------+--------------+---------------------+----------------------------------+------------------------------+
| VLAN ID | MLD SNP | Proxy | version | Fast-leave | Querier | Querier-ip | robustness | Query-interval(s) | Last-member-query-interval(ms) | Query-max-response-time(s) |
+===========+===========+==========+===========+==============+===========+==============+==============+=====================+==================================+==============================+
| 10 | enabled | disabled | 1 | disabled | disabled | 0.0.0.0 | 2 | 125 | 1000 | 10 |
+-----------+-----------+----------+-----------+--------------+-----------+--------------+--------------+---------------------+----------------------------------+------------------------------+

[Command]

show vlan mld-snooping mrouter-aging

[Purpose]

Show router port aging time for MLD snooping

[View]

System view

[Use Cases]

sonic# show vlan mld-snooping mrouter-aging
+-----------+--------------+
| VLAN ID | Aging Time |
+===========+==============+
| 10 | 180 |
+-----------+--------------+

[Command]

show vlan mld-snooping mrouter

[Purpose]

Display the router port information of MLD snooping

[View]

System view

[Use Cases]

sonic# show vlan mld-snooping mrouter
+-----------+-----------+--------+
| VLAN ID | Mrouter | Type |
+===========+===========+========+
| 10 | Ethernet5 | static |
+-----------+-----------+--------+

[Command]

mld-snooping enable

no mld-snooping enable

[Purpose]

Enable MLD snooping for VLAN

[View]

VLAN view

[Usage Scenario]

MLD Snooping operates on a Layer 2 switching network between routers and user terminals. It maintains multicast forwarding tables by listening to IPv6 multicast protocol messages from routers and user terminals, allowing multicast packets to be broadcast between specified interfaces within the VLAN

[Use Cases]

sonic(config)# vlan 20
sonic(config-vlan-20)# mld-snooping enable

[Command]

mld-snooping version 1-2

[Purpose]

Configure the MLD version

[View]

VLAN view

[Use Cases]

sonic(config-vlan-10)# mld-snooping version 1

[Command]

mld-snooping proxy enable

[Purpose]

Enable MLD snooping proxy for VLAN

[View]

VLAN view

[Usage Scenario]

Enabling MLD Snooping Proxy functionality allows the switch to substitute for routers in sending MLD Query messages and receiving MLD Report/Leave messages from users. This alleviates the burden on router devices when there are numerous terminals in the network

[Use Cases]

sonic(config)# vlan 20
sonic(config-vlan-20)# mld-snooping proxy enable

[Command]

mld-snooping querier enable

[Purpose]

Enable MLD querier functionality

[View]

VLAN view

[Usage Scenario]

Configuring a querier on the device allows it to replace upstream devices in sending MLD Query messages. The device will periodically broadcast MLD Query messages to all interfaces within the VLAN, including router ports

[Notes]

If an MLD querier already exists in the multicast network, it may trigger a re-election of the MLD querier

[Use Cases]

sonic(config)# vlan 20
sonic(config-vlan-20)# mld-snooping proxy enable

[Command]

mld-snooping querier-ip X:X::X:X

no mld-snooping querier-ip X:X::X:X

[Purpose]

Configuring the source IP address of MLD Query messages

[View]

VLAN view

[Usage Scenario]

When there are multiple queriers in the network, you can control the selection of the querier by modifying the IP address of the device’s query messages.

[Use Cases]

sonic(config)# vlan 10
sonic(config-vlan-10)# mld-snooping querier enable
sonic(config-vlan-10)# mld-snooping querier-ip 1000::1

[Command]

mld-snooping fast-leave enable

no mld-snooping fast-leave enable

[Purpose]

Enable fast leave of multicast groups on member interfaces

[View]

VLAN view

[Usage Scenario]

Upon receiving an MLD Leave message from a host indicating departure from a multicast group, the corresponding multicast forwarding table entry for that host is removed immediately without waiting for aging time

[Use Cases]

sonic(config)# vlan 10
sonic(config-vlan-10)# mld-snooping fast-leave enable

[Command]

mld-snooping robustness count

[Purpose]

Configure robustness

[Parameter]

ParameterDescription
countDefault 2, range:1~255

[View]

VLAN view

[Usage Scenario]

This command adjusts robustness in two ways:

  • Adjusts the number of specific group query messages sent by the querier to avoid potential network packet loss. When an MLD Leave message is received from a user for a specific multicast group, the command sends a specific group query message for a configured number of times, inquiring whether there are still members in that multicast group.
  • Adjusts the member aging time. After receiving a report message from a downstream host, the member aging time is set to: specific group query message count × general query message interval for downstream hosts to reply to the querier.

[Use Cases]

sonic(config)# vlan 10
sonic(config-vlan-10)# mld-snooping robustness 100

[Command]

mld-snooping query-interval interval

[Purpose]

Configure the interval at which the device sends general query messages

[Parameter]

ParameterDescription
intervalUnit: s, the default value is: 125s,range:1-18000

[View]

VLAN view

[Use Cases]

sonic(config)# vlan 10
sonic(config-vlan-10)# mld-snooping query-interval 200

[Command]

mld-snooping query-max-response-time time

[Purpose]

Configure the maximum response time for query messages

[Parameter]

ParameterDescription
timeUnit: s, the default value is: 10s, range:1~25

[View]

VLAN view

[Notes]

It should be ensured that the interval at which the querier sends general query messages is greater than the maximum response time for downstream hosts to reply to the querier. Otherwise, there is a possibility of the device mistakenly deleting entries in the member table

[Use Cases]

sonic(config)# vlan 10
sonic(config-vlan-10)# mld-snooping query-max-response-time 20

[Command]

mld-snooping last-member-query-interval last_query_interval

[Purpose]

Configure the interval at which the querier sends specific group query messages.

[Parameter]

ParameterDescription
last_query_intervalUnit: ms, the default value is: 1000ms,range:100-25500

[Use Cases]

sonic(config)# vlan 10
sonic(config-vlan-10)# mld-snooping last-member-query-interval 2000

[Command]

interface l2mc-static-group etherne interface_name vlan_id X:X::X:X

no interface l2mc-static-group ethernet interface_name vlan_id X:X::X:X

[Purpose]

Static addition of interfaces to multicast groups

[Parameter]

ParameterDescription
interface_nameInterface name
vlan_idVLAN ID of the interface
X:X::X:XInterface statically added multicast group address

[View]

System configuration view

[Notes]

After configuring the interface to statically add a multicast group, users under the interface can receive multicast data from the group in a long-term and stable manner, and need to enable the MLD Snooping function.

[Use Cases]

sonic(config)# interface l2mc-static-group ethernet 11 10 ff1e:0:0:0:0:0:0:1

[Command]

mld-snooping mrouter-aging time

[Purpose]

Configure dynamic router port aging time within a VLAN

[Parameter]

ParameterDescription
timeValue range: 1-1000, unit: s, default is 180 seconds

[View]

System configuration view

[Notes]

Within the aging time of the dynamic router port, if no MLD Query or PIM Hello messages are received, it is considered that this port no longer belongs to the router port.

[Use Cases]

sonic(config)# vlan 20
sonic(config-vlan-20)# mld-snooping mrouter-aging 10

[Command] mld-snooping mrouter ethernet interface_name no mld-snooping mrouter ethernet* interface_name*

[Purpose]

Configure the interface as a static router port for VLAN

[View]

VLAN view

[Use Cases]

sonic(config)# vlan 10
sonic(config-vlan-10)# mld-snooping mrouter ethernet 1