MLD Configuration
This chapter describes how to configure Multicast Listener Discovery (MLD).
The Multicast Listener Discovery (MLD) is used by IP hosts to report their multicast group memberships to any immediately-neighboring multicast routers.
Using the information obtained through MLD, the router maintains a list of multicast group on a per-interface basis. The routers that receive these MLD packets send multicast data that they receive for requested groups out the network segment of the known receivers.
By default, when PIMv6 is enabled on an interface, MLD version 2 is enabled. MLD can be enabled on an interface explicitly.
MLD Versions
OcNOS supports MLDv1 and MLDv2. By default, OcNOS enables MLDv2 when PIMv6 is enabled on an interface.
MLDv2 includes the following key changes from MLDv1:
• Support for Source-Specific Multicast (SSM), which builds shortest path trees from each receiver to the source, through the following feature:
• Host messages that can specify both the group and the source.
• The multicast state that is maintained for groups and sources, not just for groups as in MLDv1.
• Hosts no longer perform report suppression, which means that hosts always send MLD membership reports when an MLD query message is received.
MLD Operation
MLD works on the premise of three major packets exchange between MLD enabled routers and hosts, interested in joining a particular group.
MLD Query Operation
Once MLD is enabled or PIMv6 is enabled (which enables MLDv2), on any interface it starts sending Query message, which is called general query to the all-hosts multicast group at ff02::1 periodically to discover whether any hosts want to receive multicast data.
OcNOS elects a router as the MLD querier on a subnet if it has the lowest IP address. As long as a router continues to receive query messages from a router with a lower IP address, it resets a timer that is based on its querier timeout value. If the querier timer of a router expires, it becomes the designated querier. If that router later receives a host query message from a router with a lower IP address, it drops its role as the designated querier and sets its querier timer again.
In the figure below Router-1 eth2 sends query every query-interval. Since Router1-eth2 IPv6 link local address is less than Router-2 eth2, Router-1 eth2 becomes querier on the LAN.
MLD Membership Report Operation
When a host receives a query from the local router it sends a Host Membership Report for all the multicast groups for which it wants to receive multicast traffic. This is called solicited membership report.
When a host joins a new group, the host immediately sends a Membership Report to inform a local router that it wants to receive multicast traffic for the group it has just joined without waiting to receive a Query. This is called unsolicited membership report.
In the figure below Host-1 and Host-2 sends membership reports to Router-1 eth2 for all the multicast groups for which they want to receive multicast traffic. Upon reception of membership report Router-1 maintains an MLD group table containing multicast group-address, interface name on which it receives the report.
MLD Leave Operation
When a multicast host leaves a group, a host that runs MLD sends an MLD leave message. To check if this host is the last host to leave the group, the router sends an MLD query (Called as Group-specific-query) message and starts a timer that you can configure called the last member query response interval. If no reports are received before the timer expires, the software removes the group state. The router continues to send multicast traffic for a group until its state is removed.
In the figure below Host-1 and Host-2 sends leave message to Router-1 eth2 for all the multicast groups for which they don't want to receive multicast traffic. In response to leave message Router-1 eth2 sends an group-specific-query message before removing the multicast group address from the MLD table.
Topology
MLD Topology
MLD Configuration
The following example shows MLD configuration on Router1.
Configuring MLD Version
The configuration that follows shows how MLD version can be configured.
#configure terminal | Enter configure mode. |
(config)#ipv6 multicast-routing | Enable IPv6 multicast routing |
(config)#interface eth2 | Enter interface mode. |
(config-if)#ip address 2001::1/64 | Assign IPv6 address to an interface |
(config-if)#ipv6 mld version 1 | Enable MLD version as v1. |
(config-if)#commit | Commit the transaction. |
(config)#exit | Exit Configure mode. |
Validation
Enter the commands listed in this section to confirm the previous configurations.
#show running-config
!
no service password-encryption
!
hostname rtr1
!
Ipv6 multicast-routing
!
!
interface eth2
ip address 2001::1/64
no shutdown
ipv6 mld version 1
Configuring MLD Parameters
The configuration that follows shows how MLD parameters can be configured.
#configure terminal | Enter configure mode. |
(config)#ipv6 multicast-routing | Enable IP multicast routing |
(config)#interface eth2 | Enter interface mode |
(config-if)#ipv6 mld access-group 1 | Configures a access-list policy to control the multicast groups that hosts on the subnet serviced by an interface can join. |
(config-if)#ipv6 mld immediate-leave | |
group-list 1 | Enables the device to remove the group entry from the multicast routing table immediately upon receiving a leave message for the group. |
(config-if)# ipv6 mld last-member-query-count 7 | Sets the query count used when the software starts up. |
(config-if)# ipv6 mld last-member-query-interval 25500 | Sets the query interval used when the software starts up. |
(config-if)#ipv6 mld limit 100 | Configure Max Allowed State on this interface |
(config-if)#ipv6 mld querier-timeout | |
300 | Sets the querier timeout that the router uses when deciding to take over as the querier. |
(config-if)#ipv6 mld query-interval | |
200 | Sets the frequency at which the router sends MLD host query messages. |
(config-if)#ipv6 mld query-max-response-time 150 | Sets the response time advertised in MLD queries. |
(config-if)#ipv6 mld robustness-variable 4 | Sets the robustness variable. |
(config-if)#ipv6 mld startup-query-count 4 | Sets the query count used when the router starts up. |
(config-if)# ipv6 mld startup-query-interval 50 | Sets the query interval used when the router starts up. |
(config-if)#ipv6 mld static-group FF1E::1 | Statically binds a multicast group to the outgoing interface. |
(config-if)#commit | Commit the transaction. |
(config)#exit | Exit Configure mode. |
Validation
Enter the commands listed in this section to confirm the previous configurations
#show running-config
!
no service password-encryption
!
hostname rtr1
!
!
Ipv6 multicast-routing
!
!
interface eth2
ipv6 address 2001::1/64
no shutdown
ipv6 mld access-group 1
ipv6 mld immediate-leave group-list 1
ipv6 mld last-member-query-count 7
ipv6 mld limit 100
ipv6 mld static-group ff1e::1
ipv6 mld last-member-query-interval 25500
ipv6 mld querier-timeout 300
ipv6 mld query-interval 200
ipv6 mld query-max-response-time 150
ipv6 mld startup-query-interval 50
ipv6 mld startup-query-count 4
ipv6 mld robustness-variable 4
ipv6 mld ra-option
ipv6 mld version 1
!!
Rtr1#show ipv6 mld interface eth2
Interface eth2 (Index 4)
MLD Enabled, Active, Querier, Configured for version 1
Internet address is fe80::eac5:7aff:fe78:a2d9
MLD interface limit is 100
MLD interface has 1 group-record states
MLD interface statistics:
v1-reports: 0, v1-leaves: 0
v2-reports: 0
MLD query interval is 200 seconds
MLD startup query interval is 50 seconds
MLD startup query count is 4
MLD querier timeout is 300 seconds
MLD max query response time is 150 seconds
Group Membership interval is 950 seconds
MLD Last member query count is 7
Last member query response interval is 1000 milliseconds
MLD Group Table after MLDv1 Membership Report is received
MLD group table is populated at router by virtue of either static join is configured on interface or dynamic report is being received on the interface.
The show ipv6 mld groups command displays the MLD group table. In this table, the following fields are defined.
Table 11-3: MLD group table after MLDv1 membership report
Group address | Displays the Multicast Group for which report is received. |
Interface | Interface name on which Membership report is received. |
Uptime | Duration since the report is received. |
Expiry | Time frame in which the multicast group is going to expire. |
Last Reporter | Host address from where the report is generated. |
#show ipv6 mld groups
MLD Connected Group Membership
Group Address Interface Uptime Expires State Last Reporter
ff04::1 xe18 00:00:10 00:15:40 Active fe80::1
ff1e::1 xe18 00:17:22 static Active ::
#show ipv6 mld groups detail
MLD Connected Group Membership Details
Flags: (M - SSM Mapping, R - Remote,
SG - Static Group, SS - Static Source)
Interface: xe18
Group: ff04::1
Flags: R
Uptime: 00:00:33
Group mode: Exclude (Expires: 00:15:17)
State: Active
Last reporter: fe80::1
Source list is empty
Flags: (M - SSM Mapping, R - Remote,
SG - Static Group, SS - Static Source)
Interface: xe18
Group: ff1e::1
Flags: SG
Uptime: 00:17:45
Group mode: Exclude (Static)
State: Active
Last reporter: ::
Source list is empty