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

3.2 to 3.4 update very slow on large events table (inoptimal DB usage)

    Details

    • Team:
      Team C
    • Sprint:
      Sprint 20, Sprint 21
    • Story Points:
      2

      Description

      At some point of the database upgrade from 3.2 to 3.4, Zabbix Server starts running queries like that for each event ID:

      update alerts set p_eventid=53850802 where eventid=53850827

      While there is only ~60K records in alerts table, update takes hours because it runs queries for all the 87 million event IDs one by one (99+% of which do not exist in alerts table at all).

      Batching this update using some JOIN query would do much good there. If impossible, then preloading alerts table as well and updating only really affected alerts would be sane.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                s.paskevics Sergejs Paskevics
                Reporter:
                Alex/AT Alexey Asemov
              • Votes:
                0 Vote for this issue
                Watchers:
                7 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: