Support » Fixing WordPress » Memory Limit Problem During Upgrade – Solution

  • I use Keith Dsouza’s excellent upgrade plugin for doing upgrades and had a nasty this morning while upgrading to 2.3

    My blog has over 1,000 posts and an 8MB PHP limit on the server. I’d already hit this before with the Google Sitemap generator and got the “Fatal error: Allowed memory size of 80000000 bytes exhausted (tried to allocate 253742 bytes)” error.

    The answer was to add (in my case)
    ini_set(“memory_limit”,”16M”);
    to various scripts.

    This memory limit also hit during the 2.3 upgrade and reported fatal errors when reactivating most of my plugins. The problem was wp-includes\cache.php which now needs ini_set.. added at the start as well. The tricky bit is you have to wait until the new php scripts have been copied in during the upgrade, patch it then continue so it has to be done manually not automatically.

Viewing 5 replies - 1 through 5 (of 5 total)
  • PS. I’m not sure of my php to say whether this is possible, but could this be considered as some kind of system wide option for a future version?

    it is dependent from host to host actually

    If your host is a linux host then try setting the php memory limit in a .htacess file in the root of your blog. You can set it by adding this.

    php_value memory_limit 16M

    Just change the 16M to whatever you like.

    I have the same problems on my home server, it gives me fatal errors when I am installing other scripts and forums too. help me to repair it plz

    From a system administrator point of view just upping the memory limit from 8 to 16M in PHP is potentially hazardous thing to do.

    You have to realize that this is 8M per child extra, almost doubling the memory usage. Those figures stack up fast if you realize that a semi-productive server easilly can have about 80 childs running. Do the math. 😉

    Unfortunately this IS the only answer for the end-user. I am sure the WordPress team can consider reviewing the code to reduce the memory burden it places on PHP installations.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Memory Limit Problem During Upgrade – Solution’ is closed to new replies.