IGMP and the querier
IGMP registers hosts in multicast groups on their own LAN, and enabling PIM on an interface also enables IGMP. A querier asks which groups have members; hosts answer with reports, and send unsolicited reports to join. In IGMPv2 every router sends a general query to 224.0.0.1 at start-up, and the lowest IP address on the subnet becomes querier. If its queries stop, others elect again.
By Arif, founder of Daveth · Updated
The full 4 min walkthrough is in Daveth Pro (Network). See what the plan opens
What this page answers
How is the IGMP querier elected?
In IGMPv2 each router multicasts a general query to 224.0.0.1 with its interface address as source, and the device with the lowest IP address on the subnet becomes the querier. Read it in “Who does the asking?”
What happens when the IGMP querier fails?
The other routers run a query timer that each general query resets. If it expires, the querier is assumed down and the election runs again. Read it in “When the querier goes”
How does a host join a multicast group with IGMP?
It sends one or more unsolicited membership reports for the group, without waiting for a query, and later answers queries with reports. Read it in “Join, query, leave”
Who does the router hear from?
1.6.c.i had a last-hop router send PIM joins toward the rendezvous point for the receivers on its LAN. How does it know there are any receivers?
IGMP is used to dynamically register individual hosts in a multicast group on a particular LAN. Enabling PIM on an interface also enables IGMP.
On a particular LAN. IGMP runs between hosts and the routers on their own segment; it carries no routes. That is its whole reach, and it is the one multicast protocol here that hosts speak.
Ask and answer
A querier is a network device, such as a router, that sends query messages to discover which network devices are members of a given multicast group. A host is a receiver, including routers, that sends report messages (in response to query messages) to inform the querier of a host membership.
Read the second definition's parenthesis: including routers. A host is a role, not a device type. And notice the other parenthesis: reports go in response to queries, so the network asks rather than waits.
Who does the asking?
When IGMPv2 devices start, they each multicast a general query message to the all-systems group address of 224.0.0.1 with their interface address in the source IP address field of the message. The device with the lowest IP address on the subnet is elected the IGMP querier.
Two routers on this segment, RTR-A and RTR-B. Which one queries?
This course's reading: the election on this segment
router address IGMP PIM DR RTR-A 10.6.1.1 querier no RTR-B 10.6.1.2 query timer running yes querier: RTR-A
Lowest address, and count the tie-breakers: none. After OSPF's priorities and BGP's long path selection, that is the whole rule. Now look at the last column:
The DR is the device with the highest IP address on the subnet, whereas the IGMP querier is the device with the lowest IP address.
So the PIM DR from 1.6.c.i and the IGMP querier can be different routers on one subnet, and here they are: RTR-B is the DR and RTR-A asks.
Join, query, leave
When a host wants to join a multicast group, the host sends one or more unsolicited membership reports for the multicast group it wants to join.
RECV-1 reports 239.6.1.10 without waiting for a query, and later answers one. What does the segment hold after both?
This course's reading: memberships after the join and a query
host report group sources sent to RECV-1 IGMPv2 report 239.6.1.10 - 239.6.1.10 RECV-2 none last to respond to a query: RECV-1 leave-group message: none the group, on the querier: reported
IGMPv2 added four things to that exchange:
IGMPv2 extends IGMP functionality by providing such features as the IGMP leave process to reduce leave latency, group-specific queries, and an explicit maximum query response time. Querier election process--Provides the capability for IGMPv2 devices to elect the IGMP querier without having to rely on the multicast routing protocol to perform the process. Maximum Response Time field--A new field in query messages permits the IGMP querier to specify the maximum query-response time. Group-Specific Query messages--Permits the IGMP querier to perform the query operation on a specific group instead of all groups. Leave-Group messages--Provides hosts with a method of notifying devices on the network that they wish to leave the group.
Now RECV-1 stops wanting the group. Does it tell anyone?
When an IGMPv2 host leaves a multicast group, if it was the last host to respond to a query with a membership report for that group, it sends a leave-group message to the all-devices multicast group (224.0.0.2).
This course's reading: memberships after RECV-1 leaves
host report group sources sent to RECV-1 none RECV-2 none last to respond to a query: RECV-1 leave-group message: RECV-1 to 224.0.0.2 the group, on the querier: not stated after the leave
It was the last host to respond, so it sends the leave to 224.0.0.2. The page does not say what the querier then does with the group, and the reading says so. A host that was not the last to respond sends no leave at all.
When the querier goes
All devices (excluding the querier) start the query timer, which is reset whenever a general query message is received from the IGMP querier. If the query timer expires, it is assumed that the IGMP querier has gone down, and the election process is performed again to elect a new IGMP querier.
RTR-A goes down, and RTR-B's timer stops being reset. How long does RTR-B wait? The page's defaults:
IGMP host-query message interval 60 seconds on all interfaces. IGMP query timeout 60 seconds on all interfaces. IGMP maximum query response time 10 seconds on all interfaces. By default, the timer is two times the query interval.
This course's reading: the timers, and the two defaults for the query timer
host-query interval 60 s maximum query response time 10 s query timeout, from the defaults table 60 s query timer, two times the query interval 120 s
Look at the last two rows: 60 seconds in the defaults table, and two times a 60-second interval in the election text. The same page gives both, and this page does not pick one.
This course's reading: the election after RTR-A goes down
router address IGMP PIM DR RTR-A 10.6.1.1 down - RTR-B 10.6.1.2 querier yes querier: RTR-B
Continue the lesson
The whole lesson, with its drawings and its questions. 6 more sections after the ones above.

