CYBER MONDAY WEEK 🤑 Get 30% off your TNW for Startups or Scaleups packages when you use code CYBER30 only until December 4 →

This article was published on January 7, 2015

Adding a leap second is more dangerous for the Internet than you might expect


Adding a leap second is more dangerous for the Internet than you might expect

The International Earth Rotation and Reference Systems Service (IERS) announced today that it’s going to be adding a second to the clock on June 30, 2015. While leap seconds sound entirely harmless, it’s far more dangerous for the Internet than you might expect.

Why bother adding a second at all, then? There’s a number of reasons one can be added; everything from earthquakes changing the Earth’s rotation or simple adjustments to time to account for Earth’s naturally slowing rotation. The latter is why it’s being added this time around.

The US actually wants to get rid of leap seconds because they cause disruption to equipment, but hasn’t managed to just yet.

The Internet intrinsically relies on the time being right; links around the world use the precise time from an atomic clock to ensure communications are in sync, as do your favorite services. Time is intricately woven into the fabric of the Internet, so what happens when you decide to add a second to the clock?

Well, the last time this happened in 2012 popular services like Reddit, Foursquare and Yelp had hours of downtime along with airlines like Virgin. This was because the updated time is distributed via Network Time Protocol (NTP), and some applications and systems like Linux and MySQL noticed a lost second and froze due to a bug.

In this case, some Linux kernels had a bug that caused them to handle leap seconds incorrectly which caused a “kernel panic” (where the entire system freezes). This time around it should be fixed, however.

Some companies, like Google, work around the problem in advance by using a technique called “leap smearing” which means the company gradually adds milliseconds to the system clocks of it’s servers ahead of the time, so when the time rolls around the servers don’t think anything is wrong.

Perhaps this time around companies will have more luck, with the Linux bug being resolved for a few years now. We’ve had 25 leap seconds added in the past, so eventually we’ll get it right.

Bugs do have a tendency to pop up in the oddest places, however, so if you notice your favorite site is down at 23:59 on June 30, it’s probably thanks to the leap second.

Image credit: Virginia Department of Astronomy

Get the TNW newsletter

Get the most important tech news in your inbox each week.