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

Slow graph dropdowns in "Monitoring" => "Graphs"

XMLWordPrintable

    • Icon: Incident report Incident report
    • Resolution: Duplicate
    • Icon: Major Major
    • None
    • 1.8.14

      The dropdown menus in "Monitoring" => "Graphs" were pretty slow.

      I executed "show full processlist" while the menu loads an got the following statement:

      SELECT  DISTINCT  g.* FROM groups g,hosts_groups hg,hosts h WHERE ((g.groupid  BETWEEN 100000000000000 AND 199999999999999) OR (g.groupid  BETWEEN 200000000000000 AND 299999999999999)) AND hg.groupid=g.groupid AND h.hostid=hg.hostid AND h.status=0 AND EXISTS( SELECT DISTINCT i.itemid  FROM items i, graphs_items gi  WHERE i.hostid=hg.hostid  AND i.itemid=gi.itemid);
      

      I added a index:

      CREATE INDEX graphs_items_1 ON graphs_items(itemid) USING btree; 
      

      After creating a index execution time was reduced from 5 seconds to 0.03 seconds.

      This problem is also described in the following closed bug https://support.zabbix.com/browse/ZBX-569.

            Unassigned Unassigned
            scoopex Marc Schoechlin
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: