> For the complete documentation index, see [llms.txt](https://ccie-sp.gitbook.io/ccie-spv5.1-labs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://ccie-sp.gitbook.io/ccie-spv5.1-labs/labs/multicast/pim-duplicate-traffic-troubleshooting.md).

# PIM Duplicate Traffic Troubleshooting

Load **pim.dup.traffic.tshoot.cfg** in the Russo SPv4 lab in EVE-NG.

```
#IOS-XE
config replace flash:pim.dup.traffic.tshoot.cfg
 
#IOS-XR
configure
load bootflash:pim.dup.traffic.tshoot.cfg
commit replace
y
```

<figure><img src="https://3072390383-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkUz2C3GqnZcWhoVL6jfk%2Fuploads%2FZOzb4gk0DfNJK7fd2pg4%2Fimage.png?alt=media&amp;token=3518d921-1f10-458d-ae4b-0e2d5396ccf7" alt=""><figcaption></figcaption></figure>

R5 is connected to a LAN segment, with R10 and R6 as HSRP gateways. R5 has joined (\*, 239.1.2.3).

When R3 pings this group, R5 receives duplicate traffic. Explain the issue and find a way to fix it.

<div align="left"><figure><img src="https://3072390383-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkUz2C3GqnZcWhoVL6jfk%2Fuploads%2FOjDrHJ3e7geGtHVmT2IQ%2Fimage.png?alt=media&amp;token=46a1e08c-cbd8-4dd6-893e-d9e93228f3a3" alt=""><figcaption></figcaption></figure></div>

## Answer <a href="#id-3dc2729b-43cc-4bb7-bdce-cd12d4cd4b58" id="id-3dc2729b-43cc-4bb7-bdce-cd12d4cd4b58"></a>

```
#R6, R10
int gi2.100
 no ip pim passive
 ip pim sparse-mode
```

## Explanation <a href="#id-146d2217-f886-4c81-acc5-f39e2d5f3f2f" id="id-146d2217-f886-4c81-acc5-f39e2d5f3f2f"></a>

Currently, R10 and R6 have **ip pim passive** set on the LAN interface. This can be used to prevent formation of a PIM adjacency on an interface facing receivers/senders, while still enable PIM functionality. However, when two routers connect to the LAN segment, each router will end up electing itself as PIM DR and create a distribution tree rooted at the source/RP.

On R10 and R6 we see that Gi2.100 is enabled in mode “passive” and each believes it is the DR.

<div align="left"><figure><img src="https://3072390383-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkUz2C3GqnZcWhoVL6jfk%2Fuploads%2FBf940NFsJS9iGSbCv7lZ%2Fimage.png?alt=media&amp;token=0aba2dab-e3d1-4c22-b156-4502281b7a32" alt=""><figcaption></figcaption></figure></div>

<div align="left"><figure><img src="https://3072390383-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkUz2C3GqnZcWhoVL6jfk%2Fuploads%2FDLNNcitCZu6lICyqpEIq%2Fimage.png?alt=media&amp;token=12947e1c-8aaf-4d51-9435-1dfb18ef45e5" alt=""><figcaption></figcaption></figure></div>

Due to this, both routers build a (\*, G) rooted at the RP, which is XR4. On XR4 we see there are two outgoing interfaces in the OIL. One leading to R10 and one leading to R6.

<div align="left"><figure><img src="https://3072390383-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkUz2C3GqnZcWhoVL6jfk%2Fuploads%2FyohRVcUXAzGRnRbc4Srm%2Fimage.png?alt=media&amp;token=bbc185c5-257a-43f8-bd04-a40a6a2bb046" alt=""><figcaption></figcaption></figure></div>

Once the traffic is seen, it switches over to a SPT. R6 branches this traffic out onto the LAN and to R10. Also notice above that gi2.100 is operating in sparse-dense mode when using **ip pim passive**.

<div align="left"><figure><img src="https://3072390383-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkUz2C3GqnZcWhoVL6jfk%2Fuploads%2FhEFMqVkz1tNzZYlQT8E4%2Fimage.png?alt=media&amp;token=b4420c1e-dd06-423b-ab1c-6a7ecd9a4a3a" alt=""><figcaption></figcaption></figure></div>

Because the interfaces are running in PIM passive mode, no PIM assert is sent on the LAN. This would normally be used in PIM-DM to stop this duplicate traffic. Instead, we should run in normal PIM-SM mode where there are multiple routers on a receiver LAN.

```
#R6, R10
int gi2.100
 no ip pim passive
 ip pim sparse-mode
```

The routers now elect a DR. R6 is elected for the highest IP.

<div align="left"><figure><img src="https://3072390383-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkUz2C3GqnZcWhoVL6jfk%2Fuploads%2Fk0xdewfXiOcRZWyQtztB%2Fimage.png?alt=media&amp;token=b1a173ad-aa5a-4b93-89eb-721f3cb636e2" alt=""><figcaption></figcaption></figure></div>

<div align="left"><figure><img src="https://3072390383-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkUz2C3GqnZcWhoVL6jfk%2Fuploads%2FVrnOBURkwZr8xJKKPnLu%2Fimage.png?alt=media&amp;token=42740f16-edee-4086-9569-ab1bb3f6d9cc" alt=""><figcaption></figcaption></figure></div>

Now that R10 is no longer a DR, it prunes itself from the (\*, G) and (S, G) tree. R6 is the only router that should send PIM Joins on behalf of clients on the Gi2.100 LAN. The duplicate traffic is no longer seen.

<div align="left"><figure><img src="https://3072390383-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FkUz2C3GqnZcWhoVL6jfk%2Fuploads%2F5IwLeEDTGIGDAIfUT6qi%2Fimage.png?alt=media&amp;token=235d80c1-6d02-4f11-a4c0-27c23c0e8274" alt=""><figcaption></figcaption></figure></div>

Note that this feature (**ip pim passive**) does not appear to be available on IOS-XR. This is likely because on IOS-XE, this runs the interface in sparse-dense mode, and sparse-dense mode isn’t supported on IOS-XR. Instead you can use a neighbor filter on IOS-XR and deny **any any**, but the PIM Assert process appears to still work in this case, so you wouldn’t see duplicate traffic on the LAN.
