IP Multicast · Topic 3 of 5

IGMP and IGMP Snooping

JN0-650 study page on IGMP versions, querier election, timers, join and leave behavior, static groups and IGMP snooping on Junos EX and QFX switches.

  • 5 min
In a nutshell
  • IGMPv1, v2 and v3; v2 adds Leave, v3 adds source filters and sends reports to 224.0.0.22.
  • Junos default: version 2, query interval 125 seconds, response interval 10 seconds, robustness 2.
  • The lowest IP address wins the querier election.

What it is

IGMP (Internet Group Management Protocol) is how hosts on a LAN tell their router which multicast groups they want. The router (the querier) asks, and hosts answer with membership reports.

IGMP snooping is a Layer 2 switch feature. The switch listens to IGMP messages and learns which ports have receivers, so it sends multicast only to those ports instead of flooding the whole VLAN.

HostMembership reportgroup GSwitchSnoops and records portforwards to routerRouterQuerier

How it works

Versions

VersionKey changeReport sent to
IGMPv1Reports and queries; no explicit leaveThe group address
IGMPv2Adds a Leave message and group-specific queriesThe group address; leaves go to 224.0.0.2
IGMPv3Adds source filtering (include and exclude lists), needed for SSM224.0.0.22

The versions are backward compatible: if a router hears an older version, it falls back to it on that link. The default version on Junos interfaces is IGMPv2, and you set version 3 where SSM is used.

Queries and timers

The querier sends a general query to 224.0.0.1 periodically, and hosts answer with reports. After a host leaves, the querier sends a group-specific query to check whether other members remain.

SettingJunos default
Query interval125 seconds
Query response interval10 seconds
Robustness variable2
Last member query interval1 second

The group membership timeout is robustness times the query interval plus the response interval, which is 2 x 125 + 10 = 260 seconds. If no report arrives in that time, the group is removed.

When several routers share a segment, the one with the lowest IP address becomes the IGMP querier. The others listen and take over if the querier is silent.

Join and leave

A host joins by sending an unsolicited report for the group. In IGMPv2 it leaves by sending a Leave to 224.0.0.2, and the querier answers with group-specific queries. If nobody answers within the last member query time, the group is removed. In IGMPv3 the host changes its filter state instead.

Configuration on a router

IGMP starts when PIM or a static group is configured on an interface, and you can also set it explicitly.

set protocols igmp interface ge-0/0/2.0 version 3
set protocols igmp interface ge-0/0/2.0 query-interval 60
set protocols igmp interface ge-0/0/2.0 static group 239.1.1.1
set protocols igmp interface ge-0/0/2.0 static group 232.1.1.1 source 10.1.1.10

A static group makes the router behave as if a receiver were present, which is a good test and a way to serve receivers that cannot send reports.

show igmp interface
show igmp group
show igmp statistics

IGMP snooping on EX and QFX

Without snooping, a switch treats multicast like broadcast and floods it to every port in the VLAN. With snooping, the switch forwards a group only to ports that sent a report for it, and to ports that lead to a multicast router.

set protocols igmp-snooping vlan v10
set protocols igmp-snooping vlan v10 immediate-leave
set protocols igmp-snooping vlan v10 interface ge-0/0/24.0 multicast-router-interface
set protocols igmp-snooping vlan v10 interface ge-0/0/5.0 static group 239.1.1.1
StatementPurpose
igmp-snooping vlan nameEnables snooping for one VLAN
immediate-leaveRemoves a port at once when a Leave arrives; suitable when only one host is on the port
multicast-router-interfaceMarks a port that leads to a multicast router, so the switch always forwards group traffic to it
static groupForwards a group to the port even with no report

The switch needs a querier on the VLAN. In a routed design it is usually the router or the IRB interface of that VLAN. If no querier exists, the switch cannot keep its membership table fresh and entries time out.

RouterSends general queryLayer 2SwitchSnooping forwards itto all portsHostsAnswer with reports
Exam tip

Use immediate-leave only on access ports with one receiver. With a hub or several hosts on the port, the first Leave would cut off the others.

Verifying snooping

show igmp snooping membership
Watch out

Snooping with no multicast router port and no querier is a classic fault. Receivers join, the first report is seen, and then the group expires after the timeout.

Common mistakes

Assuming IGMP is a routing protocol. It only signals host membership on one link.

Using IGMPv2 for SSM. Source filtering needs IGMPv3, or an SSM map.

Enabling snooping without a querier. Memberships age out.

Forgetting the multicast router port. Traffic from the source never reaches the router or other switches that need it.

Using immediate-leave on a shared port. Remaining hosts lose the stream.

What to remember for the exam

  • IGMPv1, v2 and v3; v2 adds Leave, v3 adds source filters and sends reports to 224.0.0.22.
  • Junos default: version 2, query interval 125 seconds, response interval 10 seconds, robustness 2.
  • The lowest IP address wins the querier election.
  • IGMP snooping forwards a group only to member ports and multicast router ports.
  • immediate-leave and multicast-router-interface are the key snooping options.
  • A snooping switch needs an IGMP querier in the VLAN.

Check yourself

  • What does IGMPv3 add that IGMPv2 lacks?

    Source filtering with include and exclude lists, which is what makes SSM work.

  • Which router becomes the IGMP querier on a shared LAN?

    The one with the lowest IP address.

  • What does IGMP snooping stop a switch from doing?

    Flooding group traffic to every port in the VLAN, because it forwards only to member ports and router ports.

Topic 3 of 5 in IP Multicast

Test yourself on IP Multicast

The full Juniper JNCIP-ENT JN0-650 question bank has 858 questions, with timed practice exams and an explanation for every answer.

This study guide is independent and is not affiliated with, endorsed by, or sponsored by Juniper. Vendor names, certification names and exam codes are trademarks of their respective owners and are used for identification only.