Ad Widget

Collapse

Trigger on first value and on value change

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • looping
    Junior Member
    • Mar 2018
    • 2

    #1

    Trigger on first value and on value change

    Hello,
    First of all, I'm new to zabbix so I don't know a lot yet, I have only played with it since 6 weeks.

    Here is my question:
    I have a string value from an item. I would like to trigger an action when the item is created (at this time there will be only one value in the history) and after that when the value changes.

    Here is what I would like it to operate:

    1- Item creation with Value : AAA => trigger
    2- Value : AAA
    3- Value : AAA
    4- Value : BBB => trigger
    5- Value : BBB

    The expression {MyTemplace:MyItem.diff()>0} is ok the the value change, but I can't find one for the initial value. I have messed around with trigger expressions functions like change, diff, count with no luck.

    Any hints or directions I should follow ?
    Thanks
  • gskalauhov
    Junior Member
    • Apr 2019
    • 1

    #2
    Hi,
    I solved same case using:
    {MyTemplate:MyItem.count(#2)}<2 or {MyTemplate:MyItem.diff()=1}

    Comment

    Working...