Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Mark Twain has a quote for everything!

  An ancient adage warns, "Never go to sea with two chronometers; take one or three." — Fred Brooks


And for NTP, take 5 because two could tell the same lie ;)


And how do you use them--only use the median value?


2 vs 2 you don't know who to trust, but if you have 3 vs 2 you know who you ~can trust (more), that's why 5 and not 4.

But if you have a atomic clock don't trust those 5 ntp's at all. Maybe buy a 2nd clock or even better 5 of them ;)


I would assume that all 5 give slightly differing estimates of the current time [a, b, c, d, e] with duplicates being rare and not treated specially than values that are close. You can either choose 'c' to ignore the outliers, or average [b, c, d] or some weighted average of them or more. Maybe the weighted average of the middle 3 might be more stable than the single median.



> The best master clock (BMC) algorithm performs a distributed selection of the best candidate clock based on the following clock properties: (IEEE 1588-2008 uses a hierarchical selection algorithm based on the following properties, in the indicated order:[8]:Figure 27)

> Priority 1 – the user can assign a specific static-designed priority to each clock, preemptively defining a priority among them. Smaller numeric values indicate higher priority.

> Class – each clock is a member of a given class, each class getting its own priority. Accuracy – precision between clock and UTC, in nanoseconds (ns)

> Variance – variability of the clock

> Priority 2 – final-defined priority, defining backup order in case the other criteria were not sufficient. Smaller numeric values indicate higher priority.

> Unique identifier – MAC address-based selection is used as a tiebreaker when all other properties are equal.

Only useful if you trust the data: Class, Accuracy, and Variance (which seems to be a self-measured estimate).




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: