Skip to main content

Leap seconds cause chaos for computers — so Meta wants to get rid of them

Leap seconds cause chaos for computers — so Meta wants to get rid of them

/

Facebook’s parent company wants new ways to calculate time

Share this story

Perception Las Vegas And “Leonardo: The Universal Man” Media Preview
Photo by Gabe Ginsberg/Getty Images

Since 1972 there have been 27 leap seconds: additional seconds added to the world’s common clock — Coordinated Universal Time or UTC — to account for changes in the Earth’s rate of rotation. Historically, our concept of time is defined as a fraction of the length of the solar day, but as the Earth’s rate of spin is somewhat irregular (slowing and speeding based on various factors) it means solar time and universal time tend to drift apart. So, in order to compensate, we add leap seconds. And this really confuses computers.

I mean, just imagine you’re a computer. You have a very clear sense of time. You know that there are 24 hours in a day, 60 minutes in an hour, and 60 seconds in a minute: all neat and tidy. Then, on some random day as you await the coming dawn, you watch with horror as your internal clock ticks over from 23:59:59 to the previously-undreamt-of time of 23:59:60. Quite naturally you freak out. Maybe you crash a little, just to calm your nerves. As a result, you take down some of the biggest websites in the world. Everyone gets mad at you.

“Almost every time we have a leap second, we find something”

This is not a joke scenario. When a leap second was added in 2012, it caused substantial outages for sites like Foursquare, Reddit, LinkedIn, and Yelp. By 2015, when the next leap second was due, engineers had mostly learned their lessons, but there were still some glitches. Ditto 2016. As Linux creator Linus Torvalds put it:  ”Almost every time we have a leap second, we find something. It’s really annoying, because it’s a classic case of code that is basically never run, and thus not tested by users under their normal conditions.”

This is why social media conglomerate Meta wants to get rid of the leap second. In a blog post published yesterday, the company’s engineering team outlined their argument against adding leap seconds, saying it’s an adjustment that “mainly benefits scientists and astronomers” (as it allows them to make observations of celestial bodies using UTC). This benefit is less important than it once was, says Meta, and outweighed by the confusion leap seconds cause in the tech world.

“Introducing new leap seconds is a risky practice that does more harm than good, and we believe it is time to introduce new technologies to replace it,” says the company.

According to a report from CNET, Meta is not alone in this, and this campaign has attracted support from other tech giants like Google, Microsoft, and Amazon, as well as heavy-hitters in the international measurement community, like the US National Institute of Standards and Technology (NIST) and France’s Bureau International de Poids et Mesures (BIPM).

But without leap seconds, what happens to coordinated universal time? Do we just let it fall out of sync with solar time? Well, there are options, as Meta points out. One alternative to the leap second is the smear second, which means slowing down digital clocks over a longer period to account for the extra time to be added — effectively smearing the necessary leap second across a period of hours in a single day.

However, there are problems with this method too. There are lots of ways you can calculate smear seconds (particularly regarding the period you use to distribute the extra “time”). And, as there’s no single, centralized method of tracking time across the world’s many digital systems, this means alternate methods could also create confusion and outages.

At any rate, Meta isn’t suggesting any single solution to the problem of the leap second. It’s only saying that there needs to be one. And, indeed, this is a problem that many other organizations are examining right now. The next big milestone will be a report on the matter commissioned by the UN’s International Telecommunication Union or ITU in 2015. That’s due out in 2023. Because you really can’t rush this sort of thing.