We’re using a shared server (on RackSpace) for Magento development. Each developer has his own sandbox, but PHP’s memory_limit = 512M and when I try to inspect some objects [with Mage::log($someBigArray)], I get failures, and Apache logs this:
[Mon Jan 23 15:47:35 2012] [error] [client 208.247.73.130] PHP Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 228065281 bytes) in /home/msmith/projects/ref/app/Mage.php on line 761, referer: http://ref.msmith.mage.example.com/checkout/cart/
My boss wants to increase the memory so that we can do this kind of logging. Currently we only have three developers on the box, but we want to be able to increase up to 15. How much memory would be appropriate to set for memory_limit in php.ini to support that many developers on a shared server?
As much as you can, although 15 developers aren’t that many if you consider the amount of traffic you’ll be bringing to your store once you launch
All the memory in the world won’t fix your
Allowed memory size of 268435456 bytes exhaustederror. These errors crop up when PHP encounters circular recursive links between objects and keeps spooling infinite string representations into memory. Magento has a lot of these circular references.