We all remember the hysteria over the supposed disasters the Y2K bug would cause. If you don’t remember that, you’re obviously very young and I resent your age.
Chris Marget wrote up a nice piece looking into a similar bug. It’s probably not going to by as hyped as Y2K, but it’s nonetheless important. Because of the 32-bit signed integer used in Unix-based systems, there’s a maximum value of 2.1 billion seconds in the “epoch”, before it basically runs out and started back over at the beginning with 10000000000000000000000000000000. That may sound like a lot, but it’s actually about 68 years. Since the Unix epoch begins on January 1, 1970, this means we’re due for an epoch reset around 2038.
Interestingly, the Network Time Protocol will run out two years earlier. It’s not due to having the epoch date start two years earlier. Instead, it’s because it uses an unsigned 32-bit integer to keep time, so it’s actually good for 4.2 billion seconds, but the base clock starts at 1900.
Probably won’t cause planes to fall out of the sky, but something to keep an eye on in the next decade or two!
Read more at: Epoch Rollover: Coming Two Years Early To A Router Near You!