Ad Widget

Collapse

Trigger Expression and nodata

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • IPTC
    Junior Member
    • Aug 2019
    • 9

    #1

    Trigger Expression and nodata

    Hi everyone,

    I'm currently using Zabbix 4.4, and I'm trying to build a trigger expression around an item(OID) that returns either 0 or 1. I'm only interested in archiving the 1 value (currently using a regular expression and discarding the 0 value).

    The problem I'm having is trying to create a trigger that resolves on its own, using only said Item.



    I've tried the following trigger expressions:

    {Host:test.last(5m)}=1 (If the OID returns 0 for over 5 minutes and the item has no data because I'm discarding everything diferent than 1, shouldn't this trigger autoresolve on its own? As it stands the problem doesn't autoresolve.)

    {Host:test.last()}=1 and {Host:anothertest.last()}>1 (Using another item, resolves the trigger when the test Item is no longer receiving the value 1, but that's not what I need)

    As of right now I have no clue on how I can create a trigger expression that auto resolves on its own, only using said item.


    Thanks for reading.
    Last edited by IPTC; 24-10-2023, 18:23. Reason: Fixing phrasing.
  • Answer selected by IPTC at 25-10-2023, 12:03.
    cyber
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • Dec 2006
    • 4807

    last(5m)... last is LAST... it does not mean "during last 5m" .. it just the last value... be it 1 minute ago or 5 minute ago.
    last (<sec|#num>,<time_shift>)
    The most recent value. sec (ignored, equals #1) or #num (optional) - the Nth most recent value
    time_shift (optional) - evaluation point is moved the number of seconds back in time

    If you want to close it automatically use "last()=1 and nodata(5m)=0​" "last value is 1 and it has arrived in last 5 minutes"

    Comment

    • cyber
      Senior Member
      Zabbix Certified SpecialistZabbix Certified Professional
      • Dec 2006
      • 4807

      #2
      last(5m)... last is LAST... it does not mean "during last 5m" .. it just the last value... be it 1 minute ago or 5 minute ago.
      last (<sec|#num>,<time_shift>)
      The most recent value. sec (ignored, equals #1) or #num (optional) - the Nth most recent value
      time_shift (optional) - evaluation point is moved the number of seconds back in time

      If you want to close it automatically use "last()=1 and nodata(5m)=0​" "last value is 1 and it has arrived in last 5 minutes"

      Comment

      • IPTC
        Junior Member
        • Aug 2019
        • 9

        #3
        Originally posted by cyber
        last(5m)... last is LAST... it does not mean "during last 5m" .. it just the last value... be it 1 minute ago or 5 minute ago.
        last (<sec|#num>,<time_shift>)
        The most recent value. sec (ignored, equals #1) or #num (optional) - the Nth most recent value
        time_shift (optional) - evaluation point is moved the number of seconds back in time
        If you want to close it automatically use "last()=1 and nodata(5m)=0​" "last value is 1 and it has arrived in last 5 minutes"
        Thanks cyber! this is exactly what I wanted, I feel dumb for not thinking of such a simple expression.
        Last edited by IPTC; 25-10-2023, 11:57. Reason: posted without finishing the message.

        Comment

        Working...