Ad Widget

Collapse

How do you make a trigger keep alarming until it is acknowledged?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • noxis
    Senior Member
    • Aug 2007
    • 145

    #1

    How do you make a trigger keep alarming until it is acknowledged?

    Is this currently possible or would I have to write a patch/cron to do this myself?

    Edit: By "keep alarming" I mean send out an email every 15 mins or something like that I realise it sits in "TRUE" whether it is acknowledged or not.
    Last edited by noxis; 16-01-2008, 19:27.
  • swaterhouse
    Senior Member
    • Apr 2006
    • 268

    #2
    Right now you cant. Part of 1.6 will be an escalations routine that would probably do what you are looking for.

    This used to exist in 1.1 but was buggy so it was pulled for 1.4

    Comment

    • cstackpole
      Senior Member
      Zabbix Certified Specialist
      • Oct 2006
      • 225

      #3
      Take a look at my blog.
      http://zabbix.com/forum/blog.php?b=14

      This works well enough that I run it on my production systems. 2 things to note: 1) It only sends to one person and if you have a massive failure where many things are calling that script things can get a bit crazy 2) The only way to kill it is to either bring the system up or manually kill it via kill -9 on the command prompt.

      I talk about a second script in that blog post. You can ignore it. I was never comfortable having it run on my testing system much less my production. The start of this year has been tremendously busy for me and I have not even looked at fixing the problems with that script in over a month.

      If you /have/ to have repeating alerts right now, look into this and if you find a problem with the script please post back the changes. I know at least one other person using this script so any improvements would be welcomed.

      Just know that this is NOT a supported method and is something that I have come up with for my use. I do hope it can help others, hence why I posted it.

      Good Luck!

      Comment

      • skogan
        Member
        • Nov 2007
        • 70

        #4
        I have a different way to do it.

        On the zabbix server I set up the following external script:

        Code:
        #!/bin/bash
        
        if [ -z "$2" ]; then
            echo 0
        fi
        
        CURRENTTIME=`date +%s`
        
        MOD=`expr $CURRENTTIME % $2`
        
        if [ "$MOD" -lt 60 ]; then
            echo 1
        else
            echo 0
        fi
        This script accepts a notification interval in seconds on the command line and returns 1 if remainder of current unix time devided by the interval is less than 60, and 0 otherwise. You can have multiple items associated with the script, for different intervals.

        The rest is simple: for every trigger that I need repeated notifications for, I set up a clone of the trigger with the same condition and the notifier item == 1. The trigger's severity I set to INFO. Then I have an action associated with this trigger that send out an email only if it's ON.

        That's it, that all, folks!

        P.S. : It's important that before using this method you should apply a patch that I made to fix Zabbix's overview screen when dealing with multiple triggers with the same name. If you don't do it, your overview screen will not show the correct picture. The patch can be found here:



        P. P. S. : There is a slight glitch that exists in that solution: since in Zabbix triggers are not directly attached to hosts (yep, it's true), the said trigger will appear twice everywhere: once for the actual host it should be attached to and once for the host that the notifier item is a member of.

        [rant]
        Some times I get so frustrated, I just want to hit my head on the wall. Zabbix is, for the most part, a very cool system, but in certain places it's design just plain SUCKS.
        [/rant]
        Last edited by skogan; 04-02-2008, 22:36.

        Comment

        Working...