This introduces one problem…how does a router know where to find the source of multicast traffic? Let me show you a picture to explain this:

Above we have a video server that is streaming multicast traffic to 239.1.1.1. At the bottom there’s R6 who received an IGMP membership from a directly connected host who would like to receive this multicast traffic.

How is R6 supposed to know that the video server at 192.168.1.1 is sending multicast traffic for this group? With PIM dense mode, this was simple. Multicast traffic was flooded everywhere which allowed R6 to learn the source address.

To solve this issue, PIM sparse mode uses a RP (Rendezvous Point) in the network. Here’s how it works:

Each router that receives multicast traffic from a source will forward it to the RP.

Each router that wants to receive multicast traffic will go to the RP.

The RP is like a “meeting point” for multicast traffic. Here’s an example:

Above you can see that R5 has become the RP in our network. R1 receives multicast traffic from the video server and forwards it to the RP. At the bottom we have R6 that is receiving this multicast traffic from the RP and it is forwarded to the host.

This does introduce another problem though…how does R6 know where to find the RP? There are a couple of different options for this:

We can manually configure the IP address of the RP on each router.

There are some protocols that can automatically discover the RP in our network. We’ll talk about this later.

Let’s add some more detail to this story. Let’s imagine that we are using the topology above but at the moment, nobody is interested in the multicast traffic. Here’s what happens:

Our video server is forwarding multicast traffic on its interface which is received by R1. Since we are using PIM sparse mode, this router will have to forward the multicast traffic to the RP. Instead of forwarding everything, R1 will only send the first multicast packet. This packet is encapsulated in a PIM register message and forwarded to the RP. Once the RP receives the PIM register message there are two options:

When nobody is interested in the multicast traffic then the RP will reject the PIM register message.

When there is at least one receiver, the RP accepts the RP register message.

For now, let’s say that we don’t have any receivers:

Our RP will respond to R1 with a PIM register stop message. This will inform R1 to stop forwarding any multicast traffic for now. R1 will remain silent for now but not for long:

When we receive the PIM register stop packet, R1 will start a suppression timer. By default this timer is 60 seconds and when the timer is almost expired, R1 will send another packet:

R1 will send another PIM register message but this one doesn’t carry the encapsulated multicast packet. It’s a simple request to ask the RP if it is interested now. This packet is called the PIM register null packet. When we still don’t have any receivers, the RP will send another PIM register stop message. When we do have receivers, the RP will not send a PIM register stop message and R1 will start forwarding the multicast traffic.

Now you know what happens when a source starts sending multicast traffic without any receivers. Let’s see what happens when we do have receivers shall we? Take a look at the picture below:

The host that is connected to R6 would like to receive multicast traffic so it sends an IGMP membership report for the multicast group it wants. R6 now has to figure out how to get to the RP and request it to start forwarding the multicast traffic. It will check its unicast routing table for the IP address of the RP and sends a PIM join message on the interface that is used to reach the RP. In this case, that means the PIM join is forwarded towards R4.

When R4 receives the PIM join, it has to request the RP to start forwarding multicast traffic so it will also send a PIM join. It will check its unicast routing table, finds the interface that is used to reach the RP and sends a PIM join message towards the RP.

The router has received an IGMP membership report from a host on a directly connected interface.

The router has received a PIM join from a downstream router.

When the RP receives the PIM join, it will start forwarding the multicast traffic.

This concept of joining the RP is called the RPT (Root Path Tree) or shared distribution tree. The RP is the root of our tree which decides where to forward multicast traffic to. Each multicast group might have different sources and receivers so we might have different RPTs in our network.

The end result will look like this:

Multicast traffic is now flowing from R1 towards the RP, down to R4, R6 and to our receiver (H1).

Are we done now? Not quite…

If you look closely at the picture above then you might have noticed that R6 has multiple paths towards the source. Right now our multicast traffic is flowing like this:

R1 > R5 > R4 > R6

It’s possible however that this is not the most optimal path. The path from R1 > R2 > R6 has one less router than the current path so if all interfaces are equal, this path is probably better.

Once we are receiving multicast traffic through the RP, it’s possible to switch to the SPT (Source Path Tree).

Here’s what happens next:

When R6 has received the multicast traffic through the RP, it also learned the source address of this traffic. R6 can now decide it wants to use the SPT instead of the RPT to receive this traffic. When it wants this, it will send PIM join messages towards the source. R1 and R2 will start forwarding multicast traffic towards R6, using the best path:

Since R6 is now receiving multicast traffic through R2 and R1, it doesn’t need it from the RP anymore. It will send PIM prune messages towards the RP, informing any routers in between that they can stop forwarding multicast traffic for this group.

You should now have a general idea of how PIM sparse mode works. Let’s configure a small network so you can see this in action!

Configuration

We will use the following topology for this example:

R1, R2, R3 and R4 are our multicast routers that we will configure for PIM sparse mode. S1 will be the source that sends multicast traffic. H3 and H4 are two receivers.

Our routers are running OSPF so that we have full connectivity.

Configurations

Want to follow me with this example? Here you will find the startup configuration of each device.

As soon as I enable PIM sparse mode on the interface our router will start sending PIM hello packets. Here’s what these look like in wireshark:

Above you can see the type of the packet (hello) and it also shows the hold time. For whatever reason, wireshark (version 2.0.1) is showing me a value of 1 but the default is 105 seconds. If you want to take a look at this packet yourself, here’s the capture file if you want to take a look:

As soon as we do this, R1 and R2 will become neighbors since they receive each others PIM hello packets.If they keep receiving them before the holddown timer is expired then they will keep seeing each other as PIM neighbors.:

Above we can see that all routers have become PIM neighbors. The default version on Cisco IOS is PIM version 2. The expiry time is the holddown timer that is counting down. Each time when the router receives a PIM hello packet, it will reset itself to 00:01:45 (105 seconds).

Multicast Routing

Nothing is going on at the moment, let’s see if there is anything in the multicast routing tables:

Above we see the output of R1. At this moment we are not transmitting/receiving any multicast traffic but we still see something in the multicast routing tables. There’s an entry for 224.0.1.40. This multicast group address is used for Auto RP discovery, a protocol that dynamically learns RPs on the network.

The multicast routing table shows a lot of different flags, we’ll discuss some of them in this lesson. To save some virtual real estate pixel space I won’t show them over and over again when we look at the multicast routing tables.

When you are studying multicast it can be annoying to see the autoRP group address, especially in debug messages. Since IOS version 15.0(1)M it’s finally possible to disable auto RP. We don’t need it in this lesson so let’s disable it:

R1, R2, R3 & R4
(config)#no ip pim autorp

Rendezvous Point

In this lesson we are going to keep it simple, instead of learning the RP dynamically we are going to configure it manually. Right now we don’t have a RP so it’s time configure one. R2 will be our RP and we’ll use one of its IP addresses as the RP address. Physical interfaces can go down so it’s better to use a loopback interface for the RP address:

We're Sorry, Full Content Access is for Members Only...

If you like to keep on reading, Become a Member Now! Here is why:

Learn any CCNA, CCNP and CCIE R&S Topic. Explained As Simple As Possible.

Try for Just $1. The Best Dollar You've Ever Spent on Your Cisco Career!

New Lessons

Testimonials

Excellent & Helpful

I feel Rene is very helpful especially when I need help in my job in Cisco. My previous experience is with Linux systems and any open-source projects, creating various services ranging from DNS, Web services to OpenVPN, and OpenRadius. Plus maintaining security of servers. I am currently working at a Stocks Exchange Software company, which requires me to have knowledge both in Cisco, and Unix. I have some basic knowledge on Cisco, however my job requires to have more in-depth knowledge especially in multicast. One thing I love in enrolling on Network Lessons is because of Rene, I feel he is a very helpful and talented Cisco Network Engineer. Hopefully I will learn a lot on Cisco and he may help me, since I started to love Cisco.

Chester Ng NgoUnix Administrator / IT SupportNovember 18, 2015

Now Everyone can Learn Networking!

I found Networklessons.com to provide me very detailed explanations which can guide me from a novice layman to become a networking professional in a very short time. Before I became a member, I thought I knew something about OSPF, BGP, EIGRP, MPLS etc. but now I relealize I did not. A lot of the 'small pixel' how it really works I didn't know at all, but now with help of Networklessons.com I am so confident and know what all of these topics are about. Networklessons.com is not only a website containing lessons to me, but also a consultant which can help and answer the technical issues of networking. Rene answers all my questions with a prompt response. My thanks to Networklessons.com and Rene!

Davis WongNetwork EngineerFebruary 29, 2016

Educationally Rewarding

NetworkLessons.com is one of the best educational websites out there! The ease of finding content, the concise breakdown of complex topics in an easy to understand manner and great staff who will assist in answering questions. What more can you ask for!? If you want to learn networking and grow your skills this is the environment you want to be a part of. I truly love NetworkLessons.com and respect & appreciate the staff. A great investment helping me to achieve my CCNA and now working on my CCNP!

Brian CatlinSystem AdministratorJune 26, 2017

Invaluable Resource

NetworkLessons.com is amazing and my first go-to place for networking information. 99% of the time I don’t need to keep searching and I get a quick and concise tutorial. Overall a fantastic website which I would definitely recommend to others!

Richard WalkerNetwork TechnicianJuly 24, 2016

Great Resource

I just started using Networklessons.com and I like how Rene explains everything in a very thorough manner with examples. His lessons and materials are a great resource for everyone in the networking and consultant field.

Derek CasanaresIT ConsultantJanuary 25, 2016

Great Opportunity To Improve Knowledge

NetworkLessons.com is a great opportunity to improve my network knowledge and help getting my Cisco certifications. Thanks for this excellent site!

Fulvio FerreiraNetwork AnalistJune 9, 2016

A Great Teacher

The learning experience is great, easy to learn and contains straight to the point explanations. Networklessons.com is a great teacher!

Dimitry MicukovIT Tech SupportApril 15, 2016

Nice & Interactive Training

Networklessons.com is a very nice compilation of all Networking Route and Switch Technologies. Very good and interactive explanation of technologies which are easier to simulate on own's lab environment after reading on Networklessons.com.

Abhijeet AgarwalNetwork EngineerOctober 30, 2015

The Best Cisco Training Materials

NetworkLessons.com is the best Cisco training resource I have ever seen. Their lessons are very legible, straight to the point and accurate which are very helpful to pass different Cisco certification exams. And help you out for real world scenarios as well. Keep on going NetworkLessons.com!

Azm Uddin Network EngineerMarch 15, 2017

Passed my CCNA!

NetworkLessons.com played a big part in passing my CCNA/CCNA security certifications. With all the lessons, labs and help from Rene in the forum, it truly feels like you are in a classroom environment. I strongly recommend NetworkLessons.com to all my colleagues and friends interested in Cisco certifications and networking.

Juan IniguezField EngineerJanuary 11, 2016

Comprehensive & Accurate

NetworkLessons.com is very useful and significantly in my work as a technical support. I am enjoying the lessons a lot. The courses and lessons that provided by Rene and his team are easy to read and simple to understand. I also love his instruction videos which make me actually feel as if I were in his classroom. I am going to renew the membership forever!

Hussein SameerTechnical SupportSeptember 11, 2015

Clear and Detailed Lessons

I really enjoy learning about routing protocols. Rene breaks down each routing technology, and explains how to troubleshoot them. He builds small topologies that allow you to learn and implement. As a CCIE candidate, NetworkLessons.com has been a huge help towards me preparing for my CCIE R&S Certification, as well as reaffirming technologies learned in my CCNA/CCNP studies. I would highly recommend NetworkLessons.com to anyone looking to further their understanding of network technologies.