Ad Widget

Collapse

Setting up a trigger for events within a time period

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • ZummiGummi
    Junior Member
    • Apr 2020
    • 6

    #1

    Setting up a trigger for events within a time period

    Hello,

    I'm setting up a template to monitor an event log entry for a Windows host using the active agent.

    The item for the template is as follows.
    Click image for larger version

Name:	2020-04-28 17_05_00-Configuration of items and 5 more pages - Work - Microsoft​ Edge.png
Views:	3588
Size:	33.2 KB
ID:	400251

    The logs are being detected correctly.
    Click image for larger version

Name:	2020-04-28 18_16_50-History [refreshed every 30 sec.] and 5 more pages - Work - Microsoft​ Edge.png
Views:	3398
Size:	22.6 KB
ID:	400253
    What I would like to setup is a trigger if the event is logged, but only log this once since this event can fire continuously.

    If no new events are logged in 1 hour, then the problem should be marked as resolved.
    Click image for larger version

Name:	2020-04-28 18_13_56-Configuration of triggers and 5 more pages - Work - Microsoft​ Edge.png
Views:	3788
Size:	45.0 KB
ID:	400252
    At the moment, each server is reporting the same error multiple times.

    Is the problem expression correct? I'm not filtering the data, since I'm doing that in the item.

    Is the recovery expression the correct way to make something OK or should it be in the problem expression? e.g. trigger warning if there is an event and it's less than 1 hour old? Once it's been over 1 hour and there are no new events, it gets marked as resolved.

    Thank you for your time.
  • ZummiGummi
    Junior Member
    • Apr 2020
    • 6

    #2
    I unlinked the template and data, and added it back again, it's now reporting only a single problem per server now instead of multiple problems.
    The problem expression was also changed to the below, but it's still reporting entries older than 1 hour as a problem and hasn't resolved.

    Code:
    {Template Module Windows event logs by Zabbix agent active:eventlog[System,,"Warning","Resource-Exhaustion-Detector",2004,].count(1h)}>5
    Any ideas?

    Comment

    • ZummiGummi
      Junior Member
      • Apr 2020
      • 6

      #3
      Thank you for your help splitek.
      I've ended up with this trigger, so it will activate if there is an entry, but will resolve itself if no new events occur in 15 minutes. The error seems to be logged every 5 minutes.

      Code:
      {Template Module Windows event logs by Zabbix agent active:eventlog[System,,"Warning","Resource-Exhaustion-Detector",2004,].logeventid()}=1 and {Template Module Windows event logs by Zabbix agent active:eventlog[System,,"Warning","Resource-Exhaustion-Detector",2004,].nodata(15m)}=0
      The only problem is that the trigger is based on the timestamp instead of the time of the event, so old entries are picked up, but are resolved after 15 minutes. Not sure there is away around that.

      Comment


      • MikeBrosas
        MikeBrosas commented
        Editing a comment
        Hi, Any update about here? I tried to follow your config here, and I can also monitor the 2004, but the problem is, it only monitor once, after I upload the template it will show in latest data then send a triggers, but after that nothing happens next. It didnt show new latest data and didnt send a resolve triggers.
    • MikeBrosas
      Junior Member
      • Sep 2020
      • 5

      #4
      Hi, Any update about here? I tried to follow your config here, and I can also monitor the 2004, but the problem is, it only monitor once, after I upload the template it will show in latest data then send a triggers, but after that nothing happens next. It didnt show new latest data and didnt send a resolve triggers.

      Comment

      Working...