You are not logged in.

Announcement

 Téléchargez la dernière version stable de GLPI      -     Et vous, que pouvez vous faire pour le projet GLPI ? :  Contribuer
 Download last stable version of GLPI                      -     What can you do for GLPI ? :  Contribute

#1 2023-10-31 10:40:37

okba6z
Member
Registered: 2018-12-13
Posts: 32

PHP Error (1): Allowed memory size of 134217728 bytes exhausted

Bonjour,

J'ai une solution GLPi en version 10.0.7
J'ai un total ticket clos avoisinant 8,9k ticket lorsque je veux voir l'ensemble de ces tickets clos via un filtre sur le status, j'ai ce message d'erreur:

PHP Error (1): Allowed memory size of 134217728 bytes exhausted (tried to allocate 733184 bytes) in /var/www/html/src/DBmysql.php at line 363
Operating system: Linux cre-vsupport1 5.10.0-21-amd64 #1 SMP Debian 5.10.162-1 (2023-01-21) x86_64
PHP 8.1.25 fpm-fcgi (Core, FFI, PDO, PDO_Firebird, PDO_ODBC, Phar, Reflection, SPL, SimpleXML, Zend OPcache, bcmath, bz2,
    calendar, cgi-fcgi, ctype, curl, date, dom, exif, fileinfo, filter, ftp, gd, gettext, hash, iconv, imagick, imap, intl, json,
    ldap, libxml, mbstring, mysqli, mysqlnd, odbc, openssl, pcre, pdo_dblib, pdo_mysql, pdo_pgsql, pdo_sqlite, pgsql, posix,
    readline, session, shmop, soap, sockets, sodium, sqlite3, standard, sysvmsg, sysvsem, sysvshm, tidy, tokenizer, xml, xmlreader,
    xmlrpc, xmlwriter, xsl, zip, zlib)

Setup: max_execution_time="30" memory_limit="128M" post_max_size="8M" safe_mode="" session.save_handler="files"
    upload_max_filesize="2M"


Software: Apache/2.4.56 (Debian) (Apache/2.4.56 (Debian) Server at XXXXXXXXXXXX Port 80
)
    Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/112.0.0.0 Safari/537.36
Server Software: Debian 11
    Server Version: 10.5.21-MariaDB-0+deb11u1
    Server SQL Mode: STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
    Parameters: admXXXX_XXXXX@localhost/db_XXXXXXXX
    Host info: Localhost via UNIX socket
   
PHP version (8.1.25) is supported.PHP version (8.1.25) is supported.
Sessions configuration is OK.Sessions configuration is OK.
Allocated memory is sufficient.Allocated memory is sufficient.
mysqli extension is installed.mysqli extension is installed.
Following extensions are installed: dom, fileinfo, json, simplexml.Following extensions are installed: dom, fileinfo, json, simplexml.
curl extension is installed.curl extension is installed.
gd extension is installed.gd extension is installed.
intl extension is installed.intl extension is installed.
libxml extension is installed.libxml extension is installed.
zlib extension is installed.zlib extension is installed.
The constant SODIUM_CRYPTO_AEAD_XCHACHA20POLY1305_IETF_NPUBBYTES is present.The constant SODIUM_CRYPTO_AEAD_XCHACHA20POLY1305_IETF_NPUBBYTES is present.
Database engine version (10.5.21) is supported.Database engine version (10.5.21) is supported.
No files from previous GLPI version detected.No files from previous GLPI version detected.
The log file has been created successfully.The log file has been created successfully.
Write access to /var/www/html/files/_cache has been validated. Write access to /var/www/html/config has been validated. Write access to /var/www/html/files/_cron has been validated. Write access to /var/www/html/files has been validated. Write access to /var/www/html/files/_dumps has been validated. Write access to /var/www/html/files/_graphs has been validated. Write access to /var/www/html/files/_lock has been validated. Write access to /var/www/html/files/_pictures has been validated. Write access to /var/www/html/files/_plugins has been validated. Write access to /var/www/html/files/_rss has been validated. Write access to /var/www/html/files/_sessions has been validated. Write access to /var/www/html/files/_tmp has been validated. Write access to /var/www/html/files/_uploads has been validated.Write access to /var/www/html/files/_cache has been validated.
Write access to /var/www/html/config has been validated.
Write access to /var/www/html/files/_cron has been validated.
Write access to /var/www/html/files has been validated.
Write access to /var/www/html/files/_dumps has been validated.
Write access to /var/www/html/files/_graphs has been validated.
Write access to /var/www/html/files/_lock has been validated.
Write access to /var/www/html/files/_pictures has been validated.
Write access to /var/www/html/files/_plugins has been validated.
Write access to /var/www/html/files/_rss has been validated.
Write access to /var/www/html/files/_sessions has been validated.
Write access to /var/www/html/files/_tmp has been validated.
Write access to /var/www/html/files/_uploads has been validated.

Web server root directory configuration seems safe.Web server root directory configuration seems safe.
PHP directive "session.cookie_httponly" should be set to "on" to prevent client-side script to access cookie values.PHP directive "session.cookie_httponly" should be set to "on" to prevent client-side script to access cookie values.
OS and PHP are relying on 64 bits integers.OS and PHP are relying on 64 bits integers.
exif extension is installed.exif extension is installed.
ldap extension is installed.ldap extension is installed.
openssl extension is installed.openssl extension is installed.
Following extensions are installed: bz2, Phar, zip.Following extensions are installed: bz2, Phar, zip.
Zend OPcache extension is installed.Zend OPcache extension is installed.
Following extensions are installed: ctype, iconv, mbstring, sodium.Following extensions are installed: ctype, iconv, mbstring, sodium.
Write access to /var/www/html/marketplace has been validated.Write access to /var/www/html/marketplace has been validated.
Timezones seems loaded in database.Timezones seems loaded in database.



Voila ce que j'ai:
xxxxx@xxxx:~# php --ini
Configuration File (php.ini) Path: /etc/php/8.2/cli
Loaded Configuration File:         /etc/php/8.2/cli/php.ini
Scan for additional .ini files in: /etc/php/8.2/cli/conf.d
Additional .ini files parsed:      /etc/php/8.2/cli/conf.d/10-mysqlnd.ini,
/etc/php/8.2/cli/conf.d/10-opcache.ini,
/etc/php/8.2/cli/conf.d/10-pdo.ini,
/etc/php/8.2/cli/conf.d/15-xml.ini,
/etc/php/8.2/cli/conf.d/20-apcu.ini,
/etc/php/8.2/cli/conf.d/20-bz2.ini,
/etc/php/8.2/cli/conf.d/20-calendar.ini,
/etc/php/8.2/cli/conf.d/20-ctype.ini,
/etc/php/8.2/cli/conf.d/20-curl.ini,
/etc/php/8.2/cli/conf.d/20-dom.ini,
/etc/php/8.2/cli/conf.d/20-exif.ini,
/etc/php/8.2/cli/conf.d/20-ffi.ini,
/etc/php/8.2/cli/conf.d/20-fileinfo.ini,
/etc/php/8.2/cli/conf.d/20-ftp.ini,
/etc/php/8.2/cli/conf.d/20-gd.ini,
/etc/php/8.2/cli/conf.d/20-gettext.ini,
/etc/php/8.2/cli/conf.d/20-iconv.ini,
/etc/php/8.2/cli/conf.d/20-imap.ini,
/etc/php/8.2/cli/conf.d/20-intl.ini,
/etc/php/8.2/cli/conf.d/20-ldap.ini,
/etc/php/8.2/cli/conf.d/20-mbstring.ini,
/etc/php/8.2/cli/conf.d/20-mysqli.ini,
/etc/php/8.2/cli/conf.d/20-pdo_mysql.ini,
/etc/php/8.2/cli/conf.d/20-phar.ini,
/etc/php/8.2/cli/conf.d/20-posix.ini,
/etc/php/8.2/cli/conf.d/20-readline.ini,
/etc/php/8.2/cli/conf.d/20-shmop.ini,
/etc/php/8.2/cli/conf.d/20-simplexml.ini,
/etc/php/8.2/cli/conf.d/20-sockets.ini,
/etc/php/8.2/cli/conf.d/20-sysvmsg.ini,
/etc/php/8.2/cli/conf.d/20-sysvsem.ini,
/etc/php/8.2/cli/conf.d/20-sysvshm.ini,
/etc/php/8.2/cli/conf.d/20-tokenizer.ini,
/etc/php/8.2/cli/conf.d/20-xmlreader.ini,
/etc/php/8.2/cli/conf.d/20-xmlrpc.ini,
/etc/php/8.2/cli/conf.d/20-xmlwriter.ini,
/etc/php/8.2/cli/conf.d/20-xsl.ini,
/etc/php/8.2/cli/conf.d/20-zip.ini
xxxxx@xxxx:~# free -m
               total       utilisé      libre     partagé tamp/cache   disponible
Mem:            7956         764        2632          67        4558        6825
Partition d'échange:        974           0         974
xxxxx@xxxx:~# php -i | grep php.ini
Configuration File (php.ini) Path => /etc/php/8.2/cli
Loaded Configuration File => /etc/php/8.2/cli/php.ini
xxxxx@xxxx:~# php -r "echo ini_get('memory_limit').PHP_EOL;"
-1


Mais comme vous pouvez le voir en haut sur le résumé de GLPI:
memory_limit="128M"
or dans mon php.ini
memory_limit="-1"

je ne comprends pas pourquoi l'instance GLPI se limite a 128M alors que la conf de mon php.ini lui impose aucune limite.

Merci d'avance de votre aide

Offline

#2 2023-10-31 10:51:09

okba6z
Member
Registered: 2018-12-13
Posts: 32

Re: PHP Error (1): Allowed memory size of 134217728 bytes exhausted

J'ai changé la conf via le fichier de conf apache:
php_value memory_limit 4096M

Mais pareil il ne prend pas en compte ma modification

Offline

#3 2023-10-31 11:54:32

okba6z
Member
Registered: 2018-12-13
Posts: 32

Re: PHP Error (1): Allowed memory size of 134217728 bytes exhausted

J'ai changé la conf via le fichier de conf apache (etc/apache2/sites-enabled/glpi.conf):
<directory ....>
php_value memory_limit 1024M
</directory>

pareil pour /etc/php/8.2/apache2/php.ini:
memory_limit=1024

Cela ne change absolument rien

Offline

#4 2023-11-08 10:38:01

jlb59
Member
From: Valenciennes
Registered: 2008-07-29
Posts: 116

Re: PHP Error (1): Allowed memory size of 134217728 bytes exhausted

Bonjour
si je me souviens pour valider les modif du php.ini il  faut utiliser systemctl restart php-fpm.service u un truc de ce genre . cordialement


REDHAT 8.6 sur ESX vmware, glpi 10.0.10, OCS 2.3.1
Plugin : Import OCSNG,  Injection de fichiers , Impression pdf , uninstal,  rapport, comportement, OAUTH.
35000 utilisateurs , 2.5 millions de tickets

Offline

Board footer

Powered by FluxBB