Ad Widget

Collapse

Unix Millenium Bug

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • vijaya.r85
    Junior Member
    • Apr 2009
    • 20

    #1

    Unix Millenium Bug

    Hi,

    I am facing date issue in a customized report in zabbix 1.8.3 version. On selecting the filters for current day and submitting, it automatically turns for 19th January 2038. On surfing I found this as Unix Millennium bug. Please help to resolve this.

    Thanks in advance.

    Regards,
    Vijaya
  • nelsonab
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Sep 2006
    • 1233

    #2
    More information is required about this problem Yes there is a known issue with time in the standard C library which most Unix derivatives are built upon and that is once you get 2^32 seconds from Jan 1, 1970 time rolls over.

    As for your specific issue more information is needed. I'm sorry but we all suck at mind reading here. :-)
    RHCE, author of zbxapi
    Ansible, the missing piece (Zabconf 2017): https://www.youtube.com/watch?v=R5T9NidjjDE
    Zabbix and SNMP on Linux (Zabconf 2015): https://www.youtube.com/watch?v=98PEHpLFVHM

    Comment

    • vijaya.r85
      Junior Member
      • Apr 2009
      • 20

      #3
      Unix Millenium Bug

      Thanks for your reply Mr. Nelsonab. I have written a script (Groupreport.php) to generate a consolidated report for the group of devices configured and added it in the Report menu of Zabbix. User when selects the dates and clicks filter the report will be generated for the specific dates. This is working fine in zabbix 1.6.4 version for the past 1.5 years. Same I have implemented in zabbix 1.8.3 version. Till a month before it was working fine in this version. Now when I select the dates and click filter, it is generating me the output of January 19 2038. When I call the same script through command line with perl LWP::Agent it works perfect and generates the report aptly. Am quite confused.

      Please Help.

      Comment

      • nelsonab
        Senior Member
        Zabbix Certified SpecialistZabbix Certified Professional
        • Sep 2006
        • 1233

        #4
        I don't know how to help. One thing you could do is make use of a good php debugger. Jetbrains has a good IDE which integrates with the xdebug module for php and is very affordable. I use that program when I'm doing any work on the Zabbix php code.

        Otherwise with the information given it's going to be difficult for anyone to help. The only thing that sticks out in my head is an environment issue, perhaps you're using a global variable which is being overwritten by the Zabbix code, but like I said it's very difficult for anyone to know with the information given.
        RHCE, author of zbxapi
        Ansible, the missing piece (Zabconf 2017): https://www.youtube.com/watch?v=R5T9NidjjDE
        Zabbix and SNMP on Linux (Zabconf 2015): https://www.youtube.com/watch?v=98PEHpLFVHM

        Comment

        • vijaya.r85
          Junior Member
          • Apr 2009
          • 20

          #5
          Unix Millenium Bug

          Thanks for your reply nelsonab. I will check

          Regards,
          Vijaya

          Comment

          Working...