Concepts / Addresses and clocks

Addresses and clocks

PTP

Also called precision time protocol, IEEE 1588, ptp4l, linuxptp, grandmaster, boundary clock, hardware timestamping, software timestamping

Sub-microsecond time sync on a LAN, timestamping packets as they cross the wire rather than when software reads them.

Four messages, stamped as they cross the wire
Four messages, stamped as they cross the wire

PTP uses the same four-timestamp sum as NTP. Its precision comes from where the stamp is taken: in the network card, not in software after the packet has waited in a queue.

PTP (Precision Time Protocol, IEEE 1588) syncs clocks on a LAN far more tightly than NTP. A grandmaster sends a Sync, then its exact send time in a Follow_Up; the slave sends a Delay_Req and learns its arrival time from a Delay_Resp. Those four stamps give the slave its offset and the path delay. Stamping each message in the NIC hardware gives nanoseconds; software timestamping gives only microseconds.

Read next

Learn it on real machines.

Every lab is a small network of real Linux machines in your browser. Sign in with Google or email to start.

Start learning