Ad Widget

Collapse

system.localtime[local] returns different values

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • morrtz
    Junior Member
    • May 2019
    • 4

    #1

    system.localtime[local] returns different values

    Hi all,

    First post, please let me know if I'm not in the right location.
    I'm getting 2 different results when running system.localtime[local] -

    root@~ # zabbix_get -s xxxxxxx1 -k "system.localtime[local]"
    2019-05-02,05:56:45.974,-04:00
    root@~ # zabbix_get -s xxxxxxx2 -k "system.localtime[local]"
    2019-05-02,18:56:57.859,+09:00

    When I run only system.localtime I get the same epoch time, so this issue must be related to the local function in some way so I ran the command - date on both servers, they are set for JST.
    So I'm not really sure how the local function works or how it fetches the time exactly, I mean both the above times that returned are shown for similar timezone, but I want it to show the time relating to UTC as server #2 shown.

    Thanks!

  • morrtz
    Junior Member
    • May 2019
    • 4

    #2
    bumping to get some help!

    Comment

    • Mike2K
      Member
      • Oct 2018
      • 62

      #3
      There's definitely some timezone config involved...have you tried running an ntpdate command just to make sure the time is correct ?

      Comment

      • morrtz
        Junior Member
        • May 2019
        • 4

        #4
        Yes, the time in the server is correct.
        Need to know how Zabbix basically checks local time using the local function

        Comment

        • LenR
          Senior Member
          • Sep 2009
          • 1005

          #5
          Maybe this will help https://support.zabbix.com/browse/ZBX-15624 and/or https://support.zabbix.com/browse/ZBX-15301

          Comment

          • morrtz
            Junior Member
            • May 2019
            • 4

            #6
            Thanks for the articles, but these seem irrelevant because they relate to version 4.0 triggering these issues, we are still on 3.0.3 (sorry for not mentioning in the original post!)

            Comment

            Working...