Want to know about the year 2038?

Jothi Basu
6 min readJul 2, 2022

--

Before getting into the actual theory, let’s clarify what drags me here.

I’m working on a future problem where I tried to set the date in 2050. My computer doesn’t allow me to do that. Few minutes I wonder why it’s happening?

Then started googling and learned about 2038 problem and Y2K problem.

What is it?

The 2038 problem refers to the time encoding error that will occur in the year 2038 in 32-bit systems. This may cause havoc in machines and services that use time to encode instructions and licenses. The effects will primarily be seen in devices that are not connected to the internet.

As we all know from computer programs who says that computer can only understand 0’s and 1’s and so everything (numbers, text, audio, video, etc.) is stored in binary format in the Computer. From this, we can conclude that it’s a binary which means 2. So, now it’s easier for us to understand what is 32-bit systems which holds the maximum positive value of 2,147,483,647 (or hexadecimal 7FFFFFFF16) for a 32-bit signed binary integer in computing.

The terms 32-bit or 64-bits are generally used to represent processor architecture. A 32-bit processor includes a 32-bit register. This register stores memory addresses and the processor uses these memory addresses to access the data.

The data/variables are stored in Computers at some memory addresses. These memory addresses are also integers and they also need to have certain bits to store these addresses. As mentioned above, these addresses will be stored in the register.

From the above table, we can understand that a 32-bit Operating System can access ²³² memory addresses i.e. 4,294,967,296 memory addresses which can be translated to 4 GB as per the calculation below. The memory space (RAM) is limited by the number of addressable memory. So a 32-bit Operating System (in other words, 32-bit processor) can access a maximum of 4 GB RAM (actually, it will be less than 4 GB because part of the registry is used for other temporary values).

4,294,967,296 bytes
= (4,294,967,296 / 1024) kB = 4,194,304 kB
= (4,194,304 / 1024) MB = 4096 MB
= (4096 / 1024) GB
= 4 GB

Hope I’ve not bored with some technical calculations 😜.

Now let’s come to the actual point, 32-bit system have some limit of storing the data (includes time). The limit is from 0 (00:00:00 UTC January 1st 1970) to +(231–1) and -(231–1) which is equal to 2,147,483,647 seconds going both ways. 2 billion seconds may seem like a lifetime (and it is), but this system will still count its last second precisely on 03:14:07 19th January 2038.

The counter will then begin to count from the negative scale, once this date comes to pass, causing the computers to reset to December 13th 1901, leading to all kinds of errors in every modern 32-bit computer.

This is the 2038 problem, which will mark the end of UNIX time and subsequently the UNIX epoch. It could also cause a lot of chaos if left unchecked.

How it could affect the world?

Almost every piece of equipment today contains a microprocessor that runs on this system. Embedded systems in factory machinery and transportation systems, such as those found in cars and airplanes, are used to automate certain processes and coordinate with other parts of the system. For example, cars use onboard computers to monitor electronic stability control, traction control, the GPS system, braking systems, etc. When the UNIX epoch ends, these machines could malfunction, harming the human users or onboard passengers during the possible system crash.

Licenses today use dates to verify and regulate users, so a fault in this dating system would result in the termination and overall malfunction of the subscription records that the company uses, thus harming many users. This is the same for any service that uses a timestamp for authenticating and renewing user access to their work and private document; it will result in the inaccessibility of these documents and financial information once the UNIX epoch comes to an end.

The effects from this problem aren’t only going to be felt after 2038, but also much earlier, as many apps and websites use future dates for scheduling, managing hedge funds, etc.

Any Solutions?

The 2038 bug is similar to the millennial bug (the Y2K scare in the year 2000), but it’s potentially more damaging because there are far more devices in much more diverse types of electronic equipment today.

In fact, this is similar to what we did when Gangnam Style “broke” YouTube in 2014. That year, the insanely popular Kpop song broke every view record until then, racking up over 2 billion views.

The problem was that YouTube’s view counter was designed on a 32-bit system, meaning it also had the same 2,147,483,647 limit. Because what video would possibly ever be watched that much?

Eventually, YouTube switched to a 64-bit system and all was well.

Unfortunately, there doesn’t seem to be one solution that works as a universal remedy for this problem.

For those devices connected to the internet, a simple software update could solve this issue, so the majority of computing devices are going to be fine, as the IoT revolution has linked more and more devices to the internet (computers, laptops, tablets, smartwatches, household appliances, cars etc.).

Better computing systems are already replacing the 32-bit system, as 64-bit computers are being used in the new electronics coming out today. They are poised to solve this problem for a much longer time, a time far greater than the age of the universe itself! These systems will be able to keep time for 20 times the current age of the universe, which comes to around 292 billion years!

The most problematic devices are going to be those that aren’t connected to the internet and that can’t be updated through a software patch. These are probably going to cause a bit of havoc and fuel the mass hysteria of “the end of the world in 2038”.

So, at the very least, we have a backup fix in case we don’t find a more elegant solution before 2038.

Is it going to stop further?

After upgrading the systems to 64-bit is this not going to happen?

So how much memory can 64-bit Operating System access? Theoretically, it can access ²⁶⁴ (18,446,744,073,709,551,616) memory addresses which comes down to 17,179,869,184 GB of RAM. Yes, you read it right!! It’s a whopping 17 billion GB. But in practice, our computers are too small to use all this RAM. As per my reading/understanding, 64-bit Operating System has a limit of 16 TB RAM access. Similarly, 8-bit and 16-bit Operating Systems can access only 0.25 kB and 64 KB RAM respectively.

What’s going to happen after we reached this limit too (64-bit issue) — in some 30,000 years?
Is for future generations to worry about. 😅

--

--