Ad Widget

Collapse

Zabbix spam an email messages every time if a ping go offline for like 20sec.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Mateka0110
    Junior Member
    • Jan 2021
    • 2

    #1

    Zabbix spam an email messages every time if a ping go offline for like 20sec.

    I ping IPs and specific ports. I use for example "net.tcp.service[http,,80]" command to monitor it. I made a trigger with this command "{hostname:net.tcp.service.perf[http,,80].last()}=0" so it triggers when it can't ping the address, but sometimes it go down for half a minute or something like that, wich triggers and zabbix sends the email. But because it just go down for 30sec I dont need the email notification so I just tried to extend my expression so I made this: {hostname:net.tcp.service.perf[http,,80].last()}=0 and {hostname:net.tcp.service.perf[http,,80].timeleft(1,,360)}=360 . The question is it delays the email with 5minutes or it's a wrong command. If it's wrong then someone have a solution or any idea for this case? Thanks for you help guys!
  • Mateka0110
    Junior Member
    • Jan 2021
    • 2

    #2
    Originally posted by cyber
    last() is one of the most trigger happy functions... If you want to eliminate some peaks (or valleys) in your data, try percentile(), or sum or avg over time period ...
    I am not even going to timeleft here... Cannot get my head around your point here... based on only one second period, predict when it reaches 360?
    I think I dont really understand the meaning of things. What does "Last of (T)" means? Yesterday I couldn't figure it out. Could you explain it to me?

    Comment

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

      #3
      last() is one of the most trigger happy functions... If you want to eliminate some peaks (or valleys) in your data, try percentile(), or sum or avg over time period ...
      I am not even going to timeleft here... Cannot get my head around your point here... based on only one second period, predict when it reaches 360?

      Comment

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

        #4
        "Last of (T)" as in expression condition window? You enter that value that will be added to function as <sec|#num>... either in sec or in count (with # in front of it) . How those are interpreted, you can read from docs..
        in case of last()...
        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
        Supported value types: float, int, str, text, log

        Take note that #num works differently here than with many other functions.
        For example:
        last() is always equal to last(#1)
        last(#3) - third most recent value (not three latest values)
        So with last() you only rely on last check. It will fire each time your check fails... But if you check quite often and it fails sometimes for short period and you would like to avoid triggering on each of such temporary failure, you should rely on a bit more results... with some other functions, averaging of summarizing or percentage of failures etc...Like, if you check every 30 sec and 1 fail in a row is fine, but 2 in row should be notified, Then "sum(#2)=0", 2 last ones are 0-> trigger fires. Stays in problem state until successful check comes.. Or you can decide, that during a period of time at least 80% checks have to be OK, then you can use percentile() function for that... percentile(10m,,80)>0, in 10 minutes 80% of values have to be more than 0...

        Comment

        Working...