Ad Widget

Collapse

Trigger for last N values

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • LASN
    Junior Member
    • Nov 2010
    • 2

    #1

    Trigger for last N values

    Hello all.

    I've been looking for a way to trigger an event when last N values are greater than X. The function .last(#N) gets de Nth previous value, but I'd like to get all N values, and compare then to X. If all of them are greater than X, then trigger the event. Does a function like this exist in Zabbix?
    I'm using avg(N) right now, but sometimes I get a spike much greater than the treshold, what makes the average value higher than the established limit, even though is just one value. I would like to eliminate this event with the function described before.

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

    #2
    use min item.min(#5)>=val
    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

    • LASN
      Junior Member
      • Nov 2010
      • 2

      #3
      True, it will work. Thank you.

      Comment

      Working...