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

Constraint violation during trigger prototype removal

XMLWordPrintable

    • Sprint 57 (Oct 2019), Sprint 58 (Nov 2019), Sprint 59 (Dec 2019), Sprint 60 (Jan 2020)
    • 1

      If during trigger prototype removal process, new triggers will be discovered, it is possible to have the following error:

      It may happens on big installation, if some queries are not "very very fast", but theoretically on any installation.

      According PHP source code:
      1. Zabbix retrieves all discovered triggers from trigger prototypes
      2. Trying to remove linkage between discovered triggers and prototypes in trigger_discovery by triggerid column
      3. Removes quite a lot of additional information like action conditions, services and etc (linked to triggers to be removed)
      4. Removes discovered triggers
      5. Removes trigger prototype

      So if after 1 step new trigger will be discovered, it will be not removed at 2 step, but during 5th step foreign key constraint will be corrupted.

      Probably the same issue can happen for any other resources which may be discovered automatically!

        1. foreign_key_error.png
          foreign_key_error.png
          78 kB
        2. ZBX-16811.diff
          3 kB
        3. zbx_export_hosts.xml
          7 kB
        4. function-name-inconsistency.png
          function-name-inconsistency.png
          100 kB

            atumilovics Andrejs Tumilovics
            dotneft Alexey Pustovalov
            Team C
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: