In some situations it is desirable to manually configure multicast group membership on a router interface, particularly during testing and in the absence of IGMP-capable recipients. IOS provides two commands to statically designate group membership on an interface: ip igmp join-group and ip igmp static-group. So what's the difference? The
join-group command makes the router behave as a member of the specified group, whereas the
static-group command allows for fast-switching of group traffic out the designated interface(s).
Assume we wish to forward multicast traffic for the 18.104.22.168 group to the 192.168.10.0/24 subnet. To do this, we apply
ip igmp join-group 22.214.171.124 to R2's F0/1 interface:
R2(config)# interface f0/1 R2(config-if)# ip igmp join-group 126.96.36.199
We can verify that R1 and R2 now have a multicast route for this group:
R2# show ip mroute 188.8.131.52 ... (*, 184.108.40.206), 00:01:58/00:02:26, RP 220.127.116.11, flags: SJCL Incoming interface: FastEthernet0/0, RPF nbr 10.0.0.1 Outgoing interface list: FastEthernet0/1, Forward/Sparse, 00:01:58/00:02:26
A ping to the group from R1 receives a response from R2 (note that two pings are actually sent from R1, thus two replies):
R1# ping 18.104.22.168 Type escape sequence to abort. Sending 1, 100-byte ICMP Echos to 22.214.171.124, timeout is 2 seconds: Reply to request 0 from 10.0.0.2, 16 ms Reply to request 0 from 10.0.0.2, 24 ms
Now we'll replace the
join-group command with
static-group. After removing
join-group we clear the multicast routing table on both routers and apply
ip igmp static-group 126.96.36.199 to R2's F0/1 interface:
R2(config)# interface f0/1 R2(config-if)# no ip igmp join-group 188.8.131.52 R2(config-if)# do clear ip mroute * R2(config-if)# ip igmp static-group 184.108.40.206
Examining the multicast routing table verifies that we again have and entry for the 220.127.116.11 group on both routers:
R2# show ip mroute 18.104.22.168 ... (*, 22.214.171.124), 00:03:32/stopped, RP 126.96.36.199, flags: SJC Incoming interface: FastEthernet0/0, RPF nbr 10.0.0.1 Outgoing interface list: FastEthernet0/1, Forward/Sparse, 00:03:32/00:02:28
However, a ping to the group from R1 fails this time:
R1# ping 188.8.131.52 repeat 5 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 184.108.40.206, timeout is 2 seconds: .....
The ping fails because R2, configured with the
static-group command, no longer acts a group member itself; instead, it merely fast-switches multicast traffic out F0/1.