Page 1 of 1

mysql.php exhausts memory

Posted: Wed May 08, 2019 6:41 am
by Keep_It_Simple
hi i have an issue with a joomla site using version 1.5.25 site worked fine suddenly started to give a fatal error now blocking the site. which leaded to a high CPU usage. no change were made except adding articles.

here the FPA report.
Forum Post Assistant (v1.4.8 (koine)) : 8th May 2019 wrote:
Problem Description :: wrote:mysql.php will consume some bites more than memory limit
Log/Error Message :: wrote:[16-Jun-2013 10:56:08 Africa/Casablanca] PHP Fatal error: Out of memory (allocated 42467328) (tried to allocate 78 bytes) in ....../libraries/joomla/database/database/mysql.php on line 462
Last PHP Error(s) Reported :: wrote:[08-May-2019 05:00:01 Africa/Casablanca] PHP Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 76 bytes) in ......../libraries/joomla/database/database/mysql.php on line 464
Actions Taken To Resolve wrote:memory size upgrade to 256M same what ever memory size i put the mysql.php script will consume it plus 25~74 bytes more. changed php version from 5.3 up to php7 same uninstall/reinstall extension same. when accessing com_view login page works and the backend works fine
Basic Environment :: wrote:Joomla! Instance :: Joomla! 1.5.25-Stable (senu takaa ama mamni) 14-November-2011
Joomla! Configured :: Yes | Read-Only (444) | Owner: --protected-- . (uid: 1/gid: 1) | Group: --protected-- (gid: 1) | Valid For: 1.6
Configuration Options :: Offline: true | SEF: true | SEF Suffix: true | SEF ReWrite: true | .htaccess/web.config: Yes | GZip: true | Cache: false | CacheTime: 15 | CacheHandler: file | CachePlatformPrefix: N/A | FTP Layer: false | Proxy: N/A | LiveSite: | Session lifetime: 15 | Session handler: database | Shared sessions: N/A | SSL: 2 | Error Reporting: 7 | Site Debug: false | Language Debug: false | Default Access: N/A | Unicode Slugs: N/A | dbConnection Type: mysql | PHP Supports J! 1.5.25: No | Database Supports J! 1.5.25: Yes | Database Credentials Present: Yes |

Host Configuration :: OS: Linux | **** | Encoding: gzip, deflate, br | Doc Root: --protected-- | System TMP Writable: Yes |

PHP Configuration :: Version: 5.4.45 | PHP API: litespeed | Session Path Writable: Yes | Display Errors: 1 | Error Reporting: 24567 | Log Errors To: error_log | Last Known Error: 08th May 2019 05:00:01. | Register Globals: | Magic Quotes: | Safe Mode: |***** | Uploads: 1 | Max. Upload Size: 20M | Max. POST Size: 32M | Max. Input Time: 60 | Max. Execution Time: 240 | Memory Limit: 128M

Database Configuration :: Version: 10.1.39-MariaDB (Client:10.1.39-MariaDB) | Host: --protected-- (--protected--) | default Collation: latin1_swedish_ci (default Character Set: latin1) | Database Size: 17.40 MiB | #of Tables: 55
Detailed Environment :: wrote:PHP Extensions :: Core (5.4.45) | date (5.4.45) | ereg () | libxml () | openssl () | pcre () | sqlite3 (0.7) | zlib (2.0) | bz2 () | calendar () | ctype () | curl () | hash (1.0) | filter (0.11.0) | ftp () | gettext () | gmp () | SPL (0.2) | iconv () | pcntl () | readline (5.4.45) | Reflection ($Id: f6367cdb4e3f392af4a6d441a6641de87c2e50c4 $) | session () | standard (5.4.45) | shmop () | SimpleXML (0.1) | mbstring () | tokenizer (0.1) | xml () | litespeed () | apc (3.1.13) | pspell () | mysql (1.0) | mysqli (0.1) | bcmath () | imap () | snmp (0.1) | soap () | dom (20031129) | xmlreader (0.1) | json (1.2.1) | xmlrpc (0.51) | PDO (1.0.4dev) | xmlwriter (0.1) | xsl (0.1) | pdo_mysql (1.0.2) | gd () | suhosin (0.9.38) | exif (1.4 $Id: 05041c5f0094cb46d9b516bd624d593b90cc38f9 $) | mcrypt () | pdo_sqlite (1.0.1) | zip (1.11.0) | posix () | tidy (2.0) | mhash () | ionCube Loader () | Zend Engine (2.4.0) |
Potential Missing Extensions ::
Disabled Functions :: show_source | system | shell_exec | passthru | exec | popen | proc_open | allow_url_fopen | symlink |

Switch User Environment (Experimental) :: PHP CGI: No | Server SU: No | PHP SU: No | Custom SU (LiteSpeed/Cloud/Grid): Yes
Potential Ownership Issues: No
Folder Permissions :: wrote:Core Folders :: images/ (755) | components/ (755) | modules/ (755) | plugins/ (755) | language/ (755) | templates/ (755) | cache/ (755) | logs/ (755) | tmp/ (755) | administrator/components/ (755) | administrator/modules/ (755) | administrator/language/ (755) | administrator/templates/ (755) | administrator/logs/ (---) |

Elevated Permissions (First 10) ::

Re: mysql.php exhausts memory

Posted: Sun May 12, 2019 12:25 am
by AMurray
There's a lot of wrong stuff here. To say the least, obsolete PHP (5.4 ceased support in 2015 - https://www.php.net/eol.php), obsolete Joomla (1.5 last release in 2012 - https://downloads.joomla.org/cms/joomla15) etc.

To fix the memory problem, you probably have to ask your host to increase the memory limit or simply change the setting either in cPanel (or similar hosting system) or in the php.ini file directly.

I don't know that I'd bother trying to fix such an old site running on out of date server software, and rather focus on getting the site upgraded to Joomla 3.9.6, given you have the ability to use PHP 7.
Actions Taken To Resolve wrote:
memory size upgrade to 256M same what ever memory size i put the mysql.php script will consume it plus 25~74 bytes more. changed php version from 5.3 up to php7 same uninstall/reinstall extension same. when accessing com_view login page works and the backend works fine
(1) Not sure you're putting the memory limit setting in the right file; normally you'd just set that in php.ini.
(2) Joomla 1.5 won't run on PHP 7....

Re: mysql.php exhausts memory

Posted: Sun May 12, 2019 8:03 am
by Per Yngve Berg
Upgrade to 1.5.26 as a start.
https://downloads.joomla.org/cms/joomla ... format=zip


J1.5 is updated by unzipping the file, upload and overwrite all files.