Support » Fixing WordPress » exhausted memory

  • I have been reading through the support threads, but it is still unclear exactly how to fix this memory issue. Let me explain my sites issue.

    A while back recived an error stating that my 8Mb memory alloocation was not enough, so I aske my host to increase this to 16Mb for php and everything worked fine until today.

    I decided to add a table from word into my post for today. Once I pressed save I got the following error:

    Fatal error: Allowed memory size of 16777216 bytes exhausted (tried to allocate 35 bytes) in /xxx/wp-includes/functions.php on line 1250

    Now Im not sure if the two are connected or it was just that I have too many processes running?!

    I have emailed my host who tell me they can’t increase the 16mb anymore and it must be a technical issue?

    I have published and deleted a number of posts, but can’t get rid of this error. If I ask it to save the post it does actually do it, but this error appears first and I have press back on browser? I have also tried using firefox as well but it makes no difference.

    I dont know whether I need to

    a) cut down the amount of plugins I have running
    b) reduce number of posts I have on from page
    c) reduce the number of pictures I have in a post
    d) a combination of these

    I am only 6 months into blogging and having this issue already, which does not bode well for the future. As I can only see expansion of my database and more traffic.

    Any suggestions as to why this is happening?


Viewing 15 replies - 1 through 15 (of 27 total)
  • I decided to add a table from word into my post for today.

    Sounds like the source of the problem… Suggest you look carefully at that table/formatting, see what else is coming over from Word with that…

    I have deleted the offending post table and all. However the error still comes up when I try to post another entry?

    Has the table got stuck in database somewhere? Seems unlikely as I have deleted the post I added it to.

    Post a link to your site.

    As to Has the table got stuck in database somewhere? only someone with access could answer that. You could attempt a repair and optimize on the db (good practice anyway).

    hey its nothing but you can do this to avoid such error

    jus add this line in your .htaccess file (you add using file manager )

    php_value memory_limit 0M

    it will work better

    Yosemite: How do you repair and optimise. I have never done that before? What the procedure?

    xinfo: What do you mean its nothing? Is it not an issue? If it is isnt its just a pain!

    I will try that code, what does it actually mean though, so I learn from this?

    Cheers guys

    If you have access to phpMyAdmin or a similar MySQL db manager, you can repair/optimize from there.

    Guide for repair here:

    Same procedure for optimize, basically.

    Yosemite – OK did the repair only and now I get two errors when I try and post:

    Fatal error: Allowed memory size of 16777216 bytes exhausted (tried to allocate 512 bytes) in /xxx/wp-includes/functions.php on line 1250

    Fatal error: Allowed memory size of 16777216 bytes exhausted (tried to allocate 39 bytes) in /xxx/wp-includes/functions.php on line 1246


    the problem is( Allowed memory size of 16777216 bytes exhausted )

    it mean the server configration have to change its memory value which is already restricted it he have shared hosting he can do it by adding this line
    php_value memory_limit 0M
    to .htacess file which is present in the root of the web site

    xinfo: I tried the code in .htaccess and it killed my site?

    So I guess that doesnt work in my case?

    Any other ideas?

    what error it gave you ?

    can you show me your phpinfo file

    The site completely crashed both front and back end, so that was the error.

    Where is the phpinfo file, I have never come across it?

    ohh open the notepad type below code and upload to the server (root)
    save the life as phpinfo.php


    and point the browser and let me know the location of the url where you have uploaded the file

    The only time you should run into that memory error is when you’re uploading a really large image or something. There can be a problem when wordpress tries to make a thumbnail from a large image it just uploaded, as it needs to uncompress the image in memory to make the thumb. That’s the only time I’ve ever had an issue with memory. I’ve got a couple dozen wordpress installs on the same server and don’t have problems with regular posts. One of my blogs has a few thousand posts.

    Can you clarify when it’s happening? Is it when you attempt to upload images? When you hit publish? Or when you view the page? More information will be helpful here. Other details like which version of wordpress you have, and anything else you can think of will also be helpful.


    As the norm I do add many photos to the blog sometimes 5 or 6 to a post. Up until now I havent had a problem, but I added a table cut and pasted from word into a post and then, received the error stated above in my first post.

    I then deleted that post and have subsequently tried to save a new post with a new title and two words in the body just to test and the error remains the same. If I press back on my browser button it has then saved the post. I want to stop the error coming up every time I save or publish a post.

    I have tried the advice above but to no avail, so what can I do to try and sort this issue?

    The version of wordpress I am using is 2.0.2

    I hope that clarifies my situation?

Viewing 15 replies - 1 through 15 (of 27 total)
  • The topic ‘exhausted memory’ is closed to new replies.