> -----Original Message-----
> From: Jakub Raczyński <j.raczyn...@elpromaelectronics.com>
> Sent: Tuesday, February 22, 2022 8:10 AM
> To: Miroslav Lichvar <mlich...@redhat.com>
> Cc: linuxptp-users@lists.sourceforge.net
> Subject: Re: [Linuxptp-users] Multicast group (re)join issue vs IGMP snooping
> 
> > 21.02.2022 09:43 Miroslav Lichvar <mlich...@redhat.com> wrote:
> > It might help if you could post some logs that show the problem with
> > corresponding packet capture.
> 
> Sure thing.
> So here is a setup - device 10.10.2.236 is PTP Master, 10.10.2.237 is PTP 
> Slave,
> 10.10.4.1 is switch with IGMP snooping. There is also simple switch used in 
> use,
> connected to 10.10.4.1 switch and PC with wireshark.
> 
> Case 1:
> Both PTP Master and Slave are connected to simple switch. PTP Slave is started
> first, then later PTP Master.
> As intended, PTP Slave keeps sending IGMP join request until it connects to 
> any
> PTP Master.
> 
> Case 2:
> PTP Master and PTP Slave are running, PTP Master is connected to simple 
> switch,
> PTP Slave is behind turned off IGMP switch. PTP Master packets are visible in
> wireshark. After that switch with IGMP is started.
> UNINTENDED - ptp4l Master nor Slave will ever send IGMP join so multicast is
> blocked.
> 

All the evidence I found points to Linux re-sending IGMP packets between 0 to 
10 seconds since Linux 2.6

If that's not happening in your system, you'd best be debugging the kernel, not 
ptp4l.

> I believe this whole behavior is combination of ethernet driver and kernel.
> But I want to ask, should ptp4l monitor this rather than send only IGMP join
> packets at the start? Because I can see devices blatantly ignoring 'Membership
> queries' under specific circumstances (showed in the logs). So should ptp4l 
> really
> depend on kernel or other drivers to work in such cases?

ptp4l has to depend on the kernel. There is no control other than socket option 
to request to join and leave multicast groups. Its not up to the application to 
control re-send behavior.

Again, as far as I can tell, Linux has properly re-sent multicast IGMP packets 
periodically since 2.6 kernels. In addition, the time to resend is configurable 
since somewhere in the 3.x kernels.

At the very least its clear the Linux kernel *intends* to resend these 
periodically and if its not then you need to debug at the kernel level to 
figure out why.

Best of luck :)

-Jake 

_______________________________________________
Linuxptp-users mailing list
Linuxptp-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linuxptp-users

Reply via email to