Leap second
-
Day 20: The Leap Second Is No More, Huzzah!
I know yesterday’s post was a real cliffhanger. Talking about leap seconds. I hate to burst your bubble, but today there’s going to be more of that when we cover the exciting and well-documented, internationally renowned meeting in November 2022.
I’m sure everyone totally knows about the General Conference on Weights and Measures (CGPM). Well, it turns out they have an important role as the world’s final authority on the metric system since 1875, a big deal. On that 18th in November 2022, they passed Resolution 4. It did one thing:
By or before 2035, the maximum value of the difference (UT1 − UTC) will be increased.
That means: we are abolishing the leap second.
This is a big deal. The leap second has been a feature of civil time for fifty years. Getting rid of it is the biggest change to “what time is it” since UTC itself got adopted in 1972. And it took almost twenty years of “discussion” to get there.
That “battle” is what today’s post is about. What got won and what got lost is way more interesting than the resolution text.
Two tribes, two ideas of “right”
Here’s the thing nobody tells you. There are two whole tribes of people whose job it is to care about what time it is. And they want completely different things.
Team Metrologists care about precision. Stability. The boring stuff. Their crowd is physics experiments, GPS satellites, financial exchanges, telecom networks, cloud data centers. To them, time is a standard of unit and measurement, like the kilogram or the meter. A measurement standard that inserts a random extra second is not a measurement standard. You’d never tolerate a gram that occasionally weighed an extra gram.
Team Astronomers care about Earth’s rotation. We should be on team astronomers every day, all the time. Their crowd is observatories, and the very old ideas that the day should obey man. To them, civil time should mean solar time. To them, UTC was a deliberate compromise. Atomic precision for the other team, plus a periodic correction so “noon” stayed put near the sun. Take away the correction and you’ve broken a contract that Noon is always in the middle of the day and midnight is always solar midnight. The fear is that the sun might rise at midnight at some point in the future.
Both are defensible? You can imagine serious people talking about serious things for decades at a time.
Well, guess what, the metrologists won, for now.
What actually moved the needle
The first real push to abolish the leap second came at the ITU-R (the radio-spectrum arm of the International Telecommunication Union) in 2004. The US, Japan, France, and Italy were the early supporters. The UK, China, and Russia opposed. The vote was delayed. And then delayed again. And then delayed again. Through 2012, 2015, 2019, the ITU-R kept punting because nobody could agree.
What actually changed the politics were the outages.
The 2012 Linux kernel meltdown that took Reddit, LinkedIn, and Qantas offline was the first global-scale “oh no this is real” moment. Then 2015 was quiet (smearing was working). Then 2016/2017 was Cloudflare. Then we had a long stretch with no leap seconds at all, the Earth started speeding up, and metrologists started seriously talking about the negative leap second. Nobody thought this was a good idea.
The fight stopped being “two professions disagreeing” and started being “metrologists vs a problem that might kill somebody.”
The vote got moved to the CGPM, a higher-status body than the ITU-R, sitting under the BIPM in Paris. In November 2022, in a single afternoon, the resolution passed.
The vote did not specify how leap seconds would be abolished. It just said the threshold would be increased, meaning UTC will be allowed to drift further from UT1 than the current 0.9-second limit, and that the new threshold would be decided by or before 2035.
The question that is up for discussion this year at the 28th CGPM in 2026 is: how much drift do we put up with before we have to do something about it?
Options on the table:
- One minute. UTC drifts from solar time by up to a minute, which takes roughly 100 years at current rates. Then we insert a “leap minute” once, in some coordinated worldwide event. Still sounds dangerous.
- 256 seconds. A computing-friendly number (it fits in an 8-bit field). Drift accumulates over ~400 years.
- One hour. Roughly 5,000 years out. By that point the leap is just “everybody shift one time zone for a few years until civil time re-syncs.”
- No threshold at all. Let UTC and UT1 diverge forever. Civil time eventually has nothing to do with the sun. The option astronomers hate most, and engineers find most tempting.
This is genuinely undecided. The drafting task force is still working on it. The 2026 vote will probably set the threshold, but the mechanism (how an eventual leap minute or hour actually gets inserted, how it’s announced, how software handles it) is still an open problem.
What happens when (or did they) metrologists win
The biggest immediate win is that POSIX becomes correct.
Quick recall from Day 13: Unix time is defined as “seconds since 1970-01-01 UTC,” with the deeply weird caveat that it pretends leap seconds don’t exist.
So now every day is exactly 86,400 seconds, full stop. This made Unix time a lie for decades. A lie that all of computing depends on.
By killing the leap second, the lie becomes the truth. UTC will, after 2035, actually tick uniformly.
POSIX’s definition starts being an honest description of what’s happening. Every piece of date-arithmetic code ever written that assumed
86400 * daysequals a stretch of days will be correct.It’s maybe a boring victory, if it’s just the absence of a problem. In 2035, time finally heals.
What astronomers lost
The astronomers, the people who built the leap-second system in 1972, lost a principle. A simple and very old one: noon should be when the sun is overhead. Midnight should be the middle of the night. That contract is older than civilization, and UTC was the deal that kept it intact through the atomic age.
Abolishing the leap second breaks that contract. Slowly. Over centuries. But permanently. Their fear is that eventually, not tomorrow, not in 100 years, but someday, the sun will rise at midnight.
Here’s what’s not lost. The astronomers' toolkit for actually measuring where the Earth is is excellent and getting better. They watch distant quasars with radio telescopes spread across continents and know where the Earth is to the millisecond. They’ll still know exactly when solar noon happens. They’ll just have to broadcast that signal themselves, almost certainly a UT1 service separate from UTC, instead of getting it baked into civil time.
What gets lost is the default. After 2035, civilization no longer says with “noon-is-noon” as a built-in promise. If you want it, it’s there, you just have to opt in.
So what’s the big deal?
The disagreement is just about time.
If civil time is a measurement standard: you optimize for precision and stability and you remove the ambiguity. The metrologists' answer is correct.
If civil time is a human social agreement about when noon is: you accept a little time wiggle, every now and then and who isn’t a fan of a little wiggle, in exchange for keeping noon attached to the sun. Well then, the astronomers' answer is correct.
I can see how both answers are answers, but I think they are answers to different things.
Computers and the people who use them.
For systems, all our ways of tracking time, the metrologists are correct. End of story. All the GPS satellites, financial exchanges, telecom networks, cloud data centers need a clock that just ticks; uniformity, no surprises, no funny business. This is something the 2022 vote got correct.
But what is Civil time if its' not for the people? And maybe there’s still a way for everybody to win. Keep the systems on uniform atomic time, no discontinuities, no outages, and let civil time keep its old promise. Noon stays near the sun. Even if we have to do something clever every century to make it work. A leap minute. A coordinated time-zone shift. Whatever it takes.
The systems fight are over but boy do we got some stuff to figure out with that civil time.
Tomorrow we get into the real mud, the dirt of it. What everyone hates….
The case against daylight saving time.
Sources
- Resolutions of the 27th CGPM (2022) — BIPM. The official text of Resolution 4, which increases the tolerance for UT1-UTC and effectively abolishes the leap second by 2035.
- The End of the Leap Second — Nature (2022). Comprehensive coverage of the historic vote at Versailles and the twenty-year debate between metrologists and astronomers.
- Abolishing the Leap Second — The New York Times (2022). Explains the tension between the ITU-R, the CGPM, and the risks of the negative leap second.
I’d appreciate a follow. You can subscribe with your email below. The emails go out once a week, or you can find me on Mastodon at @[email protected].
-
Day 19: Leap Seconds or When a Minute Has 61
It’s week four and this week we’re talking about the inconsistencies, the problems, the strange things about time and how we measure it. If week three was mostly about software and computer systems, week four is more about the properties or the features or the details of recording time and our time systems.
The first crack in our concept of time is the quite irregular leap second.
UTC works?
How can a minute ever have 61 seconds? If you start at zero, you got to end at 59. You start at zero and you end at 60, now you have 61 seconds. That doesn’t make sense.
If you have ever seen
:60Zin a log file, that is the leap second. That minute had sixty-one seconds in it.It exists because we are trying to do the impossible: keep two completely different definitions of the “second” in alignment, forever. There are, it turns out, two definitions.
But wait, it gets worse.
There are three time scales running in the background of our civilization right now:
- TAI, or International Atomic Time. The average of about 400 atomic clocks at standards labs around the world, all ticking off the cesium hyperfine transition we covered on Day 8. TAI is uniform. Every second is the same length as every other second. TAI does not care about the Earth.
- UT1, or Universal Time 1. Defined by the Earth’s actual rotation, measured by tracking distant quasars with radio telescopes. UT1 is wobbly. The Earth speeds up and slows down by milliseconds per day, mostly because of tidal friction (slowing it down) and core-mantle coupling (anyone’s guess on any given decade).
- UTC, or Coordinated Universal Time. The civil time on your phone. UTC is TAI minus an integer number of leap seconds, kept within 0.9 seconds of UT1.
It’s time to stop pretending like the current version of UTC isn’t a compromise. It certainly is not the best we could come up with. It’s just what everyone could agree on.
The first of its problems is the dang leap second.
So how did we get to this mess?
The IERS, the International Earth Rotation and Reference Systems Service in Paris, watches the gap between UT1 and UTC. They announce the leap second six months in advance in an actual notice called Bulletin C. They also have their own weekly and monthly newsletters called Bulletin A and Bulletin B. I don’t know what is going on at IERS and I’m sorry to anyone working there, but this leap second thing is kinda crazy.
When the leap happens, the clock reads:
23:59:58 23:59:59 23:59:60 ← this is the leap second 00:00:00That
:60is the part that breaks software. Most date/time libraries do not believe:60is a real value. POSIX, the standard governing Unix systems, explicitly defines Unix time to pretend leap seconds don’t exist.Since the system was introduced in 1972, 27 leap seconds have been inserted, although none since 2016. Also, there has never been a negative leap second. We’ve only ever needed to slow UTC down to match the Earth.
But, that may be about to change. More on that tomorrow.
Because I can’t help myself.
Here’s more stuff about… Computers.
There are three ways a computer can handle the leap second arriving.
- Step. At midnight, the clock just jumps back one second. From the OS’s perspective, time briefly moves backward. Anything assuming time is monotonic, meaning it only goes forward, sees its assumption violated and may explode.
- Stall. Hold
23:59:59for two seconds. Time doesn’t go backward, but two events get the same timestamp. Anything depending on timestamp uniqueness gets confused. - Smear. Spread the extra second over a long window (Google originally used 20 hours centered on the leap, then standardized at 24 hours) by ticking slightly slow for the whole period. No
:60ever appears. No backward step. Just a clock that runs 1.0000116× slow for a day.
Google introduced smearing in 2008. By the late 2010s most cloud providers (Amazon, Microsoft, Facebook) had adopted some flavor. It is now the de facto practice.
Before smearing, leap seconds were MORE dangerous.
A second is a second not two
A leap second is like when Pluto was a Planet. It has to be a singular definition. A known amount. A standard. Software written at some of the most capable engineering organizations still took down important infrastructure, internet infrastructure. Clearly it should not be this hard to define a unit of time.
But anyways, onto the next post.
Tomorrow will cover the historic 2022 vote to abolish the leap second, the fight that produced it, and what we all agreed to.
Sources
- International Earth Rotation and Reference Systems Service (IERS) — The body responsible for monitoring Earth’s rotation and issuing Bulletin C to announce leap seconds.
- A global timekeeping problem postponed by global warming — Nature (2024). The Duncan Agnew paper detailing how melting polar ice has counteracted the Earth’s acceleration, delaying the unprecedented “negative leap second” until roughly 2029.
- POSIX.1-2017 Base Definitions: Seconds Since the Epoch — The Open Group. The formal specification demonstrating that Unix time legally ignores leap seconds.
- Time, Technology and Leaping Seconds — Google’s original 2011 blog post introducing the concept of the “leap smear.”
- The Leap Second Glitch Explained — Wired. Detailed breakdown of the 2012 Linux
hrtimerbug that took down Reddit and Qantas. - How and why the leap second affected Cloudflare DNS — Cloudflare’s excellent, candid post-mortem of their 2017 New Year’s RRDNS outage.
I’d appreciate a follow. You can subscribe with your email below. The emails go out once a week, or you can find me on Mastodon at @[email protected].
Programming Infrastructure Time 30daysoftime Leap-second UTC