Confused Development

I develop software and I often get confused in the process. I usually find the answers after a while, but a month later I can't remember them. So from now on, I will write them down here.

Monday, October 08, 2007

WordPress install.php not showing

Although, judging by the time that has passed since my last post, it may appear I'm no longer confused, this is not true. I'm constantly confused, about everything. In fact, just today I tried to install WordPress 2.3 on a virtual server here at DERI, and was very confused when the setup php script didn't run (.../blog/wp-admin/install.php). The browser didn't show any error message, but instead just a blank page. After a while of scratching my head I decided to look at the httpd error logs (always a good idea in such situations, I guess), and found this:
$ sudo tail /etc/httpd/logs/error_log
...
[client 10.2.18.50] PHP Fatal error:  Allowed memory size of 8388608 bytes exhausted (tried to allocate 233472 bytes) in /var/www/html/blog/wp-admin/includes/schema.php on line 107
Allowed memory size of 8388608 bytes exhausted (tried to allocate 0 bytes)
Aha! Some memory problem. So, googling for "PHP Fatal error: Allowed memory size of" quickly brought me to this page, which had the solution: just increase the allowed memory size for PHP scripts from the default 8MB to something higher (e.g. 12MB). This can either be done at the top of the culprit script itself (didn't work for me):
ini_set("memory_limit","12M");
or in /etc/php.ini (or wherever your php.ini is):
memory_limit = 12M
Perfect. After fixing this, the installation ran smoothly.

7 Comments:

At 8:15 pm, Blogger carotids said...

I am glad that we could help. Good luck with wordpress and php. Thanks for linking into us. :)

 
At 9:38 pm, Blogger nonzero said...

Thanks. Fixed my problem.

 
At 5:54 pm, Blogger queryamit said...

thanks a lot , i had this problem from a months , i have taken hosting plan from reddiff . same problem i had and the customer service is too bad even they listed for wordpress support and lol lastly i got solution after google . now its time to give customer service a full detail .. thanks a lot

 
At 1:33 am, Blogger Unknown said...

i changed the php.ini memory from default 128M up to 512M (surely more than enough) and no results. any suggestions? (that you can email me in case i forget to come back here?) thanks

 
At 12:11 pm, Blogger queryamit said...

php_value memory_limit 32M

just copy and paste above line on .htaccess file , the wordpress installation problem or memory problem will be solved , if any problem mail me queryamit@gmail.com

 
At 5:38 am, Blogger Unknown said...

hello!

I have IIS7, windows 7, php 5.3 and WP 3.

../wp-admin/install.php is just showing a blank page. the memory limit is already 512MB. Any idea how to troubleshoot this?

please please help. php is running because i've put 'hello world' on my phpinfo and i can see 'hello world' on my browser (chrome). I can also see mysql in phpinfo().

 
At 3:32 pm, Blogger Knud Möller said...

Hi Chavz, I have no experience with installing WordPress on Windows. However, I suggest you find the error log for your server and see if anything is showing up there. This way you will have an indication what causes the problem, and will be able to google for the problem, or ask on a forum.

Good luck!

 

Post a Comment

<< Home