Year 2038 problem

Year 2038 problem

The year 2038 problem (also known as "Unix Millennium bug", or "Y2K38" by analogy to the Y2K problem) may cause some computer software to fail before or in the year 2038. The problem affects all software and systems that store system time as a signed 32-bit integer, and interpret this number as the number of seconds since 00:00:00 January 1, 1970. [cite web | url =http://www.opengroup.org/onlinepubs/000095399/ | title = The Open Group Base Specifications Issue 6 IEEE Std 1003.1, 2004 Edition (definition of epoch) | work = IEEE and The Open Group | publisher = The Open Group | date = 2004 | accessdate = 2008-03-07 | quote = ] The latest time that can be represented this way is 03:14:07 UTC on Tuesday, January 19, 2038. Times beyond this moment will "wrap around" and be stored internally as a negative number, which these systems will interpret as a date in 1901 rather than 2038. This will likely cause problems for users of these systems due to erroneous calculations.

Most 32-bit Unix-like systems store and manipulate time in this format, so this problem is often referred to as the "Unix Millennium Bug". However, there are many other non-Unix operating systems and software that store and manipulate time this way, and these will be just as affected by this problem.

Known problems

In May 2006, reports surfaced of an early Y2038 problem in the AOLserver software. The software would specify that a database request should "never" time out by specifying a timeout date one billion seconds in the future. One billion seconds (just over 31 years 251 days and 12 hours) after 21:27:28 on 12 May 2006 is beyond the 2038 cutoff date, so after this date, the timeout calculation overflowed and calculated a timeout date that was actually in the past, causing the software to crash. [cite web | url=http://substitute.livejournal.com/1430908.html | title=The Future Lies Ahead | date=2006-06-28 | accessdate=2006-11-19] [cite web | url=http://www.mail-archive.com/aolserver@listserv.aol.com/msg09812.html | title=Something wrong after 2006-05-12 21:25 | first=Dossy | last=Shiobara | date=2006-05-17 | accessdate=2006-11-19]

Example

$ dateSu 6. Jul 00:32:27 CEST 2008$ openssl req -x509 -in server.csr -key server.key -out server.crt -days 10789 && openssl x509 -in server.crt -text | grep After Not After : Jan 18 22:32:32 2038 GMT$ openssl req -x509 -in server.csr -key server.key -out server.crt -days 10790 && openssl x509 -in server.crt -text | grep After Not After : Dec 14 16:04:21 1901 GMT (32-Bit System)$ openssl req -x509 -in server.csr -key server.key -out server.crt -days 2918831 && openssl x509 -in server.crt -text | grep After Not After : Dec 31 22:41:18 9999 GMT (64-Bit System)

olutions

There is no easy fix for this problem for existing CPU/OS/File System combinations. Changing the definition of time_t to use a 64-bit type would break binary compatibility for software, data storage, and generally anything dealing with the binary representation of time. Changing time_t to an unsigned 32-bit integer, effectively allowing timestamps to be accurate until the year 2106, would affect many programs that deal with time differences, and thus also break binary compatibility in many cases.

Most operating systems for 64-bit architectures already use 64-bit integers in their time_t. The move to these architectures is already under way and many expect it to be complete before 2038. Using a (signed) 64-bit value introduces a new wraparound date in about 290 billion years, on Sunday, December 4, 292,277,026,596. As of 2007, however, hundreds of millions of 32-bit systems are deployed, many in embedded systems, and it is far from certain they will all be replaced by 2038. Further, long before that date programs which project any kind of pattern into the future will begin to run into problems. E.g.; by 2028, projecting a trend ten years will encounter the "bug".

Despite the modern 18- to 24-month generational update in computer systems technology, embedded computers may operate unchanged for the life of the system they control. The use of 32-bit time_t has also been encoded into some file formats, which means it can live on for a long time beyond the life of the machines involved.

A variety of alternative proposals have been made, some of which are in use, including storing either milliseconds or microseconds since an epoch (typically either January 1, 1970 or January 1, 2000) in a signed-64 bit integer, providing a minimum of 300,000 years range. [cite web
url=http://unununium.org/articles/uuutime
archiveurl=http://web.archive.org/web/20060408161959/http://unununium.org/articles/uuutime
archivedate=2006-08-04
title=Unununium Time
accessdate=2006-11-19
] [cite web
url=http://java.sun.com/j2se/1.4.2/docs/api/java/lang/System.html#currentTimeMillis()
title=Java API documentation: System.currentTimeMillis
author=Sun Microsystems
accessdate-2007-05-07
] Other proposals for new time representations provide different precisions, ranges, and sizes (almost always wider than 32 bits), as well as solving other related problems, such as the handling of leap seconds.

See also


* Year 2000 problem
* Year 10,000 problem
* Time formatting and storage bugs
* Epoch (reference date)
* Network Time Protocol
* Unix time
* System time
* Unix billennium

References

External links

* [http://www.2038bug.com/ The Year-2038 Bug Website]
* [http://computer.howstuffworks.com/question75.htm Entry in How Stuff Works]
* [http://maul.deepsky.com/%7Emerovech/2038.html The Project 2038 Frequently Asked Questions]
* [http://www.merlyn.demon.co.uk/critdate.htm#2038 Critical dates 2038]
* [http://y2038.googlecode.com/ A 2038-safe replacement for time.h on 32 bit systems]


Wikimedia Foundation. 2010.

Игры ⚽ Поможем написать курсовую

Look at other dictionaries:

  • Year 2000 problem — Y2K redirects here. For other uses, see Y2K (disambiguation). The (French) sign reads 3 January 1900 instead of 3 January 2000 The Year 2000 problem (also known as the Y2K problem, the Millennium bug, the Y2K bug, or simply Y2K) was a problem for …   Wikipedia

  • Year 2007 problem — The Year 2007 problem also known as Y2K7 (or DST07) is an issue caused by a US mandated change to daylight saving time, which has repercussions in the computer industry.cite web | date = 2007 01 29 | accessdate = 2007 03 01 | title = Daylight… …   Wikipedia

  • Year 2000 problem — Passage informatique à l an 2000 Le passage informatique à l an 2000, couramment appelé bug de l an 2000 ou bogue de l an 2000 (ou Y2K aux États Unis), était un ensemble de problèmes de programmation portant sur le format de la date dans les… …   Wikipédia en Français

  • Year 10,000 problem — The Year 10,000 problem, or Y10K, is the class of all potential software bugs that may emerge should the need to express years with five digits arise. The problem can have discernible effects today, but is also sometimes mentioned because of its… …   Wikipedia

  • 2038 — (MMXXXVIII) will be a common year starting on Friday of the Gregorian calendar. Predicted events* January 5 Annular solar eclipse in the Caribbean Sea, Atlantic Ocean, and western Africa. * January 19 A common computing representation of date and …   Wikipedia

  • Проблема 2038 года — В этой статье не хватает ссылок на источники информации. Информация должна быть проверяема, иначе она может быть поставлена под сомнение и удалена. Вы можете …   Википедия

  • Jahr-2000-Problem — Millennium Bug auf einer Anzeigetafel in Nantes, aufgenommen am 3. Januar 2000 Das Jahr 2000 Problem, auch als „Millennium Bug“ oder „Y2K Bug“ („Year 2 Kilo“ = Jahr 2000) bezeichnet, ist ein Computerproblem, das durch die interne Behandlung von… …   Deutsch Wikipedia

  • Unix time — Unix time, or POSIX time, is a system for describing points in time, defined as the number of seconds elapsed since midnight Coordinated Universal Time (UTC) of January 1 1970, not counting leap seconds. It is widely used not only on Unix like… …   Wikipedia

  • List of software bugs — Many software bugs are merely annoying or inconvenient but some can have extremely serious consequences either financially or as a threat to human well being. This is a list of the software bugs with the most notable consequences: Space… …   Wikipedia

  • Epoch (reference date) — In the fields of chronology and periodization, an epoch means an instant in time chosen as the origin of a particular era. The epoch then serves as a reference point from which time is measured. Time measurement units are counted from the epoch… …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”