Blank page displayed after installing Magento Commerce
Posted 18 March 2009 by Russ in Ecommerce. Tags: Magento Commerce, MAMP.
Magento needs a decent PHP memory allocation to run and if it’s too low, you simply get a blank page in your browser. The fix is simple…
When installing Magento Commerce for the first time on OS X Leopard 10.5.6 I came up against a problem that seems fairly common in the community forums. The installation process ran smoothly but when it had completed and I called up either the front end or the admin interface, I got a blank page. No errors, no messages, nada.
With a little bit more digging around in the forums (by the way does anybody else find it frustrating that the forum search results show the same summary over and over again for in search results?!?) and a few dead-ends, I tracked the problem down to a PHP memory issue.
I’m running MAMP PRO which runs great on my Mac and made things far easier when I was trying to sort out the LAMP environment that comes with Leopard out of the box. However by default, the memory set in the PHP 5 template is too low for Magento Commerce to run and this was being reported in the PHP log (Log > PHP in the menu bar) in MAMP:
[18-Mar-2009 08:25:33] PHP Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 19456 bytes) in /Users/russ_back/Sites/magentocommerce.com/httpdocs/app/design/frontend/blank/default/template/page/2columns-right.phtml on line 55
As it turns out, this is an easy fix in MAMP and goes something like this. I’m assuming you’re using PHP5:
- Open up MAMP Pro (or open your php5.ini file if you’re not using MAMP and skip to step 3).
- Go to File > Edit Template > PHP5 php.ini (or hit cmd 4 if you’re after a shortcut). You may see a warning message but what we’re going to do is minor so you can read it and clear it for now.
- Search for the “memory_limit” in the file and if you’ve never changed this, you may find it showing as 8M, which is 8Mb and too low for Magento Commerce.
- Change this value to 16M – which is what Magento requires as a minimum – or preferably something higher, like 64M.
- Hit File > Save and close the file.
- Restart the Apache server (as simple as hitting the Stop and WebStart buttons in MAMP Pro) and then revisit your Magento location (mine’s at local.magentocommerce.com) and hit the refresh button of your browser
- Wham! You’re done and Magento Commerce should be up and running



Dimaz
11. Nov, 2009
Hi, I still got a blank page on Admin section…
my memory_limit = 128
MAMP
Mac OS X Leopard
Geez, all i want to do is try out a template.
Standard installation was ok though.