glpi-project / glpi

GLPI is a Free Asset and IT Management Software package, Data center management, ITIL Service Desk, licenses tracking and software auditing.
https://glpi-project.org
GNU General Public License v3.0
4.23k stars 1.29k forks source link

GenericObject Plugin makes very slow GLPI UI with Many object types #17905

Closed elmotofan closed 1 month ago

elmotofan commented 1 month ago

Code of Conduct

Is there an existing issue for this?

Version

10.0.15

Bug description

Hi, We are using GenericObject plugin as part of Biomedical Inventory. So, we have 150 types of different medical equipments. but we found a very slow performance in dashboards pages like inventory, personal view, global view, or tickets with minidash enabled.

After enabled bug mode, we saw too many request with these queries:

SELECT * FROM glpi_plugin_genericobject_typefamilies WHERE glpi_plugin_genericobject_typefamilies.id = '7' LIMIT 1

SELECT glpi_plugin_genericobject_typefamilies.*, '' AS transname, '' AS transcomment FROM glpi_plugin_genericobject_typefamilies WHERE glpi_plugin_genericobject_typefamilies.id = '7'

and we believe that is causing the slow performance. If we deactivate the plug-in, that’s request are no present while we browse in pages of GLPi menus.

With plugin enabled: image

Without plug-in

image

Is there some reason that make that’s queries? All items in the plug-in has all integrations enabled (service, reserve, history)

image

Relevant log output

No response

Page URL

https://glpi_url/front/central.php

Steps To reproduce

1-access GLPI base url 2- navigate on dashboard, personal view, global view

Your GLPI setup information

Información sobre la instalación y configuración del sistema
GLPI 10.0.15 ( => /var/www/HIprd/glpi)
Installation mode: TARBALL
Current language:es_AR

Server
 
Operating system: Linux ITARMGLPI01 5.14.0-427.16.1.el9_4.x86_64 #​1 SMP PREEMPT_DYNAMIC Wed May 8 17:48:14 UTC 2024 x86_64
PHP 8.3.7 fpm-fcgi (Core, PDO, Phar, Reflection, SPL, SimpleXML, Zend OPcache, bz2, calendar, cgi-fcgi, ctype, curl, date, dom,
    exif, fileinfo, filter, ftp, gd, gettext, hash, iconv, igbinary, intl, json, ldap, libxml, mbstring, msgpack, mysqli, mysqlnd,
    openssl, pcre, pdo_mysql, pdo_sqlite, random, redis, session, sockets, sodium, sqlite3, standard, tokenizer, xml, xmlreader,
    xmlwriter, xsl, zip, zlib)
Setup: max_execution_time="360" memory_limit="8092M" post_max_size="64M" safe_mode="" session.save_handler="files"
    upload_max_filesize="64M" disable_functions="" 
Software: Apache/2.4.57 (Rocky Linux) OpenSSL/3.0.7 ()
    Mozilla/5.0 (iPhone; CPU iPhone OS 17_6_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.6 Mobile/15E148 Safari/604.1
Server Software: MariaDB Server
    Server Version: 10.5.22-MariaDB-log
    Server SQL Mode: STRICT_TRANS_TABLES,NO_ENGINE_SUBSTITUTION
    Parameters: adminglpi@localhost/glpi_prd
    Host info: Localhost via UNIX socket

PHP version (8.3.7) is supported.
Sessions configuration is OK.
Allocated memory is sufficient.
mysqli extension is installed.
Following extensions are installed: dom, fileinfo, filter, libxml, json, simplexml, xmlreader, xmlwriter.
curl extension is installed.
gd extension is installed.
intl extension is installed.
zlib extension is installed.
The constant SODIUM_CRYPTO_AEAD_XCHACHA20POLY1305_IETF_NPUBBYTES is present.
Database engine version (10.5.22) is supported.
No files from previous GLPI version detected.
The log file has been created successfully.
Write access to /var/www/HIprd/glpi/../files/_cache has been validated.
Write access to /var/www/HIprd/glpi/../files/_cron has been validated.
Write access to /var/www/HIprd/glpi/../files has been validated.
Write access to /var/www/HIprd/glpi/../files/_dumps has been validated.
Write access to /var/www/HIprd/glpi/../files/_graphs has been validated.
Write access to /var/www/HIprd/glpi/../files/_lock has been validated.
Write access to /var/www/HIprd/glpi/../files/_pictures has been validated.
Write access to /var/www/HIprd/glpi/../files/_plugins has been validated.
Write access to /var/www/HIprd/glpi/../files/_rss has been validated.
Write access to /var/www/HIprd/glpi/../files/_sessions has been validated.
Write access to /var/www/HIprd/glpi/../files/_tmp has been validated.
Write access to /var/www/HIprd/glpi/../files/_uploads has been validated.
SELinux configuration is OK.

Web server root directory configuration seems safe.
Sessions configuration is secured.
OS and PHP are relying on 64 bits integers.
exif extension is installed.
ldap extension is installed.
openssl extension is installed.
Following extensions are installed: bz2, Phar, zip.
Zend OPcache extension is installed.
Following extensions are installed: ctype, iconv, mbstring, sodium.
Write access to /var/www/HIprd/glpi/marketplace has been validated.
Timezones seems loaded in database.

GLPI constants
 
GLPI_ROOT: "/var/www/HIprd/glpi"
GLPI_CONFIG_DIR: "/var/www/HIprd/glpi/../config"
GLPI_VAR_DIR: "/var/www/HIprd/glpi/../files"
GLPI_MARKETPLACE_DIR: "/var/www/HIprd/glpi/marketplace"
GLPI_USE_CSRF_CHECK: "1"
GLPI_CSRF_EXPIRES: "7200"
GLPI_CSRF_MAX_TOKENS: "100"
GLPI_USE_IDOR_CHECK: "1"
GLPI_IDOR_EXPIRES: "7200"
GLPI_ALLOW_IFRAME_IN_RICH_TEXT: false
GLPI_SERVERSIDE_URL_ALLOWLIST: ["/^(https?|feed):\\/\\/[^@:]+(\\/.*)?$/"]
GLPI_TELEMETRY_URI: "https://telemetry.glpi-project.org"
GLPI_INSTALL_MODE: "TARBALL"
GLPI_NETWORK_MAIL: "glpi@teclib.com"
GLPI_NETWORK_SERVICES: "https://services.glpi-network.com"
GLPI_MARKETPLACE_ALLOW_OVERRIDE: true
GLPI_MARKETPLACE_MANUAL_DOWNLOADS: true
GLPI_USER_AGENT_EXTRA_COMMENTS: ""
GLPI_DISABLE_ONLY_FULL_GROUP_BY_SQL_MODE: "1"
GLPI_AJAX_DASHBOARD: "1"
GLPI_CALDAV_IMPORT_STATE: 0
GLPI_DEMO_MODE: "0"
GLPI_CENTRAL_WARNINGS: "1"
GLPI_TEXT_MAXSIZE: "4000"
GLPI_DOC_DIR: "/var/www/HIprd/glpi/../files"
GLPI_CACHE_DIR: "/var/www/HIprd/glpi/../files/_cache"
GLPI_CRON_DIR: "/var/www/HIprd/glpi/../files/_cron"
GLPI_DUMP_DIR: "/var/www/HIprd/glpi/../files/_dumps"
GLPI_GRAPH_DIR: "/var/www/HIprd/glpi/../files/_graphs"
GLPI_LOCAL_I18N_DIR: "/var/www/HIprd/glpi/../files/_locales"
GLPI_LOCK_DIR: "/var/www/HIprd/glpi/../files/_lock"
GLPI_LOG_DIR: "/var/www/HIprd/glpi/../files/_log"
GLPI_PICTURE_DIR: "/var/www/HIprd/glpi/../files/_pictures"
GLPI_PLUGIN_DOC_DIR: "/var/www/HIprd/glpi/../files/_plugins"
GLPI_RSS_DIR: "/var/www/HIprd/glpi/../files/_rss"
GLPI_SESSION_DIR: "/var/www/HIprd/glpi/../files/_sessions"
GLPI_TMP_DIR: "/var/www/HIprd/glpi/../files/_tmp"
GLPI_UPLOAD_DIR: "/var/www/HIprd/glpi/../files/_uploads"
GLPI_INVENTORY_DIR: "/var/www/HIprd/glpi/../files/_inventories"
GLPI_NETWORK_REGISTRATION_API_URL: "https://services.glpi-network.com/api/registration/"
GLPI_MARKETPLACE_PLUGINS_API_URI: "https://services.glpi-network.com/api/marketplace/"
GLPI_I18N_DIR: "/var/www/HIprd/glpi/locales"
GLPI_VERSION: "10.0.15"
GLPI_SCHEMA_VERSION: "10.0.15@2eed74704cb07e0bac48b933cbd5c1c356f09629"
GLPI_MARKETPLACE_PRERELEASES: false
GLPI_MIN_PHP: "7.4.0"
GLPI_MAX_PHP: "8.4.0"
GLPI_YEAR: "2024"

Libraries
 
htmlawed/htmlawed version 1.2.14 in (/var/www/HIprd/glpi/vendor/htmlawed/htmlawed)
phpmailer/phpmailer version 6.8.0 in (/var/www/HIprd/glpi/vendor/phpmailer/phpmailer/src)
simplepie/simplepie version 1.5.8 in (/var/www/HIprd/glpi/vendor/simplepie/simplepie/library)
tecnickcom/tcpdf version 6.7.5 in (/var/www/HIprd/glpi/vendor/tecnickcom/tcpdf)
michelf/php-markdown in (/var/www/HIprd/glpi/vendor/michelf/php-markdown/Michelf)
true/punycode in (/var/www/HIprd/glpi/vendor/true/punycode/src)
iamcal/lib_autolink in (/var/www/HIprd/glpi/vendor/iamcal/lib_autolink)
sabre/dav in (/var/www/HIprd/glpi/vendor/sabre/dav/lib/DAV)
sabre/http in (/var/www/HIprd/glpi/vendor/sabre/http/lib)
sabre/uri in (/var/www/HIprd/glpi/vendor/sabre/uri/lib)
sabre/vobject in (/var/www/HIprd/glpi/vendor/sabre/vobject/lib)
laminas/laminas-i18n in (/var/www/HIprd/glpi/vendor/laminas/laminas-i18n/src)
laminas/laminas-servicemanager in (/var/www/HIprd/glpi/vendor/laminas/laminas-servicemanager/src)
monolog/monolog in (/var/www/HIprd/glpi/vendor/monolog/monolog/src/Monolog)
sebastian/diff in (/var/www/HIprd/glpi/vendor/sebastian/diff/src)
donatj/phpuseragentparser in (/var/www/HIprd/glpi/vendor/donatj/phpuseragentparser/src/UserAgent)
elvanto/litemoji in (/var/www/HIprd/glpi/vendor/elvanto/litemoji/src)
symfony/console in (/var/www/HIprd/glpi/vendor/symfony/console)
scssphp/scssphp in (/var/www/HIprd/glpi/vendor/scssphp/scssphp/src)
laminas/laminas-mail in (/var/www/HIprd/glpi/vendor/laminas/laminas-mail/src/Protocol)
laminas/laminas-mime in (/var/www/HIprd/glpi/vendor/laminas/laminas-mime/src)
rlanvin/php-rrule in (/var/www/HIprd/glpi/vendor/rlanvin/php-rrule/src)
ramsey/uuid in (/var/www/HIprd/glpi/vendor/ramsey/uuid/src)
psr/log in (/var/www/HIprd/glpi/vendor/psr/log/Psr/Log)
psr/simple-cache in (/var/www/HIprd/glpi/vendor/psr/simple-cache/src)
psr/cache in (/var/www/HIprd/glpi/vendor/psr/cache/src)
league/csv in (/var/www/HIprd/glpi/vendor/league/csv/src)
mexitek/phpcolors in (/var/www/HIprd/glpi/vendor/mexitek/phpcolors/src/Mexitek/PHPColors)
guzzlehttp/guzzle in (/var/www/HIprd/glpi/vendor/guzzlehttp/guzzle/src)
guzzlehttp/psr7 in (/var/www/HIprd/glpi/vendor/guzzlehttp/psr7/src)
glpi-project/inventory_format in (/var/www/HIprd/glpi/vendor/glpi-project/inventory_format/lib/php)
wapmorgan/unified-archive in (/var/www/HIprd/glpi/vendor/wapmorgan/unified-archive/src)
paragonie/sodium_compat in (/var/www/HIprd/glpi/vendor/paragonie/sodium_compat/src)
symfony/cache in (/var/www/HIprd/glpi/vendor/symfony/cache)
html2text/html2text in (/var/www/HIprd/glpi/vendor/html2text/html2text/src)
symfony/css-selector in (/var/www/HIprd/glpi/vendor/symfony/css-selector)
symfony/dom-crawler in (/var/www/HIprd/glpi/vendor/symfony/dom-crawler)
twig/twig in (/var/www/HIprd/glpi/vendor/twig/twig/src)
twig/string-extra in (/var/www/HIprd/glpi/vendor/twig/string-extra)
symfony/polyfill-ctype not found
symfony/polyfill-iconv not found
symfony/polyfill-mbstring not found
symfony/polyfill-php80 not found
symfony/polyfill-php81 not found
symfony/polyfill-php82 in (/var/www/HIprd/glpi/vendor/symfony/polyfill-php82)
league/oauth2-client in (/var/www/HIprd/glpi/vendor/league/oauth2-client/src/Provider)
league/oauth2-google in (/var/www/HIprd/glpi/vendor/league/oauth2-google/src/Provider)
thenetworg/oauth2-azure in (/var/www/HIprd/glpi/vendor/thenetworg/oauth2-azure/src/Provider)

LDAP directories
 
Server: '192.168.250.22', Port: '389', BaseDN: 'ou=hospital-italiano,dc=hospital-italiano,dc=local', Connection filter:
        '(&(objectClass=user)(objectCategory=person)(!(userAccountControl:1.2.840.113556.1.4.803:=2)))', RootDN:
        'cn=administrador,cn=users,dc=hospital-italiano,dc=local', Use TLS: none

SQL replicas
 
Not active

Notifications
 
Way of sending emails: SMTP+TLS (glpi.mail@hospital-italiano.org.ar@smtp.hospital-italiano.org.ar)

Plugins list
 
    fields               Name: Additional fields              Version: 1.21.8     State: Enabled                                 
        Install Method: Manual
    genericobject        Name: Administración de Objetos      Version: 2.14.10    State: Installed / not activated               
        Install Method: Marketplace
    advanceddashboard    Name: advanceddashboard              Version: 1.5.1      State: Enabled                                 
        Install Method: Manual
    advancedplanning     Name: advancedplanning               Version: 1.1.0      State: Enabled                                 
        Install Method: Marketplace
    barcode              Name: Barcode                        Version: 2.7.1      State: Installed / not activated               
        Install Method: Marketplace
    branding             Name: Branding                       Version: 1.4.0      State: Enabled                                 
        Install Method: Manual
    camerainput          Name: Camera Input                   Version: 2.1.0      State: Installed / not activated               
        Install Method: Marketplace
    printercounters      Name: Contador de impresion          Version: 2.0.1      State: Enabled                                 
        Install Method: Marketplace
    escalade             Name: Escalation                     Version: 2.9.8      State: Enabled                                 
        Install Method: Marketplace
    formcreator          Name: Form Creator                   Version: 2.13.9     State: Enabled                                 
        Install Method: Manual
    datainjection        Name: Inyección de datos             Version: 2.13.5     State: Not installed                           
        Install Method: Marketplace
    satisfaction         Name: More satisfaction              Version: 1.6.2      State: Enabled                                 
        Install Method: Marketplace
    localeoverride       Name: Rename GLPI strings            Version: 1.1.7      State: Enabled                                 
        Install Method: Manual

Anything else?

No response

trasher commented 1 month ago

This issue is related to a plugin, please report it plugin side.

elmotofan commented 1 month ago

Hi, In the repo of plugin GenericObject says that only can be reported security issues. To get support need to have a suscription to Teclib. That is correct?

image

cedric-anne commented 1 month ago

Hi, In the repo of plugin GenericObject says that only can be reported security issues. To get support need to have a suscription to Teclib. That is correct?

image

You can get community support on forums.