Ethan Banks Not writing about IT.

OECG – Chapter 20


The book spends the most time on Protocol Independent Multicast Dense Mode (PIM-DM), with barely a mention of the other dense mode multicast routing protocols DVMRP and MOSPF. I’ll cover PIM-DM in this post, and the other 2 in another post before moving on to sparse mode multicast routing protocols.


  • PIM was Cisco proprietary, but is now available via RFCs 2362, 3446 and 3973.
  • PIM is “protocol independent” in that it uses the router’s unicast routing table to perform RPF, no matter how that routing table was populated.
  • PIM Adjacencies and Hello Messages
    • PIMv1 does not use Hellos. Rather, it uses a PIM query wrapped in an IP protocol 2 message to
    • PIMv2 sends a Hello message out every 30 seconds by default.
    • Hellos cause neighbors to be discovered and adjacencies to form.
    • Hellos use IP protocol 103 with a destination IP of – the “All-PIM-Routers” multicast address.
    • Hellos contain the Holdtime value, 3x Hello interval by default. If no Hello is received during the Holdtime, the neighbor is presumed dead.
  • Source-Based Distribution Trees
    • The concept of a source-based distribution treeis that of a source sending a multicast to a router, the dense-mode router flooding the multicast to all interfaces except where it was sourced, with the downstream routers doing the same, until all edge (leaf) routers flooding to segments where multicast recipients are connected.
    • The source is the root; the routers are nodes; the connected segments are branches and leaves.
    • To enable this behavior, there are 2 IOS commands:
      • “ip multicast-routing”
      • “ip pim dense-mode”
    • PIM-DM might have a different logical tree for every source/multicast group. This is notated as “S, G”, such as,, where 172.x is the source, and 226.x is the group.
    • The “show ip mroute” command will show you the routers multicast routing table.
      • Flag C means that the S, G has a directly connected group member.
      • Flag T means that the S, G is forwarded via the shortest-path tree.
      • Flag P means that the S, G is pruned (i.e. the router is not forwarding traffic for that multicast source and group.)
      • The RPF neighbor is the next-hop to get back to the source of the multicast.
  • Prune Message
    • A PIM-DM router that does not wish to receive traffic for a particular multicast group can tell the upstream router (closer to the source), to “prune” the interface that would forward the traffic to him.
    • A “pruned” interface is therefore not “forwarding”. In PIM-DM, an interface will only be pruned for the Prune Timer, 3 minutes by default, after which it goes back to forwarding for that multicast group. (That may seem counter-intuitive, but remember that this is dense mode. The supposition of dense mode is that all routers want to receive all multicast traffic.)
  • How PIM-DM Reacts to a Failed Link
    • Remember that PIM-DM builds the multicast routing table based in part on where the source lives. The source interface is used for reverse path verification (RPF), i.e. loop prevention. So what happens when the link the source lived on is no more?
    • Simply, the router learns the new RPF interface from the unicast routing table.
    • If after this is complete, the upstream router is pruning that interface, the upstream router will be notified by a “Graft” message to begin forwarding immediately.
  • Rules for Pruning (how a PIM-DM router determines that it can request a prune.)
    • The router is receiving multicast packets on a non-RPF interface, thus making this a loop-prevention mechanism.
    • When there are no connected hosts receiving traffic for a certain multicast group. – AND – When there are no downstream routers listening for traffic from that multicast group.
  • Steady-State Operation & “State Refresh” messages
    • PIMv2 improves on the “pruned, added back 3 minutes later, pruned again, added back 3 minutes later” cycle of PIMv1 because of a feature called “state refresh”.
    • State refresh messages are sent by the downstream router just before the prune timer expires. This keeps the interface pruned by the upstream router.
  • Graft Message
    • While this naturally brings to mind American politics, a Graft message allows for a pruned interface to become unpruned immediately.
    • Without the Graft message, the link would be put back into forwarding mode only when prune timers expired, which is inefficient.
By Ethan Banks
Ethan Banks Not writing about IT.

You probably know Ethan Banks because he writes & podcasts about IT. This site is his, but covers other stuff.

Get the details on his about page.