Ad Widget

Collapse

Duration of down time

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • BeatMaster
    Junior Member
    • Feb 2005
    • 4

    #1

    Duration of down time

    Hello!

    I have made the trigger in Zabbix 1.0 which notifies me when icmp ping is 0 - router is down for 10minutes [trigger is ON] and send me the same message of ping status when triger goes OFF [ping is successful]. So i looked throught the time functions but can' t find answer: i want to get the action message which have the duration of time when the router was down, not the time when it get down. [The time between trigger status changes]

    Thanks for any help
  • BeatMaster
    Junior Member
    • Feb 2005
    • 4

    #2
    looks like it is too complex

    Comment

    • Alexei
      Founder, CEO
      Zabbix Certified Trainer
      Zabbix Certified SpecialistZabbix Certified Professional
      • Sep 2004
      • 5654

      #3
      No, it's not. It will require new macro, say {TRIGGER_IN_PREV_STATE} or similar, which would return time spent in previous trigger state.

      It is not implemented yet.
      Alexei Vladishev
      Creator of Zabbix, Product manager
      New York | Tokyo | Riga
      My Twitter

      Comment

      • BeatMaster
        Junior Member
        • Feb 2005
        • 4

        #4
        Yeah, it's what I wanted. So maybe it could be implemented in version 1.1? - it could be useful.

        Alexei - thanks for the great stuff!Keep developing it and zabbix will be the best!

        Comment

        • bee
          Senior Member
          • Jun 2007
          • 133

          #5
          {EVENT.AGE} = Duration of Problem/Downtime?

          Originally posted by Alexei
          No, it's not. It will require new macro, say {TRIGGER_IN_PREV_STATE} or similar, which would return time spent in previous trigger state.

          It is not implemented yet.
          Hi ALexei,
          Need to confirm with you, is macro {EVENT.AGE} can be use to represent duration of problem (Downtime)?
          I've tried using macro {EVENT.AGE} and always return 0. Any suggestion? or i did missing something here?

          Thanks,
          BEE

          Comment

          • data7
            Junior Member
            • May 2008
            • 18

            #6
            Event Age always returning "0"...

            Originally posted by bee
            Hi ALexei,
            Need to confirm with you, is macro {EVENT.AGE} can be use to represent duration of problem (Downtime)?
            I've tried using macro {EVENT.AGE} and always return 0. Any suggestion? or i did missing something here?

            Thanks,
            BEE

            Hello, this is happening to me too only on 1.6.2, bug confirmed?

            I use these messages for notifications and both worked as expected until 1.6.1, on 1.6.2 it doesn't seem to exist any difference between {EVENT.DATE} and {DATE} and the same for {EVENT.TIME}. And as bee said above, the {EVENT.AGE} macro always returns "0"...

            Here's what I use (with some mods, because of the language):

            For Alerts:

            Subject: Alert - {TRIGGER.NAME}

            Text:
            Problem: {TRIGGER.NAME}

            Service: {ITEM.NAME}
            Last received value: {{HOSTNAME}:{TRIGGER.KEY}.last(0)}

            Host: {HOSTNAME}
            IP: {IPADDRESS}

            Date/Time of event: {EVENT.DATE} at {EVENT.TIME}

            ################################################## ############################

            Subject: Recovery - {TRIGGER.NAME}

            Recovered alert: {TRIGGER.NAME}

            Date/time of problem start: {EVENT.DATE} at {EVENT.TIME}
            Date/time of problem recovery: {DATE} at {TIME}
            Problem length: {EVENT.AGE}

            Service: {ITEM.NAME}
            Last received value: {{HOSTNAME}:{TRIGGER.KEY}.last(0)}

            Host: {HOSTNAME}
            IP: {IPADDRESS}

            #################################################

            The output of the recovery (on 1.6 or 1.6.1) should be as the following:

            Date/time of problem start: 2009.02.17 at 12:08:19
            Data/time of problem recovery: 2009.02.17 at 12:16:16
            Problem length: 7m

            But on 1.6.2 the output of the first two lines simply repeat and the length of the event is always "0".

            Guess I'll be downgrading to 1.6.1...

            Regards,

            Gabriel

            Comment

            • Alexei
              Founder, CEO
              Zabbix Certified Trainer
              Zabbix Certified SpecialistZabbix Certified Professional
              • Sep 2004
              • 5654

              #7
              {EVENT.AGE} displays age of the last event. For recovery messages {EVENT.AGE} will always show '0'.

              In pre-1.6.3 we extended macro {HISTORY.LOG} so that it will display also age of the problem along with escalation details.
              Alexei Vladishev
              Creator of Zabbix, Product manager
              New York | Tokyo | Riga
              My Twitter

              Comment

              • Icenode
                Junior Member
                • Apr 2009
                • 27

                #8
                Has there been a fix/workaround/new command for this yet so recovery messages can include event duration?

                Comment

                • orionweb
                  Junior Member
                  • Feb 2010
                  • 17

                  #9
                  Request opened @ https://support.zabbix.com/browse/ZBXNEXT-252 Vote for it to be fixed / implemented.

                  Comment

                  • bashman
                    Senior Member
                    • Dec 2009
                    • 432

                    #10
                    I would like to query all the trigger's down time within a week.
                    978 Hosts / 16.901 Items / 8.703 Triggers / 44 usr / 90,59 nvps / v1.8.15

                    Comment

                    Working...