5 ms·
Is anyone using PTP and its requisite accuracy in production? If so, what's your use-case? Our central NTP servers are getting, per "ntpq -c kerninfo", sub-mil
by throw0101a 5y ago
Is anyone using PTP and its requisite accuracy in production? If so, what's your use-case?
Our central NTP servers are getting, per "ntpq -c kerninfo", sub-millisecond error:
$ ntpq -c kerninfo
associd=0 status=0615 leap_none, sync_ntp, 1 event, clock_sync,
pll offset: -0.257641
pll frequency: 7.5157
maximum error: 0.165426
estimated error: 0.000422
[…]
That's talking to a couple of Stratum 1, and a bunch of S2, servers.
- traceroute66 5y agoHave you tried Chrony instead of Ntpd ? System time : 0.000084656 seconds slow of NTP time Last offset : -0.000029673 seconds RMS offset : 0.000046217 seconds Frequency : 17.760 ppm slow Residual freq : -0.001 ppm Skew : 0.012 ppm Root delay : 0.001419884 seconds Root dispersion : 0.000967303 seconds
- hacker_newz 5y agoAny organization that requires nanosecond precision uses PTP. In my experience this usually includes financial exchanges that want to measure latency in trade routing.
- magicalhippo 5y agoFWIW I posted some stats from my Raspberry Pi with a GPS module here[1] along with a VM on the same LAN. The tl/dr of the Pi: $ chronyc sourcestats 210 Number of sources = 7 Name/IP Address NP NR Span Frequency Freq Skew Offset Std Dev ============================================================================== PPS1 8 6 112 -0.018 0.020 -105ns 336ns The other computers on the LAN have typically ~30uS std dev. [1]: https://news.ycombinator.com/item?id=28372861 https://news.ycombinator.com/item?id=28372861
- bestouff 5y agoPTP and NTP don't have the same use: - PTP is for sub-nanosecond local networks, with possibly hundreds of packets per second, local (in network card) clocks, hardware timestamping everywhere - NTP if for long distance sync, with sophisticated statistical smoothing from several upstream servers
- jhellan 5y agoBasically, PTP assumes that network delays are deterministic. If that's true, it is very precise. If not, PTP is the wrong tool. NTP assumes that network delays are stochastic, and uses sophisticated algorithms to account for this. PTP has much simpler algorithms, which can be implemented in electronics, where internal timings can be characterized. NTP is more complex, and tends to run on a general purpose computer. This adds internal OS timings to the uncertainty.
- michaelt 5y agoThe most well known applications include: * High-speed stock trading, where regulations often require precise timestamping. * Cell phone networks, where adjacent towers have to hold their frequencies precisely, and synchronise their transmit and receive time windows to avoid interference. * Certain types of distributed database [1] At a broader level, guarantees/specifications about NTP accuracy are hard to find. If you google 'NTP accuracy' you'll find a very wide range of claims, from sub-millisecond to >1 second [2] Indeed, a lot of the NTP userbase has timing requirements so lax they can 'smear' a leapsecond [3] over the course of 24 hours, tolerating a sustained error of hundreds of milliseconds. They've got good reasons for doing it - but it goes to show big errors are possible even under normal, correct operation. Therefore, if you have an application that needs single-millisecond-level accuracy, you won't find an NTP product specification saying it's what you want. [1] https://en.wikipedia.org/wiki/Spanner_(database)#Architecture https://en.wikipedia.org/wiki/Spanner_(database)#Architectur... [2] http://www.ntp.org/ntpfaq/NTP-s-algo.htm#Q-ACCURATE-CLOCK http://www.ntp.org/ntpfaq/NTP-s-algo.htm#Q-ACCURATE-CLOCK [3] https://developers.google.com/time/smear https://developers.google.com/time/smear
- insaneirish 5y ago> If so, what's your use-case? Certain regulations in the financial industry lead you towards using it. For example, Europe's MiFID II requires some systems to time stamp with 1 µs increments and 100 µs accuracy. PTP is the most common way to sync systems that have this requirement.
- danbr 5y ago> what's your use-case? Camera triggering/time stamping of frames that requires sub-millisecond accuracy, between multiple devices.
- M2Ys4U 5y ago>Is anyone using PTP and its requisite accuracy in production? If so, what's your use-case? I've seen it used in projects for frame-accurate timing for IP video production (the use case was more TV studios than, say, Twitch streams)
- dpzmick 5y ago> If so, what's y̶o̶u̶r̶ a use-case? CERN uses PTP on steroids for physics experiments: https://white-rabbit.web.cern.ch/ https://white-rabbit.web.cern.ch/
- huntero 5y agoPTP is a great choice when you need your time-sync to leave the software domain, for instance, locking an external PLL for frequency and phase aligned clocks. PTP enabled MAC's and PHY's usually have a dedicated hardware output for a PPS (pulse-per-second) or faster clock, generated directly from the hardware PTP counters. In the video world, we get great results synchronizing software events with NTP, but whenever you jump to a physical interface (DisplayPort, HDMI, SDI, etc.), NTP-based clocks are far too jittery. I've seen some work using the PTP hardware in the MAC with the NTP protocol, a sort of hybrid approach, but don't have any first hand experience.
- OrvalWintermute 5y ago> Is anyone using PTP and its requisite accuracy in production? If so, what's your use-case? Yes; satellite ground systems, satellite communications, earth observation
- dtgriscom 5y agoAudio over IP solutions. Having all your workstations synchronized within a few samples makes it possible to greatly reduce I/O buffer size and thus latency.