2
votes

I have been working with Magento on my localhost and everything was fine until i added a new module. now i am getting the following error: Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 261900 bytes) in /Applications/XAMPP/xamppfiles/htdocs/magento/app/Mage.php

I tried to change the memory_Limit to 512M then it generated the same errors but this time with more memory size:

Fatal error: Allowed memory size of 536870912 bytes exhausted (tried to allocate 261900 bytes) in /Applications/XAMPP/xamppfiles/htdocs/magento/app/Mage.php

Does anyone have any idea what causes this?

2

2 Answers

3
votes

Put code below to this path: /Applications/XAMPP/xamppfiles/htdocs/magento/app/Mage.php

ini_set('memory_limit', '512M');
1
votes

Most likely the extension you've installed has memory leaks in it. If you've payed for it, you should ask for an assistance from the extension developer. Otherwise, you should find the bottleneck place yourself with the help of xdebug profiler or other similar tool.

At the end, you can just disable the extension.