Ad Widget

Collapse

Can't get correct AND/OR combination in Action conditions

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mrbox
    Junior Member
    • Aug 2009
    • 6

    #1

    Can't get correct AND/OR combination in Action conditions

    I've tried every combination of adding the following three triggers, but nothing I do seems to help:



    What I want is "(A or C) and (B)". Can anyone help?

    Thanks.
  • zabbix_zen
    Senior Member
    • Jul 2009
    • 426

    #2
    The (AND OR) operator only works between conditions of the same type.
    Eg.

    (A OR C) AND (B OR D) AND E

    A: Trigger Description like 'Host 10'
    B: Trigger = 'Apache service down'
    C: Trigger Description like 'Host 22'
    D: Trigger = 'Web Portal unavailable'
    E: Value = 'PROBLEM'

    Comment

    • mrbox
      Junior Member
      • Aug 2009
      • 6

      #3
      Thanks for your help.

      I think the AND/OR action condition calculation should be described as follows in the documentation:
      • Conditions of the same type are grouped and OR'ed together
      • Multiple groups are AND'ed together

      The documentation is ambiguous as it doesn't address whether or not the order in which you add the action conditions has any effect:

      For example this set of conditions (calculation type: AND/OR):
      • Host group = Oracle servers
      • Host group = MySQL servers
      • Trigger name like 'Database is down'
      • Trigger name like 'Database is unavailable'

      is evaluated as

      (Host group = Oracle servers or Host group = MySQL servers) and (Trigger name like 'Database is down' or Trigger name like 'Database is unavailable')
      i.e. It's not obvious that if you added another Host group, it would not become:

      (Host group = Oracle servers or Host group = MySQL servers) and (Trigger name like 'Database is down' or Trigger name like 'Database is unavailable') and (Host group = <New Host group>)

      as opposed to the actual behaviour:

      (Host group = Oracle servers or Host group = MySQL servers or Host group = <New Host group>) and (Trigger name like 'Database is down' or Trigger name like 'Database is unavailable')

      Comment

      • zabbix_zen
        Senior Member
        • Jul 2009
        • 426

        #4
        Agreed.
        Myself, I'm not a fan of the Actions conditions setup interface, looks a little rough around the edges,
        hope they give it some love in a next subrelease.


        You can edit
        http://www.zabbix.com/documentation/...config/actions

        sending your proposed changed to Richlv (over the IRC # for example)

        Comment

        Working...