Project: moodle
Issue MDL-42493: Upgrade to current 2.6beta, memory exhausted problem purging caches
Site performing this upgrade: 56cc9b3..34fb354 => 2.6dev July to current 2.6beta. Got this error: {code} PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 147 bytes) in /cache/stores/file/lib.php on line 545 PHP Stack trace: PHP 1. {main}() /admin/cli/upgrade.php:0 PHP 2. cache_helper::purge_all() /admin/cli/upgrade.php:164 PHP 3. cache_helper::purge_store() /cache/classes/helper.php:439 PHP 4. cachestore_file->purge() /cache/classes/helper.php:475 PHP 5. glob() /cache/stores/file/lib.php:545 {code} It seems that, under some circumstances, if there are many cached items… purging requires a lot of memory. Consider increasing it for all executions, not only for upgrade ones. Alternatively, perform the purging after increasing memory for upgrade. I think the former is better in general, covering any purge. Ciao :-)
Story points: 2