Ad Widget

Collapse

How to get events / trigger age for certain duration?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • zabbixfk
    Senior Member
    • Jun 2013
    • 256

    #1

    How to get events / trigger age for certain duration?

    I am able to generate events between certain time and i am able to see if its PROBLEM or OK based on value on event.get. But i am not sure how to generate the age of the trigger?
    In zabbix events it shows Duration, but i am not able find something similar in API. Can someone help me here? I wanted to figure out age of the trigger states, even if its PROBLEM or OK. Like in events page it shows how long that trigger is in PROBLEM or OK state - need to query this using api.
    Any pointers greatly helpful.

    Thanks,
  • zabbixfk
    Senior Member
    • Jun 2013
    • 256

    #2
    * bump * - can someone reply to this.... I am sure this is a valid use case - to know age of a trigger ....

    Thanks,

    Comment

    • zabbixfk
      Senior Member
      • Jun 2013
      • 256

      #3
      *bump* can someone reply to this.

      Comment

      • zabbixfk
        Senior Member
        • Jun 2013
        • 256

        #4
        * bump * - can someone please reply / explain how this can be done. - atleast from zabbix dev team?
        How to obtain trigger duration / age?

        Comment

        • zabbixfk
          Senior Member
          • Jun 2013
          • 256

          #5
          *bump* - somethinh like calculating {EVENT.AGE} will also help. ANy pointers?

          Comment

          • omarsan1
            Junior Member
            • Jun 2019
            • 8

            #6
            Eu tenho problema com falhas para enviar um teste de e-mail do zabbix Peço sua ajuda não enviar e-mail zabbix O tempo limite de 3 segundos foi atingido ao tentar se conectar ao servidor Zabbix "localhost".
            Attached Files

            Comment

            • zabbixfk
              Senior Member
              • Jun 2013
              • 256

              #7
              *bump* - waiting for some pointers !!!

              Comment

              • zabbixfk
                Senior Member
                • Jun 2013
                • 256

                #8
                *bump*
                Looking for pointers on how to figure out trigger duration. How long that trigger was in that state?

                Comment

                • zabbixfk
                  Senior Member
                  • Jun 2013
                  • 256

                  #9
                  * Bump *
                  I am disappointed, no one from zabbix dev team too is responding to this thread? I tried to look at the events.php source code but could'nt get out anything.
                  Can some one help me understand how does event age is calculated? ( the one entry shown at events.php page called duration )

                  Comment

                  • vso
                    Zabbix developer
                    • Aug 2016
                    • 190

                    #10
                    Can’t you use “clock”?

                    Comment

                    • zabbixfk
                      Senior Member
                      • Jun 2013
                      • 256

                      #11
                      No, i can't use clock. Clock says at what time that event occurred, but i am looking at 'Duration' field which is displayed at events page - more like how long that trigger was in that state
                      ex: Trigger A was in Problem1 State for 3m 5s at Clock1 ,
                      then it resulted to OK1 at clock2.
                      Again Trigger A created problem 2 at clock3 (say after 2min of previous ok), then OK1 Duration becomes 2m ( something like clock3-clock2 ).

                      Thanks,

                      Comment

                      • splitek
                        Senior Member
                        • Dec 2018
                        • 101

                        #12
                        Originally posted by zabbixfk
                        In zabbix events it shows Duration, but i am not able find something similar in API. Can someone help me here? I wanted to figure out age of the trigger states, even if its PROBLEM or OK. Like in events page it shows how long that trigger is in PROBLEM or OK state - need to query this using api.
                        Any pointers greatly helpful.

                        Thanks,

                        get problem and clock value form it.
                        Next calculate by yourself: time_now - clock

                        Comment


                        • zabbixfk
                          zabbixfk commented
                          Editing a comment
                          Thanks, my server is 3.0, so can't use this.
                      • nameuser
                        Member
                        • Apr 2018
                        • 39

                        #13
                        I have same issue. How can I get event duration with event.get?
                        problem.get is not an option because this method is for retrieving unresolved problems and recently resolved problems.
                        I need to gather info about duration of resolved problems further back in the past.

                        Comment

                        Working...