Uploaded image for project: 'ZABBIX FEATURE REQUESTS'
  1. ZABBIX FEATURE REQUESTS
  2. ZBXNEXT-7443

avg(latest_foreach(...., 30s)) result is non sensical

XMLWordPrintable

    • Icon: Change Request Change Request
    • Resolution: Duplicate
    • Icon: Trivial Trivial
    • None
    • 6.0.0beta2, 6.0.0beta3
    • Server (S)
    • None

      Two seperate bugs cause the output of avg(latest_foreach(...., 30s)) to be non sensical if any item being queried becomes unavailable (such as if discovery no longer returns it).

       

      1. avg appears to cast the null value from latest_foreach to 0 resulting in a low average (we have values of 100 in all items, but half of them are unavailable resulting in 50%)
      2. latest_foreach doesnt support a time parameter. Documentation as to the parameters of latest_foreach is vauge but seems to indicate that foreach functions should have a time parameter "foreach_function(item filter,time period)" - if you look at the code last_foreach does not.

       

      I'm willing to submit a patch for part 2, it looks simple enough to fix.

            wiper Andris Zeila
            splitice Mathew
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: