1.PIM DM experiment


2.IGMPv1-v3 experiment, you can observe IGMP messages


3.PIM SM static experiment


4.PIM SM dynamic experiment



Configure the IP address, PIM part router IGP interconnection.


[R4]multicast routing-enable

[R4-GigabitEthernet0/0/2]igmp enable


PC1 clicks multicast to join the group


[R4]dis igmp routing-table

Routing table of VPN-Instance: public net

 Total 1 entry


 00001. (*, 239.1.1.1)

       List of 1 downstream interface

        GigabitEthernet0/0/2 (192.168.1.1),

                   Protocol: IGMP


Enable PIM-DM


[R1]multicast routing-enable

[R1-GigabitEthernet0/0/0]pim dm

[R1-GigabitEthernet0/0/2]pim dm


[R2]multicast routing-enable


[R2-GigabitEthernet0/0/0]pim dm



[R2-GigabitEthernet0/0/1]pim dm


[R2-GigabitEthernet0/0/2]pim dm


[R4-GigabitEthernet0/0/0]pim dm


[R4-GigabitEthernet0/0/1]pim dm


[R3]multicast routing-enable


[R3-GigabitEthernet0/0/0]pim dm

[R3-GigabitEthernet0/0/1]igmp enable


<R4>dis pim routing-table //View the table entries for pim

 VPN-Instance: public net

 Total 1 (*, G) entry; 1 (S, G) entry


 (*, 239.1.1.1)

     Protocol: pim-dm, Flag: WC EXT

     UpTime: 00:20:44

     Upstream interface: NULL

         Upstream neighbor: NULL

         RPF prime neighbor: NULL

     Downstream interface(s) information: None


 (172.16.1.100, 239.1.1.1)

     Protocol: pim-dm, Flag: EXT ACT

     UpTime: 00:03:39

     Upstream interface: GigabitEthernet0/0/1

         Upstream neighbor: 24.1.1.2

         RPF prime neighbor: 24.1.1.2

     Downstream interface(s) information: None



After joining the group, start vcl and receive multicast traffic.


View IGMPv1 message experiment


[R4-GigabitEthernet0/0/2]undo igmp enable //To enable pim, you need to close igmp first

[R4-GigabitEthernet0/0/2]pim dm

[R4-GigabitEthernet0/0/2]igmp enable

[R4-GigabitEthernet0/0/2]igmp version 1


<R4>dis igmp interface g0/0/2 //View the igmp information of interface 0/0/2

Interface information of VPN-Instance: public net

GigabitEthernet0/0/2(192.168.1.1):

IGMP is enabled

Current IGMP version is 1

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: -

Querier for IGMP: 192.168.1.1 (this router)

Total 1 IGMP Group reported


The IGMP querier relies on the PIM protocol hello message for election.


1.PIM hello message



2. General group query message



3. Member relationship report message



View IGMPv2 message experiment


The default version is v2


Specific group query message



membership report message



leave message



View IGMPv3 message experiment


Add multicast source IP



PIM SM


Static RP


All pim routers create loopback interfaces and all communicate with igp.

Set R2 to RP

[R2-LoopBack0]ip address 3.3.3.3 32

[R2-pim]static-rp 2.2.2.2


[R1-LoopBack0]ip address 1.1.1.1 32

[R1-pim]static-rp 2.2.2.2


[R3-LoopBack0]ip address 3.3.3.3 32


[R3-pim]static-rp 2.2.2.2


[R4-LoopBack0]ip address 4.4.4.4 32


[R4-pim]static-rp 2.2.2.2


[R2-pim]dis pim routing-table

 VPN-Instance: public net

 Total 1 (*, G) entry; 1 (S, G) entry


 (*, 239.1.1.1)

     RP: 2.2.2.2 (local)

     Protocol: pim-sm, Flag: WC

     UpTime: 00:00:27

     Upstream interface: Register

         Upstream neighbor: NULL

         RPF prime neighbor: NULL

     Downstream interface(s) information:

     Total number of downstreams: 1

         1: GigabitEthernet0/0/2

             Protocol: pim-sm, UpTime: 00:00:27, Expires: 00:03:03


 (172.16.1.100, 239.1.1.1)

     RP: 2.2.2.2 (local)

     Protocol: pim-sm, Flag: SPT 2MSDP ACT

     UpTime: 00:00:03

     Upstream interface: GigabitEthernet0/0/0

         Upstream neighbor: 13.1.1.1

         RPF prime neighbor: 13.1.1.1

     Downstream interface(s) information:

     Total number of downstreams: 1

         1: GigabitEthernet0/0/2

             Protocol: pim-sm, UpTime: 00:00:03, Expires: -


Dynamic RP


[R2-LoopBack0]pim sm //If you elect RP dynamically, you need to enable PIM SM mode on the loopback interface.

[R2-pim]c-bsr priority 100 //By controlling the priority of C-BSR, elect it to become the official BSR

[R2-pim]c-bsr LoopBack 0


[R1-LoopBack0]pim sm

[R1-pim]c-bsr LoopBack 0


[R3-LoopBack0]pim sm


[R3-pim]c-bsr LoopBack 0


[R4-LoopBack0]pim sm


[R4-pim]c-bsr LoopBack 0


[R2-pim]dis pim bsr-info //View bsr information

 VPN-Instance: public net

 Elected AdminScoped BSR Count: 0

 Elected BSR Address: 2.2.2.2

     Priority: 100

     Hash mask length: 30

     State: Elected

     Scope: Not scoped

     Uptime: 00:06:07

     Next BSR message scheduled at: 00:00:53

     C-RP Count: 0

 Candidate AdminScoped BSR Count: 0

 Candidate BSR Address: 2.2.2.2

     Priority: 100

     Hash mask length: 30

     State: Elected

     Scope: Not scoped

     Wait to be BSR: 0

     

     

[R1-pim]c-rp LoopBack 0

[R2-pim]c-rp LoopBack 0

[R3-pim]c-rp LoopBack 0

[R4-pim]c-rp LoopBack 0


[R2-pim]dis pim rp-info

 VPN-Instance: public net

 PIM-SM BSR RP Number:4

 Group/MaskLen: 224.0.0.0/4

     RP: 1.1.1.1

     Priority: 0

     Uptime: 00:02:21

     Expires: 00:02:09

 Group/MaskLen: 224.0.0.0/4

     RP: 2.2.2.2 (local)

     Priority: 0

     Uptime: 00:02:14

     Expires: 00:02:16

 Group/MaskLen: 224.0.0.0/4

     RP: 3.3.3.3

     Priority: 0

     Uptime: 00:02:11

     Expires: 00:02:19

 Group/MaskLen: 224.0.0.0/4

     RP: 4.4.4.4

     Priority: 0

     Uptime: 00:02:08

     Expires: 00:02:22

 PIM SM static RP Number:1

     Static RP: 2.2.2.2 (local)