Third refinement: Pruning
By careful application of rules such as those above, it is possible for the routers
to agree on a spanning-tree for the whole network. However, we are still
wasting effort in forwarding datagrams to R
F when it has no group members. The solution
is to introduce special
prune messages.
When a router such as R
F receives a datagram for a multicast group
which has no members on its attached LAN, it sends a prune message back to the
router which forwarded the datagram. This router (R
D in this case) now adjusts its routing
database to remove R
F from the
tree. If we are in the situation of b), R
D will now know it has no-one to forward to,
in which case it can, itself, send a prune message to R
S. With the
addition of pruning, RPB becomes
reverse path multicasting (RPM).
We need to have a method of restoring pruned links in case a host the other
side of the link joins the group. We can either let prunes time-out (at which
point the flow is restored and then, maybe, pruned again) or we can add
explicit
graft messages to the protocol. The former mechanism is a use
of
soft-state which is applied extensively in Internet protocols.
Anticipating that state information is perishable in this way and building in
mechanisms to restore it is fundamental to the operation of the Internet. It
is key concept in making the Internet robust.
By using all these
refinements, we can arrive at a reasonably efficient spanning tree. The two
possibilities are shown. Both of these use shortest path routes from the
source router (R
S) to R
B and R
E. On the face of it, the tree in diagram b) is
more efficient since it involves one fewer transmission hop. However, this is
not necessarily so since the network cloud might might be a LAN. If it is,
then R
S can reach R
B and R
C with one transmission. We may then prefer diagram b) since it
shares the forwarding load between the two routers.