Ad Widget

Collapse

system.uptime stays at 0 after Vituozzo 7 Kernel Update (zabbix-agent 3.0 and 3.2)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • KervyN
    Junior Member
    • Mar 2017
    • 10

    #1

    system.uptime stays at 0 after Vituozzo 7 Kernel Update (zabbix-agent 3.0 and 3.2)

    Hi,
    can someone tell me how system.uptime is collected?
    We updated the Kernel in Virtuozzo 7 and the zabbix-agentd inside the guests now reports system.uptime with value 0.
    The host still got the right uptime.

    Code:
      Host: test-ubuntu-1604 (guest)
      uname -r: 4.2.0-327.36.1.vz7.20.18
      cat /proc/uptime: 4102.54 8161.06
      zabbix_agentd -V: zabbix_agentd (daemon) (Zabbix) 3.0.1 Revision 58734 26 February 2016, compilation time: Apr  8 2016 12:15:36
      system.uptime: 0
    Code:
      Host: test-ubuntu-1404 (guest)
      uname -r: 3.10.0-327.36.1.vz7.20.18
      cat /proc/uptime: 1473.02 8786.81
      zabbix_agentd -V: zabbix_agentd (daemon) (Zabbix) 3.2.3 Revision 64610 21 December 2016, compilation time: Dec 21 2016 13:52:42
      system.uptime: 0
    Code:
      Host: test-virtuozzo-7 (host)
      uname -r: 3.10.0-327.36.1.vz7.20.18
      cat /proc/uptime: 966618.50 15309985.87
      zabbix_agentd -V: zabbix_agentd (daemon) (Zabbix) 3.2.3 Revision 64610 21 December 2016, compilation time: Dec 21 2016 13:37:14
      system.uptime: 967387
    Any Ideas?
    Last edited by KervyN; 01-03-2017, 17:21. Reason: Updated Kernelversion for i22-test-ubuntu-1604
  • KervyN
    Junior Member
    • Mar 2017
    • 10

    #2
    It seems to be n Issue with openVZ / Virtuozzo 7.
    We compiled a this script [1] and have the same problem.

    [1] https://gist.github.com/KervyN/64fe4...a035fcb0667d0e

    We are going to contact our Odin TAM and will keep you up2date.

    Best regards
    Kervyn

    Comment

    • KervyN
      Junior Member
      • Mar 2017
      • 10

      #3
      We reported the issue to Odin. Here is their answer:

      It appears to be a kernel issue, indeed.

      The uptime is calculated properly, however the function ‘do_sysinfo()’ calls few notifiers after uptime calculation, and one of them zeroes the resulting structure. (Check “kernel/sys.c” in the sources, ‘do_sysinfo()’ calls ‘virtinfo_notifier_call()’; it used to be before uptime calculation in Virtuozzo 6, see “kernel/time.c” for details.)


      The issue has been reported to developers as PSBM-62094, to be fixed in the future kernels.

      For now, you can read “/proc/uptime” instead, it is not affected.

      Comment

      Working...