logoalt Hacker News

dijittoday at 6:13 PM1 replyview on HN

Just here to reinforce your point.

The last leap-second I encountered (also the 2014 one) crashed my MySQL databases.

you wouldn't assume that it depends on time like that, because honestly why would it? "surely it's fine, NTP corrects drift of a second fairly frequently"- but a leap second is not a drift, it's something quite insane unless your primitives are solid. Nobody would test for this.


Replies

imglorptoday at 8:26 PM

Yes I would assume that the NTP daemon would handle a leap second arrival with guarantees of (1) gradual application over a longer period and (2) never moving the clock backwards, only slowing it a little.

I wonder if all NTP implementations don't follow those guarantees?

Oh and another app that hates clock jumps used to be sshd; it would just bail out and drop all connections. We found that out while chasing ANOTHER bug in SunOS on a T4: they didn't have it mutexed right so it possible to read its RTC register while it was in the middle of getting updated so the client would read a garbage time. We chased NTP for a week before realizing it was the kernel.

show 1 reply