0% found this document useful (0 votes)
22 views33 pages

VXLAN Multicast Anycast RP

The document discusses configuring VXLAN Multicast Anycast RP to avoid single points of failure in multicast routing. It explains the use of anycast RP, where multiple devices share the same IP address as the Rendezvous Point, and outlines the necessary configurations and verification steps. The document also highlights the importance of synchronizing information between RPs using protocols like PIM and MSDP.

Uploaded by

sumanth.m
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views33 pages

VXLAN Multicast Anycast RP

The document discusses configuring VXLAN Multicast Anycast RP to avoid single points of failure in multicast routing. It explains the use of anycast RP, where multiple devices share the same IP address as the Rendezvous Point, and outlines the necessary configurations and verification steps. The document also highlights the importance of synchronizing information between RPs using protocols like PIM and MSDP.

Uploaded by

sumanth.m
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 33

VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

You are here: Home » VXLAN

VXLAN Multicast Anycast RP 

Lesson Contents Course


1. Con!guration
2. Veri!cation
Contents
3. Packet Capture VXLAN
3.1. PIM Join (LEAF1 to Multicast group)
3.2. PIM Register (LEAF1 to SPINES) Introduction to Virtual
3.3. PIM Register-stop (SPINES to LEAF1) Extensible LAN (VXLAN)
3.4. PIM Register (SPINE1 to SPINE2) VXLAN Static Ingress
3.5. PIM Register-stop (SPINE2 to SPINE1) Replication
4. Conclusion VXLAN Flood and Learn
Multicast Data Plane

In the VXLAN Flood and Learn Multicast Data Plane lesson, we con!gured VXLAN
VXLAN "ood Anycast
Multicast and
RP
learn using multicast. This worked, but we had a single spine switch con!gured as the static
VXLAN MP-BGP EVPN L2 VNI
Rendezvous Point (RP). If you don’t want a single point of failure, you can add a second spine
VXLAN MP-BGP EVPN L3 VNI
switch. This introduces another issue: which spine switch should be the RP?
MP-BGP EVPN VXLAN ARP
Suppression
You can con!gure RP redundancy with protocols like auto-RP or bootstrap. However, failover
VXLAN Underlay OSPF
for these protocols is not very fast.

Another option is anycast RP. This is a technique where multiple devices act as a single RP
using the same IP address. However, this also introduces an issue. Leaf switches have two
uplinks, one to each spine switch. It’s possible that some leaf switches join one spine switch,
and others join the second spine switch. This is not random; we use a hashing algorithm to
decide which uplink to use:

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 1 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

LEAF1# show ip multicast vrf default


Multicast Routing VRFs (1 VRFs)
VRF Name VRF Table Route Group Source
(*,G) State
ID ID Count Count Count
Count

default 1 0x00000001 3 1 1 1
Up
Multipath configuration (1): s-g-hash
Resilient configuration: Disabled

ECMP multicast uses the s-g-hash based on the source and group address. This hashing
algorithm is predictable because it does not use random values.

We need something that can synchronize information between RPs. There are two protocols
we can use for this:

Multicast Source Discovery Protocol (MSDP)


PIM

Cisco Nexus switches can use anycast RP without MSDP. PIM messages will be exchanged
between spine switches so all spine switches know about the multicast sources. In this lesson,
I’ll explain how to con!gure anycast RP and we’ll do a packet capture to see it in action.

1. Configuration
This is the topology we’ll use:

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 2 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

We’ll need two spine switches. I’m using Cisco NX-OS 9000v version 9.3(9) on the switches. The
hosts (S1 and S2) are simple Ubuntu containers because they only need to send some ICMP
tra#c between each other.

I use static MAC addresses on all devices so that it’s easier to debug and do a packet capture.
All MAC addresses look like 0050.c253.X00Y, where X is the device number and Y is the
interface number.

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 3 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

Also, since we already con!gured the underlay and overlay in the VXLAN "ood and learn
multicast lesson, I’m focusing only on the con!guration of anycast RP in this lesson. We start
with a pre-con!gured underlay/overlay network.

14:05

Con!gurations

Want to take a look for yourself? Here, you will !nd the startup con!guration of each device.
You can also download the containerlab topology.

LEAF1
hostname LEAF1

feature ospf

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 4 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

feature pim
feature vn-segment-vlan-based
feature nv overlay

vlan 10
vn-segment 10010

interface nve1
no shutdown
source-interface loopback0
member vni 10010
mcast-group 239.1.1.1

interface Ethernet1/1
no switchport
mac-address 0050.c253.3001
ip address 192.168.13.3/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface Ethernet1/2
no switchport
mac-address 0050.c253.3002
ip address 192.168.23.3/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface Ethernet1/3
no shutdown
switchport access vlan 10

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 5 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

interface loopback0
ip address 3.3.3.3/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

router ospf 1

LEAF2
hostname LEAF2

feature ospf
feature pim
feature vn-segment-vlan-based
feature nv overlay

vlan 10
vn-segment 10010

interface nve1
no shutdown
source-interface loopback0
member vni 10010
mcast-group 239.1.1.1

interface Ethernet1/1
no switchport
mac-address 0050.c253.4001
ip address 192.168.14.4/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 6 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

interface Ethernet1/2
no switchport
mac-address 0050.c253.4002
ip address 192.168.24.4/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface Ethernet1/3
no shutdown
switchport access vlan 10

interface loopback0
ip address 4.4.4.4/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

router ospf 1

SPINE1
hostname SPINE1

feature ospf
feature pim

interface Ethernet1/1
no switchport
mac-address 0050.c253.1001
ip address 192.168.13.1/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 7 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

no shutdown

interface Ethernet1/2
no switchport
mac-address 0050.c253.1002
ip address 192.168.14.1/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface loopback0
ip address 1.1.1.1/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

router ospf 1

SPINE2
hostname SPINE2

feature ospf
feature pim

interface Ethernet1/1
no switchport
mac-address 0050.c253.2001
ip address 192.168.23.2/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 8 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

interface Ethernet1/2
no switchport
mac-address 0050.c253.2002
ip address 192.168.24.2/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface loopback0
ip address 2.2.2.2/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

router ospf 1

The con!guration is almost identical to when we used multicast with a single RP. To con!gure
anycast RP, we need to do this:

Create a new loopback interface on the spine switches with the IP address we want to
use for anycast RP.
Enable OSPF on this loopback.
Enable PIM on this loopback.
Con!gure the spine switches to use the IP address on the new loopback interface as RP.
Con!gure all IP addresses of the spine switches for the anycast RP set.
Con!gure all switches to use the anycast RP address.

This is what anycast RP looks like on the spine switches:

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 9 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

We’ll use 12.12.12.12 as the RP address. The spine switches still need a unique IP address on
their loopback 0 interfaces because they use this to communicate with each other.

Let’s get started:

SPINE1 & SPINE2


(config)# interface loopback1
(config-if)# ip address 12.12.12.12/32
(config-if)# ip router ospf 1 area 0.0.0.0
(config-if)# ip pim sparse-mode

Now we con!gure the RP set:

SPINE1 & SPINE2


(config)# ip pim anycast-rp 12.12.12.12 1.1.1.1
(config)# ip pim anycast-rp 12.12.12.12 2.2.2.2

On both spine switches, we need to con!gure:

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 10 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

the IP address we want to use for anycast RP.


Our own IP address.
The IP address of the other spine switch.

On all switches, we con!gure 12.12.12.12 as the RP:

SPINE1, SPINE2, LEAF1 & LEAF2


(config)# ip pim rp-address 12.12.12.12

That’s all we need to do.

2. Verification
Let’s make sure we have PIM neighbors:

SPINE1# show ip pim neighbor


PIM Neighbor Status for VRF "default"
Neighbor Interface Uptime Expires DR
Bidir- BFD ECMP Redirect
Priority
Capable State Capable
192.168.13.3 Ethernet1/1 1d01h 00:01:35 1 yes
n/a no
192.168.14.4 Ethernet1/2 1d01h 00:01:22 1 yes
n/a no

SPINE2# show ip pim neighbor


PIM Neighbor Status for VRF "default"
Neighbor Interface Uptime Expires DR
Bidir- BFD ECMP Redirect
Priority
Capable State Capable
192.168.23.3 Ethernet1/1 1d01h 00:01:16 1 yes

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 11 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

n/a no
192.168.24.4 Ethernet1/2 1d01h 00:01:43 1 yes
n/a no

That seems to be the case. Let’s check the RP settings:

SPINE1# show ip pim rp


PIM RP Status Information for VRF "default"
BSR disabled
Auto-RP disabled
BSR RP Candidate policy: None
BSR RP policy: None
Auto-RP Announce policy: None
Auto-RP Discovery policy: None

Anycast-RP 12.12.12.12 members:


1.1.1.1* 2.2.2.2

RP: 12.12.12.12*, (0),


uptime: 1d01h priority: 255,
RP-source: (local),
group ranges:
224.0.0.0/4

SPINE2# show ip pim rp


PIM RP Status Information for VRF "default"
BSR disabled
Auto-RP disabled
BSR RP Candidate policy: None
BSR RP policy: None
Auto-RP Announce policy: None
Auto-RP Discovery policy: None

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 12 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

Anycast-RP 12.12.12.12 members:


2.2.2.2* 1.1.1.1

RP: 12.12.12.12*, (0),


uptime: 1d01h priority: 255,
RP-source: (local),
group ranges:
224.0.0.0/4

SPINE1 and SPINE2 know about the RP address, and they know about each other. This is what
the leaf switches think of it:

LEAF1# show ip pim rp


PIM RP Status Information for VRF "default"
BSR disabled
Auto-RP disabled
BSR RP Candidate policy: None
BSR RP policy: None
Auto-RP Announce policy: None
Auto-RP Discovery policy: None

RP: 12.12.12.12, (0),


uptime: 1d01h priority: 255,
RP-source: (local),
group ranges:
224.0.0.0/4

LEAF2# show ip pim rp


PIM RP Status Information for VRF "default"
BSR disabled
Auto-RP disabled
BSR RP Candidate policy: None
BSR RP policy: None

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 13 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

Auto-RP Announce policy: None


Auto-RP Discovery policy: None

RP: 12.12.12.12, (0),


uptime: 1d01h priority: 255,
RP-source: (local),
group ranges:
224.0.0.0/4

The leaf switches use 12.12.12.12 as the RP. Here are the multicast routing tables:

SPINE1# show ip mroute 239.1.1.1


IP Multicast Routing Table for VRF "default"

(*, 239.1.1.1/32), uptime: 00:02:59, pim ip


Incoming interface: loopback1, RPF nbr: 12.12.12.12
Outgoing interface list: (count: 1)
Ethernet1/2, uptime: 00:02:59, pim

(3.3.3.3/32, 239.1.1.1/32), uptime: 00:02:34, pim mrib ip


Incoming interface: Ethernet1/1, RPF nbr: 192.168.13.3, internal
Outgoing interface list: (count: 1)
Ethernet1/2, uptime: 00:02:34, pim

(4.4.4.4/32, 239.1.1.1/32), uptime: 00:02:39, pim mrib ip


Incoming interface: Ethernet1/2, RPF nbr: 192.168.14.4, internal
Outgoing interface list: (count: 0)

you can see LEAF1 and LEAF2 as a source for 239.1.1.1. Same thing on SPINE2:

SPINE2# show ip mroute 239.1.1.1


IP Multicast Routing Table for VRF "default"

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 14 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

(*, 239.1.1.1/32), uptime: 00:02:58, pim ip


Incoming interface: loopback1, RPF nbr: 12.12.12.12
Outgoing interface list: (count: 1)
Ethernet1/1, uptime: 00:01:11, pim

(3.3.3.3/32, 239.1.1.1/32), uptime: 00:02:36, pim mrib ip


Incoming interface: Ethernet1/1, RPF nbr: 192.168.23.3, internal
Outgoing interface list: (count: 0)

(4.4.4.4/32, 239.1.1.1/32), uptime: 00:02:41, pim mrib ip


Incoming interface: Ethernet1/2, RPF nbr: 192.168.24.4, internal
Outgoing interface list: (count: 1)
Ethernet1/1, uptime: 00:01:11, pim

Both spine switches have learned that LEAF1 and LEAF2 are sources. Let’s check the leaf
switches:

LEAF1# show ip mroute 239.1.1.1


IP Multicast Routing Table for VRF "default"

(*, 239.1.1.1/32), uptime: 00:01:24, ip pim nve


Incoming interface: Ethernet1/2, RPF nbr: 192.168.23.2
Outgoing interface list: (count: 1)
nve1, uptime: 00:01:18, nve

(3.3.3.3/32, 239.1.1.1/32), uptime: 00:01:24, mrib ip pim nve


Incoming interface: loopback0, RPF nbr: 3.3.3.3
Outgoing interface list: (count: 1)
Ethernet1/1, uptime: 00:01:22, pim

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 15 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

LEAF1 shows itself as a source. So does LEAF2:

LEAF2# show ip mroute 239.1.1.1


IP Multicast Routing Table for VRF "default"

(*, 239.1.1.1/32), uptime: 00:03:13, nve ip pim


Incoming interface: Ethernet1/1, RPF nbr: 192.168.14.1
Outgoing interface list: (count: 1)
nve1, uptime: 00:03:13, nve

(4.4.4.4/32, 239.1.1.1/32), uptime: 00:03:13, nve mrib ip pim


Incoming interface: loopback0, RPF nbr: 4.4.4.4
Outgoing interface list: (count: 2)
Ethernet1/2, uptime: 00:01:23, pim
Ethernet1/1, uptime: 00:02:53, pim

Everything is looking good. At the moment, the leaf switches don’t know about each other as
NVE peers:

LEAF1# show nve peers

LEAF2# show nve peers

Let’s send a ping from S1 to S2:

lab@s1:~$ ping 172.16.12.2


PING 172.16.12.2 (172.16.12.2) 56(84) bytes of data.
From 172.16.12.1 icmp_seq=1 Destination Host Unreachable
From 172.16.12.1 icmp_seq=2 Destination Host Unreachable
From 172.16.12.1 icmp_seq=3 Destination Host Unreachable
64 bytes from 172.16.12.2: icmp_seq=4 ttl=64 time=6.98 ms
64 bytes from 172.16.12.2: icmp_seq=5 ttl=64 time=3.76 ms

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 16 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

^C
--- 172.16.12.2 ping statistics ---
5 packets transmitted, 2 received, +3 errors, 42.8571% packet loss,
time 6065ms
rtt min/avg/max/mdev = 3.559/4.567/6.978/1.399 ms, pipe 3

This works. The leaf switches learn about each other:

LEAF1# show nve peers


Interface Peer-IP State LearnType
Uptime Router-Mac
--------- -------------------------------------- ----- --------- ----
---- -----------------
nve1 4.4.4.4 Up DP
00:00:25 n/a

Courses 
LEAF2# Forum
show Support
nve peers Tools    Search … 

Interface Peer-IP State LearnType


Uptime Router-Mac
--------- -------------------------------------- ----- --------- ----
---- -----------------
nve1 3.3.3.3 Up DP
00:00:38 n/a

This is good. Everything is working as expected.

3. Packet Capture
The big question remains…when one spine switch receives a PIM packet and learns about a
source, how does the other spine switch learn this too? We can answer that by doing a packet
capture.

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 17 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

10:32

If you want to follow along, here is the capture !le:

VXLAN Multicast Anycast RP PIM

Besides the packet capture, enabling debug ip pim data-register and debug
 ip pim data-register receive will show you the decisions of the spine
switches when they receive a PIM packet.

I’ll capture both interfaces on the spine switches. To start with a clean slate, we’ll shut the
interfaces that connect to the hosts and the NVE interfaces:

LEAF1 & LEAF2


(config)# interface nve1
(config-if-nve)# shutdown

(config)# interface e1/3

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 18 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

(config-if)# shutdown

We’ll also clear the multicast routing tables:

LEAF1, LEAF2, SPINE1 & SPINE2


# clear ip mroute *

Now we’ll unshut the NVE interface on LEAF1:

LEAF1(config)# interface nve1


LEAF1(config-if-nve)# no shutdown

This will cause LEAF1 to register itself with one of the two spine switches.

3.1. PIM Join (LEAF1 to Multicast group)


When the NVE interface is up, LEAF1 sends a PIM join message for 239.1.1.1:

Frame 1: 76 bytes on wire (608 bits), 76 bytes captured (608 bits) on


interface eth1, id 0
Ethernet II, Src: NanShanBridg_53:30:02 (00:50:c2:53:30:02), Dst:
IPv4mcast_0d (01:00:5e:00:00:0d)
Internet Protocol Version 4, Src: 192.168.23.3, Dst: 224.0.0.13
Protocol Independent Multicast
0010 .... = Version: 2
.... 0011 = Type: Join/Prune (3)
Reserved byte(s): 00
Checksum: 0xe5fe [correct]
[Checksum Status: Good]
PIM Options
Upstream-neighbor: 192.168.23.2
Address Family: IPv4 (1)
Encoding Type: Native (0)

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 19 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

Unicast: 192.168.23.2
Reserved byte(s): 00
Num Groups: 1
Holdtime: 210
Group 0
Group 0: 239.1.1.1/32
Address Family: IPv4 (1)
Encoding Type: Native (0)
Flags: 0x00
Masklen: 32
Group: 239.1.1.1
Num Joins: 1
IP address: 12.12.12.12/32 (SWR)
Address Family: IPv4 (1)
Encoding Type: Native (0)
Flags: 0x07, Sparse, WildCard, Rendezvous Point
Tree
Masklen: 32
Source: 12.12.12.12
Num Prunes: 1
IP address: 3.3.3.3/32 (SR)
Address Family: IPv4 (1)
Encoding Type: Native (0)
Flags: 0x05, Sparse, Rendezvous Point Tree
Masklen: 32
Source: 3.3.3.3

This PIM join is sent to SPINE2 because of the hashing algorithm. You can see this by looking
at the Upstream-neighbor !eld, which shows 192.168.23.2. This is how LEAF1 joins the RPT.

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 20 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

3.2. PIM Register (LEAF1 to SPINES)


Next, LEAF1 sends a PIM register and, this time, uses another link:

Frame 3: 62 bytes on wire (496 bits), 62 bytes captured (496 bits) on


interface eth1, id 0
Ethernet II, Src: NanShanBridg_53:30:01 (00:50:c2:53:30:01), Dst:
NanShanBridg_53:10:01 (00:50:c2:53:10:01)
Internet Protocol Version 4, Src: 3.3.3.3, Dst: 12.12.12.12
Protocol Independent Multicast
0010 .... = Version: 2
.... 0001 = Type: Register (1)
Reserved byte(s): 00
Checksum: 0x9eff [correct]
[Checksum Status: Good]
PIM Options

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 21 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

Flags: 0x40000000
0100 .... = IP Version: IPv4 (4)
Internet Protocol Version 4, Src: 3.3.3.3, Dst: 239.1.1.1

The PIM register is a unicast packet sent to the anycast RP address (12.12.12.12) and, because
of the hashing algorithm, ends up at SPINE1. We can see this because the destination MAC
address is 00:50:c2:53:10:01.

3.3. PIM Register-stop (SPINES to LEAF1)


SPINE1 will send a PIM register-stop to LEAF1:

Frame 4: 60 bytes on wire (480 bits), 60 bytes captured (480 bits) on


interface eth1, id 0
Ethernet II, Src: NanShanBridg_53:10:01 (00:50:c2:53:10:01), Dst:
NanShanBridg_53:30:01 (00:50:c2:53:30:01)

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 22 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

Internet Protocol Version 4, Src: 12.12.12.12, Dst: 3.3.3.3


Protocol Independent Multicast
0010 .... = Version: 2
.... 0010 = Type: Register-stop (2)
Reserved byte(s): 00
Checksum: 0xe5d6 [correct]
[Checksum Status: Good]
PIM Options
Group: 239.1.1.1/32
Address Family: IPv4 (1)
Encoding Type: Native (0)
Flags: 0x00
Masklen: 32
Group: 239.1.1.1
Source: 3.3.3.3
Address Family: IPv4 (1)
Encoding Type: Native (0)
Unicast: 3.3.3.3

SPINE1 (00:50:c2:53:10:01) will tell LEAF1 to stop sending multicast tra#c to the group. The
source is the anycast RP address, and the destination is LEAF1’s loopback.

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 23 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

3.4. PIM Register (SPINE1 to SPINE2)


From LEAF1’s perspective, we are done. The PIM register, however, was sent to SPINE1, so
how does SPINE2 know that LEAF1 is registered to 239.1.1.1? When a spine switch receives a
PIM register from a leaf switch, it registers the source and sends a PIM register to all RPs in the
RP set, such as SPINE2. You can see it here:

Frame 2: 62 bytes on wire (496 bits), 62 bytes captured (496 bits) on


interface eth2, id 1
Ethernet II, Src: NanShanBridg_53:10:02 (00:50:c2:53:10:02), Dst:
NanShanBridg_53:40:01 (00:50:c2:53:40:01)
Internet Protocol Version 4, Src: 1.1.1.1, Dst: 2.2.2.2
Protocol Independent Multicast
0010 .... = Version: 2
.... 0001 = Type: Register (1)
Reserved byte(s): 00

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 24 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

Checksum: 0x9eff [correct]


[Checksum Status: Good]
PIM Options
Flags: 0x40000000
0... .... .... .... .... .... .... .... = Border: No
.1.. .... .... .... .... .... .... .... = Null-Register:
Yes
0100 .... = IP Version: IPv4 (4)
Internet Protocol Version 4, Src: 3.3.3.3, Dst: 239.1.1.1

Above, we see the PIM register from SPINE1 to SPINE2 that goes through LEAF2.

3.5. PIM Register-stop (SPINE2 to SPINE1)


When SPINE2 receives the PIM register, it replies with a PIM register-stop to SPINE1:

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 25 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

Frame 6: 60 bytes on wire (480 bits), 60 bytes captured (480 bits) on


interface eth2, id 1
Ethernet II, Src: NanShanBridg_53:20:02 (00:50:c2:53:20:02), Dst:
NanShanBridg_53:40:02 (00:50:c2:53:40:02)
Internet Protocol Version 4, Src: 2.2.2.2, Dst: 1.1.1.1
Protocol Independent Multicast
0010 .... = Version: 2
.... 0010 = Type: Register-stop (2)
Reserved byte(s): 00
Checksum: 0xe5d6 [correct]
[Checksum Status: Good]
PIM Options
Group: 239.1.1.1/32
Address Family: IPv4 (1)
Encoding Type: Native (0)
Flags: 0x00
Masklen: 32
Group: 239.1.1.1
Source: 3.3.3.3
Address Family: IPv4 (1)
Encoding Type: Native (0)
Unicast: 3.3.3.3

This packet is in response to the PIM register from SPINE1 to SPINE2.

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 26 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

Don’t be confused by seeing MAC address 00:50:c2:53:40:01 (LEAF2) as the


destination. Keep in mind that we don’t have a link between spines, and the

interfaces between the spine and leaf switches are routed interfaces. This packet
makes it from SPINE1 to SPINE2 by going through LEAF2.

Con!gurations
Want to take a look for yourself? Here, you will !nd the !nal con!guration of each device.

LEAF1
hostname LEAF1

feature ospf
feature pim

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 27 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

feature vn-segment-vlan-based
feature nv overlay

ip pim rp-address 12.12.12.12 group-list 224.0.0.0/4

vlan 10
vn-segment 10010

interface nve1
no shutdown
source-interface loopback0
member vni 10010
mcast-group 239.1.1.1

interface Ethernet1/1
no switchport
mac-address 0050.c253.3001
ip address 192.168.13.3/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface Ethernet1/2
no switchport
mac-address 0050.c253.3002
ip address 192.168.23.3/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface Ethernet1/3
no shutdown
switchport access vlan 10

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 28 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

interface loopback0
ip address 3.3.3.3/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

router ospf 1

LEAF2
hostname LEAF2

feature ospf
feature pim
feature vn-segment-vlan-based
feature nv overlay

ip pim rp-address 12.12.12.12 group-list 224.0.0.0/4

vlan 10
vn-segment 10010

interface nve1
no shutdown
source-interface loopback0
member vni 10010
mcast-group 239.1.1.1

interface Ethernet1/1
no switchport
mac-address 0050.c253.4001
ip address 192.168.14.4/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 29 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

ip pim sparse-mode
no shutdown

interface Ethernet1/2
no switchport
mac-address 0050.c253.4002
ip address 192.168.24.4/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface Ethernet1/3
no shutdown
switchport access vlan 10

interface loopback0
ip address 4.4.4.4/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

router ospf 1

SPINE1
hostname SPINE1

feature ospf
feature pim

ip pim rp-address 12.12.12.12 group-list 224.0.0.0/4


ip pim anycast-rp 12.12.12.12 1.1.1.1
ip pim anycast-rp 12.12.12.12 2.2.2.2

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 30 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

interface Ethernet1/1
no switchport
mac-address 0050.c253.1001
ip address 192.168.13.1/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface Ethernet1/2
no switchport
mac-address 0050.c253.1002
ip address 192.168.14.1/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface loopback0
ip address 1.1.1.1/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

interface loopback1
ip address 12.12.12.12/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

router ospf 1

SPINE2
hostname SPINE2

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 31 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

feature ospf
feature pim

ip pim rp-address 12.12.12.12 group-list 224.0.0.0/4


ip pim anycast-rp 12.12.12.12 1.1.1.1
ip pim anycast-rp 12.12.12.12 2.2.2.2

interface Ethernet1/1
no switchport
mac-address 0050.c253.2001
ip address 192.168.23.2/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface Ethernet1/2
no switchport
mac-address 0050.c253.2002
ip address 192.168.24.2/24
ip ospf network point-to-point
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode
no shutdown

interface loopback0
ip address 2.2.2.2/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

interface loopback1
ip address 12.12.12.12/32
ip router ospf 1 area 0.0.0.0
ip pim sparse-mode

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 32 of 33
VXLAN Multicast Anycast RP 07/02/25, 6:38 PM

router ospf 1

4. Conclusion
That’s it. You have now learned how to con!gure Anycast RP for VXLAN:

Spine switches require an additional loopback with the IP address you want to use for
anycast RP.
You need to enable PIM and OSPF on this interface.
Spine switches still require a unique IP address on a separate loopback because they’ll
use this to communicate with each other.
Spine switches forward PIM messages to each other (all switches in the RP set) so that
they all know about the di%erent multicast sources.

I hope you enjoyed this lesson. If you have any questions, please leave a comment. If you want
to learn more details about Anycast RP using PIM only, take a look at RFC 4610.

« Previous Lesson
VXLAN Flood and Learn
Multicast Data Plane
Next Lesson
VXLAN MP-BGP EVPN L2 VNI »

 Ask a question or start a discussion by visiting our Community Forum

© 2013 - 2025 NetworkLessons.com 22072 Disclaimer Privacy Policy Support About

https://networklessons.com/vxlan/vxlan-multicast-anycast-rp Page 33 of 33

You might also like