On an IPv6 multicast network shown in Figure 1, the layer 2 switch at the edge of the access layer forwards multicast data packets received from the upstream router to receiver hosts. If MLD snooping is not configured, the switch broadcasts multicast data packets. With MLD snooping configured, the switch listens on MLD messages exchanged between the outer and hosts, and analyzes packet information (such as packet type, group address, and receiving interface) to create and maintain a Layer 2 multicast forwarding table. Multicast data packets are then forwarded to specific hosts based on the Layer 2 multicast forwarding table.
In Figure 2, the router connects to a multicast source, the two switches run MLD snooping, and hosts A to C are receiver hosts (group members).
The following table describes the port roles shown in Figure 2.
Port Role |
Function |
Generation |
---|---|---|
Router port NOTE:
A router port is a port of a Layer 2 multicast device connected to an upstream multicast router. |
Receives multicast packets from a Layer 3 multicast device such as a designated router (DR) or MLD querier. |
|
Member port (member of a multicast group) |
Forwards multicast data to receiver hosts. |
|
Router ports and member ports are outbound interfaces in Layer 2 multicast forwarding entries. A router port is an upstream interface, and a member port is a downstream interface. Port information learned through protocol packets is saved as dynamic entries, and port information manually configured is saved as static entries.
The following table describes how a Layer 2 multicast device running MLD snooping processes various MLD messages and creates Layer 2 multicast forwarding entries.
MLD Message |
MLD Working Phase |
Processing Method |
---|---|---|
MLD General Query message |
General query The MLD querier periodically sends General Query messages to all hosts and the router (FF02::1) on the local network segment, to check which multicast groups have members on the network segment. |
A Layer 2 device forwards an MLD General Query message to
all ports excluding the port that has received the messages. This
port is treated as follows:
NOTE:
By default, the Layer 2 device sets the aging time to 180 seconds when the router port receives an MLD General Query message. This is a configurable variable. |
MLD Report message |
Membership report Report messages are sent in two
scenarios:
|
A Layer 2 device forwards an MLD Report message to all router
ports in a VLAN. The device obtains the multicast group address from
the Report message and performs the following operations on the port
that has received the message:
NOTE:
Aging time of a dynamic router port = Robustness variable x General query interval + Maximum response time for General Query messages |
MLD Done message |
Leave of group members There are two phases:
|
The Layer 2 device determines whether the multicast group
matches a forwarding entry and whether the port that receives the
message is in the outbound interface list.
The following assumes that the port receiving an MLD Leave
message is a dynamic member port. Within the aging time of the member
port:
|
Multicast-Address-Specific Query/Multicast-Address-and-Source-Specific Query message |
A Multicast-Address-Specific Query or Multicast-Address-and-Source-Specific Query message is forwarded to the ports connected to members of specific groups. |
When a Layer 2 device receives an IPv6 PIM Hello message, it sets the aging time of the router port to the Holdtime value contained in the Hello message.
If a static router port is configured, the Layer 2 device forwards received MLD Report and Done messages to the static router port. If a static member port is configured for a multicast group, the Layer 2 device adds the port to the outbound interface list for that multicast group.
When a Layer 2 multicast forwarding table has been created, the Layer 2 device searches the multicast forwarding table for outbound interfaces of multicast data packets based on VLAN IDs and destination addresses (IPv6 group addresses). If outbound interfaces are found for a packet, the Layer 2 device forwards the packet to all the member ports of the multicast group. If no outbound interface is found, the Layer 2 device drops the packet or broadcasts the packet in the VLAN.