Live data from Hacker News

Ask HN: Are systems ready for the first negative leap second?

news.ycombinator.com

11–20 of 100 posts

Re: Ask HN: Are systems ready for the first negative leap second?

#11

If we have positive and negative leap seconds, why are we doing anything at all? 1 second forward, just to go 1 second back 10 years later…

I don't think we can predict ahead of time whether we'll need a leap second or not

If the question is "why bother syncing time to Earth's orbit around the sun at all", I don't have a good answer for that except at this point, it's tradition.

Re: Ask HN: Are systems ready for the first negative leap second?

#12
post #3

Systems are absolutely not ready. Leap seconds are a bad idea and negative leap seconds are worse. Just don't do it and let the drift cancel out.

negative leap seconds aren't too bad. jumping forward a second won't lead to a time loop like jumping back did on several systems (some twice!)

Re: Ask HN: Are systems ready for the first negative leap second?

#13
post #10
post #4

Google's proposal is a smear. [1] Most time servers do not use smear. No idea what behavior it may introduce in places where sub-second time is important. Curious if all these bugs [2] were fixed specifically to deal with going backwards . [1] - https://developers.google.com/time/smear [2] - https://rivassec.com/leap-second-chaos-2012.html

The brilliant thing about the smear is that it distributes the new second across each second of the day, so that each second differed by 1/86400 seconds, well within the margin of error for NTP. As far as the computers were concerned, nothing was different.

The less brilliant thing about the smear is that if your ntpd syncs from smeared and unsmeared servers, the results aren't great.

It would have been better if they would have kept the time on the wire accurate or added mandatory protocol stuff to avoid confusing things for ntpds configured to different leap second handling.

Re: Ask HN: Are systems ready for the first negative leap second?

#14
I wonder how many systems actually care? I presume the core NTP servers handle this well, and most systems just feed off of that?

GPS satellites probably handle it well too, but maybe some consumer or even industrial GPS receivers don't? Maybe some trading systems? I don't think crypto systems care too much.

Re: Ask HN: Are systems ready for the first negative leap second?

#15
post #14

I wonder how many systems actually care? I presume the core NTP servers handle this well, and most systems just feed off of that? GPS satellites probably handle it well too, but maybe some consumer or even industrial GPS receivers don't? Maybe some trading systems? I don't think crypto systems care too much.

traditional markets are closed when time changes happen

Re: Ask HN: Are systems ready for the first negative leap second?

#16
post #13
post #10

Earlier quoted context omitted.

The brilliant thing about the smear is that it distributes the new second across each second of the day, so that each second differed by 1/86400 seconds, well within the margin of error for NTP. As far as the computers were concerned, nothing was different.

The less brilliant thing about the smear is that if your ntpd syncs from smeared and unsmeared servers, the results aren't great. It would have been better if they would have kept the time on the wire accurate or added mandatory protocol stuff to avoid confusing things for ntpds configured to different leap second handling.

if you need below 1 millisecond time accuracy, probably you know what you are doing and you wont mix NTP servers (and I think you need PTP for that)

Re: Ask HN: Are systems ready for the first negative leap second?

#17

If we have positive and negative leap seconds, why are we doing anything at all? 1 second forward, just to go 1 second back 10 years later…

The Earth's rotation is slowing down in the long term, hence the need to adjust. In the short term (where 10 years is "short") it can speed up or slow down, but long-term it is slowing down.

Note that this is not an argument for leap seconds - just my understanding of their rationale.

Re: Ask HN: Are systems ready for the first negative leap second?

#18
post #11

If we have positive and negative leap seconds, why are we doing anything at all? 1 second forward, just to go 1 second back 10 years later…

I don't think we can predict ahead of time whether we'll need a leap second or not If the question is "why bother syncing time to Earth's orbit around the sun at all", I don't have a good answer for that except at this point, it's tradition.

We can set some rasterization floor, such as like 3 minutes or something, and live with that.

Correcting for a 3-minute offset every few millenia seems easier than trying to understand all this minutia about wobble and aquifer management and whatever else goes into a leap second.

Re: Ask HN: Are systems ready for the first negative leap second?

#19
post #14

I wonder how many systems actually care? I presume the core NTP servers handle this well, and most systems just feed off of that? GPS satellites probably handle it well too, but maybe some consumer or even industrial GPS receivers don't? Maybe some trading systems? I don't think crypto systems care too much.

The problem frequently crops up in order-deterministic systems that use time and haven't accounted for the edge case of all the vagaries related to time-keeping of this being only one.

I've worked on some extremely sensitive systems that had thousands of lines of C dedicated to handling skewing a time gap across an hour-per-second when necessary. I know that code assumed only "missing" time (jump-forwards)... Even knowing what I know as a developer now, if I was re-implementing that system from scratch and didn't have this top-of-mind, I'd bet I would miss "overlapping" or "duplicate" time entirely.

Maybe that is more of a me problem than others, but I'd bet there are some safety critical systems out there where the responsible engineers, QA, and specs all missed this as well.

Re: Ask HN: Are systems ready for the first negative leap second?

#20
post #14

I wonder how many systems actually care? I presume the core NTP servers handle this well, and most systems just feed off of that? GPS satellites probably handle it well too, but maybe some consumer or even industrial GPS receivers don't? Maybe some trading systems? I don't think crypto systems care too much.

I wonder if there's things that run 24/7 and need to be monitored.. e.g. if you have oil flowing through some pipeline at 100 liters/second, one particular minute will have 6100 liters, and someone will want to get paid for that 100 extra liters.

But the meter/reporting tool would say "Well, we measure every second, and the meter reported a constant rate of 100 liter/second, and as we know we have 60 seconds in a minute, so we got 6000 liters!".

Or a database for "measurements every second for this minute" that has 60 fields, and don't have a field for the 61st measurement.

Post reply on HN