PIM Sparse Mode
Protocol Independent Multicast - Sparse-Mode (PIM-SM) is a protocol for efficiently routing Internet Protocol (IP) packets to multicast groups that may span wide-area and inter-domain internets. The protocol is named protocol-independent because it is not dependent on any particular unicast routing protocol for topology discovery, and sparse-mode because it is suitable for groups where a very low percentage of the nodes (and their routers) will subscribe to the multicast session. Unlike earlier dense-mode multicast routing protocols such as DVMRP and dense multicast routing which flooded packets across the network and then pruned off branches where there were no receivers, PIM-SM explicitly constructs a tree from each sender to the receivers in the multicast group.
Protocol Overview
A PIM-join message must be sent towards the source of the multicast stream.But, a PIM-SM router does not know where to forward a join request, as multicast traffic will be received only after the join request is sent out by the PIM router. This problem is solved using 3 components:
- Rendezvous Point
- Source trees
- Shared- trees
They are explained one after the other.
Rendezvous Point
When configuring PIM-SM on a network, at least one router must be designated as a rendezvous point (RP). The RP could be configured manually, or dynamically through Cisco's Auto-RP[1] or PIMv2's Bootstrap Router (BSR) method. Regardless of which method is used, an RP performs a critical function: it establishes a common reference point from which multicast trees are grown.
Source and Shared Trees
When a source begins sending multicast traffic, the first router it interfaces recognizes the multicast IP address. It creates (source IP address, Group IP address)and ( *, Group IP address) entry in its routing table. The router also encapsulates the multicast packet into a PIM register message[2] and sends it to the RP. The RP immediately sends back a PIM register stop message back, after updating its routing table similarly.
The hosts send IGMP Join message to subscribe to a multicast group.The first-hop router sends a PIM join message to the RP. The RP adds this interface as an outgoing interface for both the trees. Now the source and shared trees are joined.
However, since the RP itself has not subscribed to the multicast group, the RP sends a PIM join to the first-hop router to source. Whenever a new client requests to join the multicast group, the shared tree is extended.