Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-17369

Zabbix 4.4: wmi.getall[] - incorrect output for values with real32 type

XMLWordPrintable

    • Icon: Problem report Problem report
    • Resolution: Fixed
    • Icon: Trivial Trivial
    • 4.4.5
    • Agent (G)
    • None
    • Team C
    • Sprint 69 (Oct 2020), Sprint 70 (Nov 2020), Sprint 71 (Dec 2020), Sprint 72 (Jan 2021)
    • 0.25

      Problem:
      wmi.getall[] - returns incorrect value when using data type real32
       

      Usage:

       C:\Program Files\Zabbix Agent>zabbix_get -s 127.0.0.1 -k wmi.get[root\OpenHardwareMonitor,"select Max from sensor where (Parent LIKE '%RAM%' AND SensorType = \"Load\")"]
      

      Returned value: 79.757965

      C:\Program Files\Zabbix Agent>zabbix_get -s 127.0.0.1 -k wmi.getall[root\OpenHardwareMonitor,"select Max from sensor where (Parent LIKE '%RAM%' AND SensorType = \"Load\")"]
      

      Returned value: [\{"Max":4635312884778270720.}]

      Description:
      When using wmi.getall[], if the object parameters have type Real32 the returned value is incorrect. When using wmi.get[] there's no such issue.

      Tried to debug it, the returned value using key wmi.getall[] as to IEEE 754 (decimal number represented in hex) - the resulted value is incorrect. Also it falls over the 32-bits.

      P.S. Also the left-most dot after the digits looks suspicious.

            dgoloscapov Dmitrijs Goloscapovs
            4ernomor Igor Zobun
            Team C
            Votes:
            4 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated:
              Resolved: