1.基本概念
IGMPv2定义四种报文:
1)成员关系查询
分常规查询报文(目的IP地址为224.0.0.1)和特定组查询(成员离开组播组时会发送一个离组报文,查询器发送特定查询报文进行查询,目的地址为所查询的组播地址,“组地址”字段记录这个组播地址)
2)成员关系报告
主机加入组播组或进行常规查询时,主机发送成员关系报告报文,目的地址为主机所加入的组播地址,“组地址”字段记录这个组播地址)
3)离组
主机离开组播组时,会主动发送离组报文,目的地址224.0.0.2,“组地址”字段记录这个组播地址)
4)版本1成员关系报告
用于兼容IGMPv1。
2.IGMPv2查询及响应
IGMPv2定义自己的查询器选举机制(IGMPv1通过PIM用来选举产生DR),IGMPv2查询最大响应时间缺省10s。
3.IGMPv2组成员离开
与IGMPv1组成员默默离开不同,IGMPv2成员会主动发送离组报文,离组目的IP地址为224.0.0.2,报文“组地址”值为离组主机地址。
4.IGMPv2查询器
网段中接口IP地址最小的路由器成为该网段的IGMPv2查询器,负责向这个网段执行查询操作。
5.IGMPv2基础配置
![图片[1]-8.3 IGMPv2-大赛人网](https://www.dsrw.com/wp-content/uploads/2023/03/图片11-7.png)
1)R1配置
[R1]multicast routing-enable
[R1]interface GigabitEthernet 0/0/0
[R1-GigabitEthernet0/0/0]IP address 192.168.10.252 24
[R1-GigabitEthernet0/0/0]igmp enable
[R1-GigabitEthernet0/0/0]igmp version 2
2)R2配置
[R2]multicast routing-enable
[R2]interface GigabitEthernet 0/0/0
[R2-GigabitEthernet0/0/0]ip address 192.168.10.253 24
[R2-GigabitEthernet0/0/0]igmp enable
[R2-GigabitEthernet0/0/0]igmp version 2
3)查询igmp信息
<R1>display igmp interface
Interface information of VPN-Instance: public net
GigabitEthernet0/0/0(192.168.10.252):
IGMP is enabled
Current IGMP version is 2
IGMP state: up
IGMP group policy: none
IGMP limit: -
Value of query interval for IGMP (negotiated): -
Value of query interval for IGMP (configured): 60 s
Value of other querier timeout for IGMP: 0 s
Value of maximum query response time for IGMP: 10 s
Querier for IGMP: 192.168.10.252 (this router)
<R2>display igmp interface
Interface information of VPN-Instance: public net
GigabitEthernet0/0/0(192.168.10.253):
IGMP is enabled
Current IGMP version is 2
IGMP state: up
IGMP group policy: none
IGMP limit: -
Value of query interval for IGMP (negotiated): -
Value of query interval for IGMP (configured): 60 s
Value of other querier timeout for IGMP: 121 s
Value of maximum query response time for IGMP: 10 s
Querier for IGMP: 192.168.10.252
4)查询igmp组信息
[R1]display igmp group
Interface group report information of VPN-Instance: public net
GigabitEthernet0/0/0(192.168.10.252):
Total 2 IGMP Groups reported
Group Address Last Reporter Uptime Expires
239.1.1.1 192.168.10.3 00:11:18 00:01:57
239.1.1.2 192.168.10.2 00:10:35 00:01:57
5)配置静态组播组
[R1-GigabitEthernet0/0/0]igmp static-group 239.1.1.2
[R1]display igmp group static
Static join group information of VPN-Instance: public net
Total 1 entry, Total 1 active entry
Group Address Source Address Interface State Expires
239.1.1.2 0.0.0.0 GE0/0/0 UP never
6)配置静态组播组指定组播源
[R1-GigabitEthernet0/0/0]igmp static-group 239.1.1.2 source 172.16.2.1
[R1]display igmp group static
Static join group information of VPN-Instance: public net
Total 1 entry, Total 1 active entry
Group Address Source Address Interface State Expires
239.1.1.2 172.16.2.1 GE0/0/0 UP never
© 版权声明
文章版权归作者所有,未经允许请勿转载。
THE END
请登录后查看评论内容