Friday, January 20, 2012

Multicast sparse mode SPT switchover

Background
Cisco router would automatically attempt to do a SPT-switchover as soon as it receives first  multicast packet by default and learns source IP of the multicast source. What exactly happens here is the explanation
Explanation
Once first hop router i.e router directly attached to the receiver starts receiving multicast packets it immediately knows about the source IP address. First thing it does, it internally checks the commands ip pim spt-threshold <>. If the incoming multicast flow is under the configured threshold it continues the same path via RP i.e only (*,G) entries up to the RP. But if it crosses the threshold limit it does this.

Now since it knows about the source IP (which it did not not know earlier) it consults its unicast routing table to see source IP is reachable by which interface. It then sends a PIM join message towards the source out of the interface by which source IP address is reachable of. It does this even if this outgoing interface is leading towards RP itself. After sending join message towards the source an SPT is built between source DR and this router (directly attached to the receiver). At this stage all the routers in the SPT have (S,G) entries. This could be seperate path towards the source or via RP towards the source.

This router now starts getting two flows just for a moment, then immediately it sends a prune message to the RP to remove itself from the shared tree, this prune message is then reaches to RP as hop by hop basis, the RP further sends it towards the source in order to leave SPT for this particular group.

At this stage router attached to the receiver get only one multicast flow from the source via shotest path. 

No comments: