Five Minute Facts About Packet Timing
By Doug Arnold.
I get asked a lot of questions from customers about network timing technology. Some of them are challenging to answer. However, one that I get all the time that is easy to answer is this: “Do I want NTP or PTP?” It all comes down to accuracy. I simply ask them what time transfer accuracy do they need. Guilty, I’m answering a question with a question. Let me put it this way: Is the accuracy you need measured in microseconds or nanoseconds? If the answer is yes, you want PTP (IEEE 1588). If the answer is in milliseconds or seconds, then you want NTP.
I wrote earlier about why PTP is so accurate. And the answer is due to the fact that hardware timestamping is commonly implemented in PTP technology, but not in NTP. Hardware timestamping is allowed in the client and server devices which are running NTP, but not many devices out there implement this. Furthermore the biggest source of error in network timing is often due to the variations in queuing time in switches and routers. NTP does not have a solution for this, PTP does. The solution is to use special switches and routers called transparent clocks or boundary clocks. For a description of these clever devices see my earlier post: What Are All Of These IEEE 1588 Clock Types?. There is even ongoing standards work to use technology developed at CERN. (that’s right the people who discovered the Higgs Boson and invented the world wide web) to extend PTP to picoseconds.
If you’re thinking, I don’t need to coordinate measurements of high energy particles, I just want to set the clocks on my servers and routers to within a few ms, then you want NTP. But if PTP is more accurate why not use it for everything? Good question. The answer is:
- ease of implementation
NTP is easier to implement because free NTP clients are already included with just about any computer, server or router you buy. Just point each client to which address to ask for time and its good to go. You can also easily download and install free software that contains a list of know NTP servers and their addresses. Clink this link if you don’t believe me.
NTP is cheaper, because the clients are free, and no special switches are required. Most system integrators buy dedicated servers, since that saves them the trouble of integrating a GPS receiver (to get standard time) with an NTP server. But each server can keep thousands of clients happy and on time.
Both PTP and NTP have feature for fault tolerance, depicted in the diagrams below.
In the case of PTP a slave synchronizes to a master clock, which other masters listen in, so that they can take over if the active master goes away for any reason. That’s good, but NTP does one better. The client gets time from all of the servers and ignore one which seems to be too far off in time compared to the other servers.
The bottom line is that NTP has been around several decades, and has become cheap easy and robust. The good news is that many of these properties are gradually being added to the world of IEEE 1588 so soon you will be able to have the ease and robustness of NTP with the accuracy of the Hadron Collider.
- ptp vs ntp
- ntp vs ptp
- ptp ntp
- NTP PTP
- https://blog meinbergglobal com/2013/11/22/ntp-vs-ptp-network-timing-smackdown/
- ptp time server
- NTP accuracy
- ptp vs ntp comparison
- PTP smackdown