I am unable to delete multiple records from my suitecrm custom module. It gives error:
Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 32 bytes) in /modules/AOD_Index/Lib/Zend/Search/Lucene/Storage/File.php on line 194
I have searched for a solution for the error wherein it said to increase the PHP file upload limit & memory size, I have increased the PHP limits, however, its still a no go.
I was getting error to import the records, Error 503 Timed Out, as well wherein it suggested to disable the AOD settings post which the import works.
Please advice how to resolve the multiple delete issue.
I work via MSACCESS2013 ( if Local SuiteCRM) , then ODBC ,select LINK, select tables, etc etc and then you can make query and Updatequery or delete whatever.
William.
What Petrovils said about accessing the database in Windows, can also be done in Linux via phpMyAdmin. I don’t know which system you’re running.
Your original error seems strange to me. The AOD Indexer is using up 583Mb of RAM. I wonder if it’s going in an endless loop or something. Do you have a huge database? Are you trying a huge delete operation?
this is your php process is running out of allowed memory, change your php.ini file and set memory_limit to 1024MB just for that purpose, then change back to the original value, of course you need to restart you apache service after each modification.
Thank You for the suggestions. No, I am not deleting a huge data, about 100 records, I have tried to increase php limit to 1024 MB, but its still a no go. Any another suggestions I can try?
i’m pretty sure that you’re not modifying your setting correctly, please look again. Remember that there are many php.ini files you can modify and also depends on the OS that you have.
Yes, Mike is right, I have 3 php.ini files in my system! Only one of them counts!
Anyway, you can check if the error you’re getting now reflects the increased limit or not.
As a different route altogether, you could try deleting the AOD Lucene Index, and do your operations. The Index will eventually be rebuilt. There are posts online explaining how to do this. But this could be overkill, especially if you have a large database. Make sure you have a backup before attempting it, also.
// Reporting E_NOTICE can be good too (to report uninitialized
// variables or catch variable name misspellings …)
error_reporting(E_ERROR | E_WARNING | E_PARSE | E_NOTICE);
// Report all errors except E_NOTICE
// This is the default value set in php.ini
error_reporting(E_ALL ^ E_NOTICE);
// Report all PHP errors (see changelog)
error_reporting(E_ALL);
// Report all PHP errors
error_reporting(-1);
// Same as error_reporting(E_ALL);
ini_set(‘error_reporting’, E_ALL);
Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 32 bytes) in /modules/AOD_Index/Lib/Zend/Search/Lucene/Storage/File.php on line 194
Now that you changed the memory limit to 1024MB and restarted Apache, does the number in the error change?
Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 32 bytes) in /modules/AOD_Index/Lib/Zend/Search/Lucene/Storage/File.php on line 194
I checked the code on that line 194 and I can’t say why it’s breaking there, but for me, it suggests two directions of investigation: the size of the AOD files, and any strange behaviors caused by PHP versions / bugs.