Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-22874

Trigger expression for "and not" not correspond expected behavior

XMLWordPrintable

    • Sprint 101 (Jun 2023)
    • 0.25

      Hello.

      Our expectation that trigger expression with "and not" for these two cases will provide us the same result:

      1) and not dayofweek()=6 and not dayofweek()=7

      2) and not (dayofweek()=6 and dayofweek()=7)

      First expression not work. Second work correctly.

      There is no documentation for this case.

      Only https://www.zabbix.com/documentation/current/en/manual/config/triggers/expression

      with explanation:

      "notand and or operators are case-sensitive and must be in lowercase. They also must be surrounded by spaces or parentheses."

      Looks like parentheses is mandatory. Not "spaces or parentheses." -> "spaces and parentheses".

      This mistake caused incident unfortunately. Please see attachment for example.

        1. image_2023-05-31_12-07-06.png
          22 kB
          Egor T.
        2. image-2023-06-05-07-20-54-849.png
          19 kB
          Egor T.
        3. image-2023-06-05-07-21-58-386.png
          17 kB
          Egor T.
        4. not-sunday-not-saturday_not_working.png
          348 kB
          Aigars Kadikis
        5. not-sunday-not-saturday_working.png
          303 kB
          Aigars Kadikis

            martins-v Martins Valkovskis
            etix Egor T.
            Team D
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: