Hands-On Lab: Configuring HSRP-Aware PIM for Multicast Redundancy

This hands-on lab configures PIM in an HSRP environment, verifying that multicast forwarding correctly follows the active HSRP router rather than being split unpredictably between both routers in the redundancy pair.

PIM NSF-Aware HSRPMulticast Designated Router ElectionHSRP Active Router Multicast Alignment

~4 دقیقه مطالعه · آخرین به‌روزرسانی ۴ مهر ۱۴۰۵

Lab Objective

Configure PIM Sparse Mode on two routers running HSRP for the same LAN segment, verify PIM's own Designated Router election aligns with the HSRP active router by default, and confirm multicast traffic is forwarded consistently through the active router rather than being duplicated or dropped due to disagreement between the two redundancy mechanisms.

Lab Purpose

HSRP, covered extensively earlier in this series, and PIM each run their own independent election process on a shared segment — HSRP elects an active router for unicast default gateway purposes, while PIM independently elects a Designated Router (DR) for multicast forwarding. Without deliberate alignment, these two elections could disagree, causing multicast traffic to take an unexpected path relative to unicast traffic on the same LAN.

Lab Topology

R1 (HSRP active, higher priority) ---- Gi0/1 ---- Switch1
R2 (HSRP standby) ---- Gi0/1 ---- Switch1

Virtual IP: 192.168.190.1/24
Receiver connected via Switch1, in the
same VLAN

PIM sparse-mode enabled on both R1 and
R2's Gi0/1, plus their WAN-facing interfaces
toward a source/RP elsewhere

Task 1: Verify HSRP's Active/Standby State

Confirm R1 is HSRP active and R2 is standby, as configured in the earlier HSRP lab.

Task 2: Verify PIM's Independent DR Election on the Same Segment

Check which router PIM elected as Designated Router on the shared Gi0/1 segment.

Task 3: Confirm Default PIM DR Election Criteria

Understand that PIM's DR election is based on highest IP address by default, independent of HSRP state entirely.

Task 4: Verify Multicast Forwarding Follows the PIM DR

Generate multicast traffic and confirm it is forwarded onto the segment specifically by the PIM DR, checking whether this aligns with or diverges from the HSRP active router.

Task 5: Align PIM DR Priority with HSRP if a Mismatch Exists

If PIM's DR differs from the HSRP active router, adjust PIM DR priority on the interface to bring the two into alignment.

Solution and Verification

R1# show standby brief

Interface  Grp  Pri P State   Active   Standby   Virtual IP
Gi0/1      1    150 P Active  local    192.168.190.3  192.168.190.1
-- R1 confirmed as HSRP active, consistent
-- with the earlier HSRP lab

R1# show ip pim interface gigabitethernet0/1

Address          Interface   PIM  Nbr    Query   DR
                              Count  Intvl
192.168.190.2    Gi0/1        on    2      30    192.168.190.3
-- The DR IP shown is 192.168.190.3 --
-- R2's actual interface address, NOT R1's
-- (192.168.190.2) -- PIM elected R2 as DR
-- purely because it has the higher raw IP
-- address on this segment, completely
-- unaware of HSRP's active/standby roles

-- This confirms PIM's default election
-- criterion: highest IP address wins DR,
-- with no consideration of HSRP state,
-- priority, or any unicast forwarding
-- role whatsoever

Source> [sends multicast traffic]

R2# show ip mroute 239.1.1.1

(*, 239.1.1.1), ...
  Outgoing interface list:
    GigabitEthernet0/1, Forward
-- R2, the PIM DR (but HSRP standby), is
-- the one actually forwarding multicast
-- traffic onto the shared segment -- a
-- potential inconsistency worth noting,
-- though not necessarily broken, since
-- multicast and unicast forwarding roles
-- are logically independent

-- To deliberately align PIM's DR election
-- with the HSRP active router (R1),
-- increase R1's PIM DR priority above R2's:

R1(config)# interface gigabitethernet0/1
R1(config-if)# ip pim dr-priority 200

R2(config)# interface gigabitethernet0/1
R2(config-if)# ip pim dr-priority 100

R1# show ip pim interface gigabitethernet0/1

Address          Interface   PIM  Nbr    Query   DR
                              Count  Intvl
192.168.190.2    Gi0/1        on    2      30    192.168.190.2
-- R1 (192.168.190.2) is now the PIM DR,
-- matching its role as HSRP active --
-- dr-priority, when configured, always
-- takes precedence over the default
-- highest-IP tiebreaker

Key Takeaway

PIM's DR election and HSRP's active/standby election are entirely independent processes by default, and nothing automatically synchronizes them — a network relying on both should deliberately configure ip pim dr-priority to match the intended HSRP active router, since leaving both at default settings can result in multicast traffic taking an unexpected path relative to unicast traffic on the same segment, a subtle design detail easy to overlook when HSRP and PIM are configured by different engineers or at different times.

نوشته و پژوهش‌شده توسط دکتر شاهین صیامی

مقالات مرتبط

Hands-On Lab: Final Comprehensive CCNP Troubleshooting Challenge (BGP, DMVPN, and QoS Integration)

This hands-on lab presents a complex multi-layer failure across an integrated BGP-over-DMVPN topology combined with QoS marking, requiring systematic diagnosis of a route reflector misconfiguration, an NHRP registration failure, and an incorrectly applied QoS policy simultaneously affecting the same network.

ادامه

Hands-On Lab: Configuring BGP over DMVPN

This hands-on lab runs iBGP as the routing protocol across the same DMVPN hub-and-spoke topology used in the two previous labs, configuring the hub as a route reflector so spokes learn each other's routes without a full iBGP mesh, combining two previously separate concepts into one integrated design.

ادامه

Hands-On Lab: Configuring OSPF over DMVPN

This hands-on lab runs OSPF as the dynamic routing protocol across the same DMVPN hub-and-spoke topology, configuring the tunnel interface as an OSPF point-to-multipoint network type to correctly handle the hub-and-spoke adjacency pattern without requiring the broadcast network type's DR/BDR election.

ادامه

Hands-On Lab: Configuring EIGRP over DMVPN

This hands-on lab runs EIGRP as the dynamic routing protocol across the DMVPN hub-and-spoke topology built in earlier labs, verifying neighbor relationships form correctly across the multipoint tunnel and routes propagate without requiring per-spoke static configuration on the hub.

ادامه

Hands-On Lab: Configuring HSRP MD5 Authentication

This hands-on lab configures MD5 authentication on an HSRP group, verifying two routers with matching authentication strings form a normal active/standby relationship while a router with a mismatched string is excluded from the group entirely.

ادامه

Hands-On Lab: Configuring Cisco Umbrella-Style DNS Security via DNS Forwarding Redirection

This hands-on lab configures a router to redirect all client DNS queries toward a security-focused DNS resolver using DNS forwarding interception, approximating cloud-delivered DNS security enforcement without requiring per-client configuration changes.

ادامه