Ad Widget

Collapse

Trigger seems to be ignoring Recovery criteria - Help with expression

Collapse
This topic has been answered.
X
X
 
  • Time
  • Show
Clear All
new posts
  • adfrost
    Junior Member
    • May 2022
    • 7

    #1

    Trigger seems to be ignoring Recovery criteria - Help with expression

    I'm struggling to get a trigger recovery to work properly. I'm working on some UPS monitoring that generates an alert when the device is turned off. I've got three models I'm monitoring and I am having issues with one of them.

    This is the base expression for determining it is turned off:
    Code:
    {net.str.ups.liebert-unity.TEST.tpl:upsOutputVoltage.max(2m)}=0
    That works fine for two of the models, but one of the models I'm monitoring is exhibiting behavior where - even when it is turned off - it reports positive voltage briefly:

    Click image for larger version

Name:	2022-05-26 14_02_16-Window.png
Views:	580
Size:	68.4 KB
ID:	445189

    Click image for larger version

Name:	2022-05-26 14_05_19-History.png
Views:	521
Size:	32.6 KB
ID:	445190

    This causes it recover, even though it is still actually off. The trigger generates an alert which feeds into our ticketing system, and the end result is that we get a constant stream of tickets. To get around this issue for that model, I have added a recovery expression to introduce some hysteresis. Here is how that trigger is defined:

    Click image for larger version

Name:	2022-05-26 14_16_52-Configuration of triggers.png
Views:	550
Size:	33.1 KB
ID:	445191

    What I'm going for is when voltage goes below 10v for 10 minutes, it triggers the problem (that part works) and when voltage goes above 119v for 15 minutes, it should be considered recovered. However, it seems to be ignoring that recovery criteria and recovering even if voltage spikes for less than 15 minutes. Typically I will see voltage spike anywhere from 2-6 minutes at the longest, but it doesn't matter. It recovers anyway. I've tried adjusting the polling period (it was originally 5 minutes, then tried 2 minutes, and now I'm at 1 minute). I've tried using min/max in expression instead of last. I've tried 5m, 10m, and 15m monitoring periods. None of this has worked.

    I'm frankly stumped at this point, as the expressions seems to be formatted properly, and Zabbix is just ignoring it.
  • Answer selected by adfrost at 28-05-2022, 17:19.
    Markku
    Senior Member
    Zabbix Certified SpecialistZabbix Certified ProfessionalZabbix Certified Expert
    • Sep 2018
    • 1781

    last() does not work with a time specification, see https://www.zabbix.com/documentation...gers/functions

    Try max(10m)<10 (= "the values are below 10V for last 10 minutes") for problem expression and min(15m)>=119 for recovery (= "the values are at least 119V for last 15 minutes").

    Markku

    Comment

    • Markku
      Senior Member
      Zabbix Certified SpecialistZabbix Certified ProfessionalZabbix Certified Expert
      • Sep 2018
      • 1781

      #2
      last() does not work with a time specification, see https://www.zabbix.com/documentation...gers/functions

      Try max(10m)<10 (= "the values are below 10V for last 10 minutes") for problem expression and min(15m)>=119 for recovery (= "the values are at least 119V for last 15 minutes").

      Markku

      Comment

      • adfrost
        Junior Member
        • May 2022
        • 7

        #3
        Thanks Markku,
        I've tried that and it works. I didn't realize that last() didn't with time periods. I also had the min & max backwards.

        Comment

        Working...