Ad Widget

Collapse

How should look unavailable trigger.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • pietro54
    Senior Member
    • Feb 2011
    • 112

    #1

    How should look unavailable trigger.

    Hi,
    In zabbix 2.0 I was using (internal) item
    Code:
    zabbix[host,agent,available]
    and trigger
    Code:
     {Linux:zabbix[host,agent,available].min(9)}=1
    .

    But there is a problem, this doesent work well in new zabbix 2.2

    Can some one tell how should look correct item and triger to check zabbix agentd is available?
  • pc99096
    Senior Member
    • Oct 2011
    • 193

    #2
    just use the default zabbix agent template

    item - agent.ping

    trigger (if there is no data for more than 5 minutes) - agent.ping.nodata(5m)=1

    Comment

    • pietro54
      Senior Member
      • Feb 2011
      • 112

      #3
      Hi,
      thanks, this is very helpful.

      But this is generating some false alarm on windows hosts.
      Is there any possibility to create something like this

      Zabbix server ask host are you alive: yes im alive
      Zabbix server ask host are you alive: no answer
      Zabbix server ask ... no answer
      Zabbix server ask ... no answer

      and if there 3 check one by one give no answer then trigger should to problem.

      Comment

      • pc99096
        Senior Member
        • Oct 2011
        • 193

        #4
        i am usually using icmpping instead of agent.ping


        and a trigger like icmpping.sum(#3)<1 (sum of the last 3 values)

        Comment

        • aib
          Senior Member
          • Jan 2014
          • 1615

          #5
          Originally posted by pietro54
          Hi,
          thanks, this is very helpful.

          But this is generating some false alarm on windows hosts.
          Is there any possibility to create something like this

          Zabbix server ask host are you alive: yes im alive
          Zabbix server ask host are you alive: no answer
          Zabbix server ask ... no answer
          Zabbix server ask ... no answer

          and if there 3 check one by one give no answer then trigger should to problem.
          Code:
          {hostname:agent.ping.nodata(#3)}=1
          Sincerely yours,
          Aleksey

          Comment

          • pietro54
            Senior Member
            • Feb 2011
            • 112

            #6
            Are you sure it work like you want it?
            Because it work like this:
            if in any of 3 last values was no data then trigger goes to problem.
            No meter if this was first or third value. (that's just mine opinion)

            Comment

            • steveboyson
              Senior Member
              • Jul 2013
              • 582

              #7
              nodata(#3) is the 3rd last value.

              Better use count(#3,1,"lt")
              It will count the number of values of the last 3 item calls which have less than "value=1". Is probably that what you want.

              Comment

              • pietro54
                Senior Member
                • Feb 2011
                • 112

                #8
                Yes, this sounds correctly, but i can not add trigger like this:
                {Windows :agent.ping.nodata(#3,1,"lt")}=1

                Windows is a template name.

                Comment

                • steveboyson
                  Senior Member
                  • Jul 2013
                  • 582

                  #9
                  But you can use {Windows.agent.ping.count(#3,1,"lt")}>0

                  Comment

                  • pietro54
                    Senior Member
                    • Feb 2011
                    • 112

                    #10
                    Hi,
                    I try this, but is doesn't work well...
                    Please let me understood this
                    Code:
                    agent.ping.count(#3,1,"lt")}>0
                    agent.ping.count(<numer of recived values>, <what means 1>, < what means lt>?
                    I can`t find it on https://www.zabbix.com/documentation...ers/expression

                    where do you get such knowledge?

                    Comment

                    • steveboyson
                      Senior Member
                      • Jul 2013
                      • 582

                      #11


                      Code:
                      agent.ping.count(#3,1,"lt")}>0
                      Trigger fires, if the number of values from the last 3 results which are "less than" (lt) 1 is more than 0.
                      (means: if more than "zero" value from the last three values have failed)

                      Comment

                      • pietro54
                        Senior Member
                        • Feb 2011
                        • 112

                        #12
                        But if there will be "no data".
                        no data#(value)0.

                        I mean, if host is down, server receives <no data>, so server cannot compare 1or0 to <no data>.
                        Thats how I`m thinking.
                        Last edited by pietro54; 24-03-2014, 15:22.

                        Comment

                        • steveboyson
                          Senior Member
                          • Jul 2013
                          • 582

                          #13
                          Simply add a 2nd "nodata" trigger.

                          Comment

                          • pietro54
                            Senior Member
                            • Feb 2011
                            • 112

                            #14
                            Hi,
                            Thanks for your time and patient for this thread.

                            I think it`s not thats simple.
                            If i will create something like this:
                            agent.ping.count(#3,1,"lt")}>0 | agent.ping.nodata(0)}=1
                            This trigger will generate same number of false alarms like only agent.ping.nodata(10)}=1

                            But if I will create
                            agent.ping.count(#3,1,"lt")}>0 & agent.ping.nodata(0)}=1
                            I think trigger will not work correctly.

                            trigger should implicit in one count and no data.
                            Sth like that:
                            agent.ping.count,nodata(#3,1,"lt")}>0

                            Comment

                            • steveboyson
                              Senior Member
                              • Jul 2013
                              • 582

                              #15
                              Originally posted by steveboyson
                              Simply add a 2nd "nodata" trigger.
                              "A 2nd trigger" means a 2nd trigger. Not one trigger with two statements, combined by "|" or "&" ...

                              Comment

                              Working...