troglobit / pimd

PIM-SM/SSM multicast routing for UNIX and Linux
http://troglobit.com/projects/pimd/
BSD 3-Clause "New" or "Revised" License
194 stars 86 forks source link

Route Multicast without IGMP join #118

Closed ahdzesq closed 6 years ago

ahdzesq commented 6 years ago

Hello toglobit

I want to know if there is any way to ask Neighbors to send the multicast groups that are in the pimd.conf file without send the IGMP to join request to the pimd from another interface?

Regards

troglobit commented 6 years ago

I'm not really sure I understand what you mean, what multicast groups in pimd.conf are you referring to? Also, by Neighbors, do you mean PIM Neighbors?

Could you provide an example, a drawing of your set up, or your pimd.conf?

As a background for further discussion I'm providing a quick recap of how it all works:

  1. Multicast is always supposed to be forwarded to the IGMP querier on the LAN
  2. On Layer-3 an IPv4 multicast router usually runs a dynamic protocol like DVMRP (mrouted) or PIM
  3. On Layer-2 the router is usually configured to also be IGMP querier. This is what tells all end devices and switches (that may employ IGMP snooping) that all multicast should be forwarded in the direction of the IGMP query
  4. When these LAN connected end devices hear the IGMP Query, periodically sent by the router, they can respond with an IGMP Join (called IGMP membership report in IGMP v3) to signal they want a particular group, or set of multicast groups, to be forwarded to them

Hence, multicast on the LAN is always forwarded to the IGMP querier (the PIM router), this is usually handled transparently by IGMP-aware switches (called IGMP snooping). This makes the IGMP querier (the PIM router) a sort of focal point for multicast on the LAN.

The root cause in your case may be that multicast isn't properly forwarded to your PIM router. For that there is unfortunately no cure from the perspective of pimd. The LAN must be properly set up to either understand that receiving an IGMP query means "forward multicast in that general direction", or configured to forward all multicast towards the router. In the latter case there is usually a multicast router port setting in the firmware of managed switches on the LAN.

ahdzesq commented 6 years ago

Hello Troglobit, Thanks for your answer

Sorry if my question is not clear at all

the groups that I'm referring is the rp_addres line something like this: "rp_address 205.209.215.254 224.0.31.1 masklen 32 priority 1" That I want to say is: there is any way to request the multicast data to the PIM neighbor without the igmp query from the LAN?

Maybe this is a confusing question, but this is because I'm working on layer 1 network, I don't know if you know something about this, but this is for market data distribution that it comes in multicast, so I need to distribute this market data via layer 1 without that igmp query from the LAN

This is my pimd.conf file

igmp-query-interval 12 igmp-querier-timeout 42 spt-threshold packets 0 interval 100

phyint enp0s31f6 disable phyint enp1s0d7 disable phyint enp1s0d6 disable phyint enp1s0d5 disable phyint enp1s0d4 disable phyint enp1s0d3 disable phyint enp1s0d2 disable phyint lo disable

phyint enp1s0 enable dr-priority 101 distance 1 metric 1

rp_address 205.209.215.254 224.0.31.1 masklen 32 priority 1 rp_address 205.209.215.254 224.0.31.43 masklen 32 priority 1 rp_address 205.209.215.254 224.0.31.22 masklen 32 priority 1 rp_address 205.209.215.254 233.72.75.1 masklen 32 priority 1 rp_address 205.209.215.254 224.0.31.3 masklen 32 priority 1 rp_address 205.209.215.254 224.0.31.45 masklen 32 priority 1 rp_address 205.209.215.254 224.0.31.24 masklen 32 priority 1 rp_address 205.209.215.254 233.72.75.66 masklen 32 priority 1

Thanks, Regards.

troglobit commented 6 years ago

So, you want to be able to flood all groups received on inbound interfaces of the Rendez-Vous Point to any other interface on the same router, without receiving any IGMP Join/Membership report on those latter interfaces?

That is not how it's supposed to work, and there is no mechanism available in pimd for this. I'd recommend having an end device connected on those interfaces do an IGMP join instead.

ahdzesq commented 6 years ago

Thanks for your answer I'll be working this way

Another question, did you know why I can't get data passing from one interface to the LAN? I see Number of groups 2 but Number of mirrors 0 this is what I see in "pimd -r"

Virtual Interface Table ======================================================
Vif  Local Address    Subnet              Thresh  Flags      Neighbors
---  ---------------  ------------------  ------  ---------  -----------------
  0  172.10.10.21     172.10.10/24             1  DISABLED
  1  10.248.16.161    10.248.16.160/31         1  DR PIM     10.248.16.160
  2  10.248.58.161    10.248.58.160/27         1  DR NO-NBR
  3  10.248.16.161    register_vif0            1

 Vif  SSM Group        Sources

Multicast Routing Table ======================================================
----------------------------------- (*,G) ------------------------------------
Source           Group            RP Address       Flags
---------------  ---------------  ---------------  ---------------------------
INADDR_ANY       224.0.28.1       69.50.112.254    WC RP
Joined   oifs: ....
Pruned   oifs: ....
Leaves   oifs: ..l.
Asserted oifs: ....
Outgoing oifs: ..o.
Incoming     : .I..

TIMERS:  Entry    JP    RS  Assert VIFS:  0  1  2  3
             0    35     0       0        0  0  0  0
----------------------------------- (S,G) ------------------------------------
----------------------------------- (*,G) ------------------------------------
Source           Group            RP Address       Flags
---------------  ---------------  ---------------  ---------------------------
INADDR_ANY       224.0.28.128     69.50.112.254    WC RP
Joined   oifs: ....
Pruned   oifs: ....
Leaves   oifs: ..l.
Asserted oifs: ....
Outgoing oifs: ..o.
Incoming     : .I..

TIMERS:  Entry    JP    RS  Assert VIFS:  0  1  2  3
             0    20     0       0        0  0  0  0
----------------------------------- (S,G) ------------------------------------
--------------------------------- (*,*,G) ------------------------------------
Number of Groups: 2
Number of Cache MIRRORs: 0
------------------------------------------------------------------------------
troglobit commented 6 years ago

Well, what is your LAN, is it 172.10.10/24? It seems you've disabled that interface. Try enabling it and run tcpdump on that interface. If there's a lot of traffic you can tell tcpdump to filter out only igmp traffic. You can also enable IGMP debug messages in pimd to see if they are registered. See the pimd -h usage text for help.

ahdzesq commented 6 years ago

No, my LAN is 10.248.58.160/27 network I have pimd running with -d and I can see the registry of the groups but there is no passing data

troglobit commented 6 years ago

OK. Did you try tcpdump on the interface, do you see any inbound IGMP join messages for the groups you want to forward? And if you do, do you see any inbound multicast on the 10.248.16.160/31 interface?

ahdzesq commented 6 years ago

Yes I can see the IGMP request on the interface but there is nothing of data

[root@localhost test090317]# tcpdump -i enp4s0d1 igmp -vv tcpdump: listening on enp4s0d1, link-type EN10MB (Ethernet), capture size 262144 bytes 17:37:41.489487 IP (tos 0xc0, ttl 1, id 0, offset 0, flags [DF], proto IGMP (2), length 56, options (RA)) localhost.localdomain > igmp.mcast.net: igmp v3 report, 3 group record(s) [gaddr igmp.mcast.net is_ex { }] [gaddr all-routers.mcast.net is_ex { }] [gaddr pim-routers.mcast.net is_ex { }] 17:37:41.557109 IP (tos 0x0, ttl 1, id 28618, offset 0, flags [none], proto IGMP (2), length 40, options (RA)) 10.248.58.169 > igmp.mcast.net: igmp v3 report, 1 group record(s) [gaddr 224.0.28.1 is_ex { }] 17:37:45.557109 IP (tos 0x0, ttl 1, id 28619, offset 0, flags [none], proto IGMP (2), length 40, options (RA))

troglobit commented 6 years ago

Then you need to check where the multicast data for group 224.0.28.1 stops.

ahdzesq commented 6 years ago

I've solved the issue, it was the layer 1 switch that it was dropping the multicast, now I can receive the data

Thanks for your help!