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

Slow screens with a lot of graphs for non-Super-Admins

XMLWordPrintable

    • Icon: Incident report Incident report
    • Resolution: Fixed
    • Icon: Major Major
    • 1.8.14rc1
    • 1.8.13rc1
    • Frontend (F)
    • MySQL on SSD Vertex 3, nginx with php-fpm.

      For example we have:
      hosts - 254
      items - 131523
      triggers - 13537
      functions - 26007
      graphs - 82893
      graphs_items - 495851
      groups - 11
      hosts_groups - 554
      rights - 3
      screens - 899
      screens_items - 16182
      trigger_depends - 0
      users_groups - 4
      usrgrs - 20

      Web-interface spent about 1 sec for SQL queries, but screens page opened very slow (about 120 seconds). See debug.log.

      I found source code block where web-interface spent this time (CScreen->get()). It is comparing two hashes for excluding unavailable graphs for this user:
      // graph

      foreach($restr_graphs as $resourceid){
      foreach($screens_items as $screen_itemid => $screen_item){
      if(($screen_item['resourceid'] == $resourceid) && ($screen_item['resourcetype'] == SCREEN_RESOURCE_GRAPH))

      { unset($result[$screen_item['screenid']]); unset($screens_items[$screen_itemid]); }

      }
      }

      I suppose this problem might happen for other screen elements too. For example, simple graphs.

      Mysql dump for test lab is available.

        1. debug.log
          36 kB
          Alexey Pustovalov

            Unassigned Unassigned
            dotneft Alexey Pustovalov
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: