Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×
Operating Systems Linux

Linux 5.1 Continues The Years-Long Effort Preparing For Year 2038 (phoronix.com) 118

Linux 5.1 continues the massive undertaking in preparing the kernel for the Year 2038 problem. Phoronix: The Linux kernel has been seeing "Y2038" work for years and the effort is far from over. Thomas Gleixner (a Linux kernel developer who serves as a member of the technical advisory board at The Linux Foundation) sent in the latest Y2038 work for the Linux 5.1 kernel, which after a lot of ground work in previous kernels has introduced the first set of syscalls that are Year 2038 safe.
This discussion has been archived. No new comments can be posted.

Linux 5.1 Continues The Years-Long Effort Preparing For Year 2038

Comments Filter:
  • by Anonymous Coward on Tuesday March 05, 2019 @03:36PM (#58220558)

    We know from y2k that systems have a long lifetime. Software needs to be fixed well before 2038 to ensure that they work then, especially with Linux in so many embedded systems that make much more use of time data.

    Good on them.

    • No time to waste, guys! There's only 19 years left!

      • by Anonymous Coward

        Some current mortgages and bonds will last longer than that. No need to wait for 19 years for issues to appear.

      • No, there's 595666616 seconds left.
        • That's a huge number which gives the impression there's even more time left.
          You need to do the opposite: there's only 0.19 century left!

          • How much is that in parsecs? I got a Kessel run I got to make before my navi-computers lose their mind.
            • Well as parsecs messure distance and not time it is kind of hardto convert between the units, â" oh it was a joke, Iâ(TM)m terrible at geting them at times, butthsnk you for the effort weneed a bit of humpr here. Have a nice day

      • You are too late already, it is 18 years and so many months. It is definitely not 19 years....

        • You may be too late, but I'm not. I've been storing dates as ISO8601 strings for over a decade now, to bypass all the Pre-1970-01-01/Y2000/Y2038 bullshit. All my systems can go from 0000-01-01 to 9999-12-31.

          • by ceoyoyo ( 59147 ) on Tuesday March 05, 2019 @04:38PM (#58220942)

            Y10K bug.

          • You're tardy, fella. I began using the ISO8601 - or "Asian" - date format way back in the (Nineteen) Eighties, likely before it was even an ISO standard. It's OBVIOUSLY the only way to store and represent dates in a fashion useful for non-human computing. Frankly, humans themselves would do well to adapt their squishy CPUs to internally represent dates in that fashion. That is still a work in progress for me, largely due to the ongoing external bombardment of non-ISO8601 insanity.

            • by Michael Woodhams ( 112247 ) on Wednesday March 06, 2019 @01:12AM (#58223250) Journal

              Ditto. I felt smugly superior to be using little-endian DD-MM-YYYY which was so much better (consistent) than the USA's middle-endian MM-DD-YYYY format. Then starting in 1988, my MSc thesis was on an experiment with many Japanese collaborators (they had the money, we had the supernova) and I saw them use YYYY-MM-DD and I was an instant convert. We're already big-endian in our decimal notation, so dates should be too. And in YYYY-MM-DD, chronological order and 'alphabetic' order are the same.

          • by Kjella ( 173770 )

            All my systems can go from 0000-01-01 to 9999-12-31.

            I think you will find plenty systems choke on year "zero" which is actually year 1 BC. There's technically no reason why since anything before 1753 is wonky anyway and ISO 8601 allows it, but you'll have a lot less headaches with 0001-01-01 as your min-value.

            • I am guessing that the reference to 1753 is the switch-over from the Julian calendar to the Gregorian calendar but depending on your country the switch-over happened on different dates over a period of 3.5 centuries.

              I presume that computers use the Gregorian calendar for all dates including before the Gregorian calendar was invented in October 1582. I always wondered whether historians converted historical dates to the Gregorian calendar. For example, Christ's birthday of 25th December is the Gregorian cale

              • by ebh ( 116526 )

                And people wonder why tzdata gets updated so often...

              • by hawk ( 1151 )

                > For example, Christ's birthday of 25th December is the Gregorian calendar date but some counties such
                >as Russia use the 7th January as Christ's birthday because that is the old calendar equivalent date.

                No, they don't in any way, shape, or form "Use" January 7th.

                Rather, they use a calendar that says its December 25, while the rest of us are using January 7.

                I assume that the Russians have switched to the Gregorian for secular use, but the overwhelming majority of Orthodox and most Eastern Catholics ou

                • I agree with you, you repeated my point. I should of been clearer that the 7th January was the Gregorian date which is equivalent to 25th December in the Julian calendar.

    • by darkain ( 749283 )

      No shit! At my workplace, we *STILL* have a SCO Unix machine in production, along with some HP printers that just turned 20 years old in January... Y2038 is now less than 20 years away, so anything built today MIGHT be running then!

    • Back in my day, we waited 1997 and then worked excessive hours in a panic for three years. If it was good enough for us, it should be good enough for you.

      I actually had a 100% genuine post-Y2K bug that I needed to fix. I was one of the main people in charge of source control (which was SCCS) in our company at the time. On 2nd Jan my on-call cell phone rang (while I was watching Sleepy Hollow in a movie theatre - oops!) A few rather keen developers were working, despite it being a holiday, and were getting w

  • I wonder if Linux will survive to this date even without this problem.
    • Some incarnation of it will almost certainly be in use. Maybe it won't be in every smartphone, tablet, and car like it is now - but there will almost certainly be servers running it, even if they are called "legacy systems", and even if they are virtualized.

    • It was almost 4 years from 4.0 to 5.0, and we're 19 years from 2038, so that puts us at somewhere around 10.0, not 23.1. Of course Linus may completely change the number system by then, so it's impossible to predict.

  • only 12 years left... not that I'm counting...
    • by lazarus ( 2879 )

      You may not be counting in base10. You may be right in base16 depending on exactly when in 2038 it happens.

    • by Merk42 ( 1906718 )
      So you plan to go completely off the grid and not rely on any Linux powered technology once you retire in 12 years?
  • Maybe this is an opportunity for computer science students who want to learn more about the Linux kernel see see its inner workings.

  • by Anonymous Coward

    -typedef time_t int
    +typedef time_t long

    There. Fixed it.

    • While you're at it, why use a signed type at all?
      • by vovin ( 12759 )

        So returning -1 can be used to indicate an error?
        Also time_t is already defined as a long in the linux kernel so its 64 bits on a 64 bit arch kernel and 32 for a 32 bit arch.
        I think this set of syscalls is mainly for 32 bit architectures to be able to be explicit about 64 time_t values
        Meaning that the implicit time_t is now the same as the explicit time64_t on 64 bit architectures while (if you care) about portability and correctness across 32/64 architectures you would start using time64_t.

        Here are the 2 e

        • by Megane ( 129182 )
          So how do you tell the difference between -1 as an error and -1 as one second before the epoch? History didn't start in 1970, and a good number of humans still alive today were born before then.
  • by ardmhacha ( 192482 ) on Tuesday March 05, 2019 @04:25PM (#58220894)

    The Y2K bug hit well before the year 2000.

    Back in 1990 the company I worked for had a problem when a 10 year contract with scheduled payments was entered into the system in 1990. All the programmers in the company spent weeks working through source code searching for places where dates were stored with a 2 digit year. I assume the Y2038 bug has already hit systems where future dates are used,

  • Many who are have been hired the last 20 years will be going on pension well after 2038 ... you need to store the date in something - many have resulted in storing dates in strings, which is less than perfect.
  • Well we need to come in Saturday and Sunday to keep up + WE need to talk about your TPS reports!

  • 19 years to rebuild Linux from Scratch
    • Nope, you have 18 years plus some months until Y2038 hits world-wide at 03:14:07 UTC on 19 January 2038. If you wait 19 years, you will be too late.

      Imagine simultaneous world-wide failures predominantly in Embedded Systems when Y2038 bites.

      If you try to set your smart-phone to 2039, you will find that you can't get past 2036. Why is that ? Answer Y2038.

    • Na href=https://en.wikipedia.org/wiki/Google_Fuchsia>Google Fuchsia...
  • netbsd and OpenBSD made time_t 64 bit even on 32 bit architectures. FreeBSD is a bit lamer and didn't do that for 32 bit x86.

    Pathetic.

    • by zyche ( 784345 )

      This is the comment that should be pegged at the top.

    • BSDs are chill with breaking API and ABI between major versions, while Linux kernel keeps them stable (or at least not intentionaly broke them), so such transition has to be more complicated (like in off_t 32->64 bit transition where there are two sets of functions / data types and programs can either explicitly use the 64-bit ones, or be recompiled with define that transparently switches to 64-bit ones).

      • Wrong, there is no "more complicated" solution that will help here.

        Not an excuse when 32 bit time is ending, the API/ABI *HAS* to be broken for this one

        Linux devs less capable is all

All the simple programs have been written.

Working...