< Home

Example for Configuring the MLD Snooping Querier

Networking Requirements

In Figure 1, Source1 and Source2 on a Layer 2 network send multicast data to FF16::1 and FF16::2. HostA and HostC need to receive data of multicast group FF16::1, whereas HostB and Host D need to receive data of multicast group FF16::2.

Figure 1 Network diagram for configuring MLD snooping querier

Configuration Roadmap

Enable MLD snooping on each switch in the network and configure MLD snooping querier to meet the service requirement. Enable each switch to discard unknown multicast packets to prevent the device from broadcasting multicast packets in a VLAN when there is no corresponding Layer 2 forwarding entry.

  1. According to Figure 1, create a VLAN on the switches and add interfaces to the VLAN.
  2. Enable MLD snooping globally and in the VLAN on all the switches.
  3. Configure SwitchA closest to the multicast source as the MLD snooping querier.
  4. Enable all the switches to discard unknown multicast packets.

Procedure

  1. Create a VLAN and add interfaces to the VLAN. The configurations of SwitchB, SwitchC and SwitchD are similar to the configuration of SwitchA, and are not mentioned here.

    # Configure SwitchA.

    <HUAWEI> system-view
    [HUAWEI] sysname SwitchA
    [SwitchA] vlan 10
    [SwitchA-vlan10] quit
    [SwitchA] interface gigabitethernet 0/0/1
    [SwitchA-GigabitEthernet0/0/1] port link-type hybrid
    [SwitchA-GigabitEthernet0/0/1] port hybrid pvid vlan 10
    [SwitchA-GigabitEthernet0/0/1] port hybrid untagged vlan 10
    [SwitchA-GigabitEthernet0/0/1] quit
    [SwitchA] interface gigabitethernet 0/0/2
    [SwitchA-GigabitEthernet0/0/2] port link-type hybrid
    [SwitchA-GigabitEthernet0/0/2] port hybrid pvid vlan 10
    [SwitchA-GigabitEthernet0/0/2] port hybrid untagged vlan 10
    [SwitchA-GigabitEthernet0/0/2] quit
    [SwitchA] interface gigabitethernet 0/0/3
    [SwitchA-GigabitEthernet0/0/3] port link-type hybrid
    [SwitchA-GigabitEthernet0/0/3] port hybrid pvid vlan 10
    [SwitchA-GigabitEthernet0/0/3] port hybrid untagged vlan 10
    [SwitchA-GigabitEthernet0/0/3] quit

  2. Enable MLD snooping.

    # Configure SwitchA. The configurations of SwitchB, SwitchC and SwitchD are similar to the configuration of SwitchA, and are not mentioned here.

    [SwitchA] mld-snooping enable
    [SwitchA] vlan 10
    [SwitchA-vlan10] mld-snooping enable
    [SwitchA-vlan10] quit

  3. Configure MLD snooping querier.

    # Configure SwitchA as the querier.

    [SwitchA] vlan 10
    [SwitchA-vlan10] mld-snooping querier enable
    [SwitchA-vlan10] quit

  4. Configure the switches to discard unknown multicast packets.

    # Configure SwitchA. The configurations of SwitchB, SwitchC and SwitchD are similar to the configuration of SwitchA, and are not mentioned here.

    [SwitchA] vlan 10
    [SwitchA-vlan10] multicast drop-unknown
    [SwitchA-vlan10] quit
    

  5. Verify the configuration.

    # After the MLD snooping querier starts to work, all devices except the querier can receive MLD General Query messages. Use the following command to check MLD packet statistics, such as statistics about received MLD packets on SwitchB.

    [SwitchB] display mld-snooping statistics vlan 10
     MLD Snooping Packets Counter                                                   
       Statistics for VLAN 10                                                       
         Recv V1 Report  316                                                        
         Recv V2 Report  0                                                          
         Recv V1 Query  305                                                        
         Recv V2 Query   0                                                          
         Recv Done       2                                                          
         Recv Pim Hello  85                                                         
         Send Query(S=0) 1                                                          
         Send Query(S!=0)0                                                          
         Send General Query               0                                         
         Send Group-Specific Query        0                                         
         Send Group-Source-Specific Query 0                                         

Configuration Files

  • SwitchA configuration file

    #
    sysname SwitchA
    #
    vlan batch 10
    #
    mld-snooping enable
    #
    vlan 10
     multicast drop-unknown
     mld-snooping enable
     mld-snooping querier enable
    #
    interface GigabitEthernet0/0/1
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet0/0/2
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet0/0/3
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    return
  • SwitchB configuration file

    #
    sysname SwitchB
    #
    vlan batch 10
    #
    mld-snooping enable
    #
    vlan 10
     multicast drop-unknown
     mld-snooping enable
    #
    interface GigabitEthernet0/0/1
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet0/0/2
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet0/0/3
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet0/0/4
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    return
  • SwitchC configuration file

    #
    sysname SwitchC
    #
    vlan batch 10
    #
    mld-snooping enable
    #
    vlan 10
     multicast drop-unknown
     mld-snooping enable
    #
    interface GigabitEthernet0/0/1
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet0/0/2
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet0/0/3
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    return
  • SwitchD configuration file

    #
    sysname SwitchD
    #
    vlan batch 10
    #
    mld-snooping enable
    #
    vlan 10
     multicast drop-unknown
     mld-snooping enable
    #
    interface GigabitEthernet0/0/1
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    interface GigabitEthernet0/0/2
     port link-type hybrid
     port hybrid pvid vlan 10
     port hybrid untagged vlan 10
    #
    return
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >