Thread: [Linuxptp-users] Two Delay_req message
PTP IEEE 1588 stack for Linux
Brought to you by:
rcochran
From: - - <art...@gm...> - 2022-09-04 19:25:41
|
Hi Please advise how linuxptp works As I understand it from the documents I found, ptp works in the following way: Announce message Sync message Follow_up message Delay_req message Delay_resp message I understand that depending on the mod ptp can work without Follow_up. But sometimes I see the following things in tcpdump: Announce message Sync message Follow_up message Delay_req message Delay_resp message Delay_req message Delay_resp message Announce message Sync message Follow_up message Delay_req message Delay_resp message or Sync message Follow_up message Delay_req message Delay_req message Delay_resp message Delay_resp message So it looks like the master sends two Delay_req. I just need to understand if it's expected ptp work or it's a bug with the driver Best regards, Vyacheslav |
From: Miroslav L. <mli...@re...> - 2022-09-05 07:32:02
|
On Mon, Sep 05, 2022 at 12:25:20AM +0500, - - wrote: > I understand that depending on the mod ptp can work without Follow_up. Follow up is needed when the hardware cannot modify the timestamp in the sync message as it is being transmitted. This seems to be rare in computer HW. > So it looks like the master sends two Delay_req. > I just need to understand if it's expected ptp work or it's a bug with the > driver The interval between delay requests is random to avoid requests from different clients to arrive at the same time at the server. If the server is slower in responding, or the interval happens to be very close to 0, you could see two delay requests before first response. -- Miroslav Lichvar |
From: Dennis H. (dehagart) <deh...@ci...> - 2022-09-05 08:27:35
|
Hi, The slave sends the delay_Req to the master. The slave should transmit a delay_Req at a regular interval depending on the configuration or negotiation of the inter-message interval (the desired time between each message). In IEEE 1588-2019, the requirement for regular messages is outlined in “9.5.11.2 Timing requirements” – generally they should be transmitted at an interval above 90% of the desired inter-message interval. So, for example, if you configured 32 packets per second (1/32 second interval), you would expect an average inter-message time value around that configured value (roughly +/- 10%) So, if the two delay_Req and sent are on top of each other, then the slave is misbehaving, although the master should tolerate short excursions from the inter-message interval. In response to the delay_Req, the delay_Resp from the master “should be transmitted as soon as possible after the receipt of the associated Delay_Req message” (9.5.12 Transmission of a Delay_Resp message) If it’s taking its time, then the master is probably not being strictly adherent to the standards (seeing the timestamps on the tcpdump would help determine who is at fault). But there is some flexibility in the implementation whereby a significant number of outliers should be tolerated (30% in some cases), so the odd delay in messages should not be a big deal. Regards Dennis From: art...@gm... <art...@gm...> Sent: Sunday, September 4, 2022 21:25 To: lin...@li... Subject: [Linuxptp-users] Two Delay_req message Hi Please advise how linuxptp works As I understand it from the documents I found, ptp works in the following way: Announce message Sync message Follow_up message Delay_req message Delay_resp message I understand that depending on the mod ptp can work without Follow_up. But sometimes I see the following things in tcpdump: Announce message Sync message Follow_up message Delay_req message Delay_resp message Delay_req message Delay_resp message Announce message Sync message Follow_up message Delay_req message Delay_resp message or Sync message Follow_up message Delay_req message Delay_req message Delay_resp message Delay_resp message So it looks like the master sends two Delay_req. I just need to understand if it's expected ptp work or it's a bug with the driver Best regards, Vyacheslav |
From: Miroslav L. <mli...@re...> - 2022-09-05 09:09:50
|
On Mon, Sep 05, 2022 at 08:11:48AM +0000, Dennis Hagarty (dehagart) via Linuxptp-users wrote: > In IEEE 1588-2019, the requirement for regular messages is outlined in “9.5.11.2 Timing requirements” – generally they should be transmitted at an interval above 90% of the desired inter-message interval. > So, for example, if you configured 32 packets per second (1/32 second interval), you would expect an average inter-message time value around that configured value (roughly +/- 10%) > So, if the two delay_Req and sent are on top of each other, then the slave is misbehaving, although the master should tolerate short excursions from the inter-message interval. No, the client is fine. The minimum interval between two delay requests is 0. Quoting from 9.5.11.2: the random distribution shall be a uniform random distribution with a minimum value of 0 and a maximum value of {2^logMinDelayReqInterval+1} seconds -- Miroslav Lichvar |
From: Dennis H. (dehagart) <deh...@ci...> - 2022-09-05 12:09:14
|
Hi, Then probably the first question would be - is this unicast or multicast? Or using a particular profile? Regards Dennis -----Original Message----- From: Miroslav Lichvar <mli...@re...> Sent: Monday, September 5, 2022 11:10 To: Dennis Hagarty (dehagart) <deh...@ci...> Cc: art...@gm...; lin...@li... Subject: Re: [Linuxptp-users] Two Delay_req message On Mon, Sep 05, 2022 at 08:11:48AM +0000, Dennis Hagarty (dehagart) via Linuxptp-users wrote: > In IEEE 1588-2019, the requirement for regular messages is outlined in “9.5.11.2 Timing requirements” – generally they should be transmitted at an interval above 90% of the desired inter-message interval. > So, for example, if you configured 32 packets per second (1/32 second interval), you would expect an average inter-message time value around that configured value (roughly +/- 10%) > So, if the two delay_Req and sent are on top of each other, then the slave is misbehaving, although the master should tolerate short excursions from the inter-message interval. No, the client is fine. The minimum interval between two delay requests is 0. Quoting from 9.5.11.2: the random distribution shall be a uniform random distribution with a minimum value of 0 and a maximum value of {2^logMinDelayReqInterval+1} seconds -- Miroslav Lichvar |
From: - - <art...@gm...> - 2022-09-05 11:32:15
|
Thank you for your help. But I'm not quite clear: Sync message Follow_up message Delay_req message Delay_resp message Delay_req message Delay_resp message So it looks like there is a surplus here Delay_req message Delay_resp message Is this normal? Best regards, Vyacheslav пн, 5 сент. 2022 г. в 15:09, Miroslav Lichvar <mli...@re...>: > On Mon, Sep 05, 2022 at 08:11:48AM +0000, Dennis Hagarty (dehagart) via > Linuxptp-users wrote: > > In IEEE 1588-2019, the requirement for regular messages is outlined in > “9.5.11.2 Timing requirements” – generally they should be transmitted at an > interval above 90% of the desired inter-message interval. > > So, for example, if you configured 32 packets per second (1/32 second > interval), you would expect an average inter-message time value around that > configured value (roughly +/- 10%) > > So, if the two delay_Req and sent are on top of each other, then the > slave is misbehaving, although the master should tolerate short excursions > from the inter-message interval. > > No, the client is fine. The minimum interval between two delay > requests is 0. Quoting from 9.5.11.2: > > the random distribution shall be a uniform random distribution > with a > minimum value of 0 and a maximum value of > {2^logMinDelayReqInterval+1} > seconds > > -- > Miroslav Lichvar > > |
From: Miroslav L. <mli...@re...> - 2022-09-05 12:16:11
|
On Mon, Sep 05, 2022 at 05:31:55PM +0600, - - wrote: > Thank you for your help. > > But I'm not quite clear: > Sync message > Follow_up message > Delay_req message > Delay_resp message > Delay_req message > Delay_resp message > > So it looks like there is a surplus here > Delay_req message > Delay_resp message > > Is this normal? Yes, it is normal. The timing of delay requests is independent from sync messages and it is random. You can have 0, 1, 2, or more delay request and responses between two sync messages. -- Miroslav Lichvar |