Forums

[resolved] memory size problem...very nasty one (4 posts)

  1. wp-tc
    Member
    Posted 2 years ago #

    Hi guys,

    My wp blog recently has encountered the memory problem. Every time I press the 'publish' button to post a new post it come out the message of " Allowed memory size of 16777216 bytes exhausted (tried to allocate 42 bytes).....public_html/wp-includes/functions.php on line 2901" . However, the post is successfully published because i can found the post at the edit page.

    I have done the research online, and I know this problem is quite common. However I try almost all the approaches that recommended by experianceses people but the problem still remains. The solution that i have tried includes:
    1. .htaccess file:
    php_value memory_limit 32M

    2. wp-config.php file:
    Increasing memory allocated to PHP
    define('WP_MEMORY_LIMIT', '32M');

    3.wp-setting.php files:
    define('WP_MEMORY_LIMIT', '32M');

    and many more...but i still solve the probelm.

    The only solution that work for me is inactivating some plugin. But it seems it is not the specific plug in that cause the problem. Because inactivating the plugin only solve the problem temporary. The error will occur again after some post has been published. Than i will need to inactivating other plug in again. This is kind a weird and i am totally have no idea what is going on here.

    Anyone can help? Please...

  2. wp-tc
    Member
    Posted 2 years ago #

    Anybody please...?

  3. sweetangst
    Member
    Posted 2 years ago #

    Talk to your host -- it's possible that you aren't allowed to increase your own PHP memory limit.

  4. wp-tc
    Member
    Posted 2 years ago #

    I finally found the solution!!!!
    It is the XML sitemap generator plugin that causing this problem.

    I deactivated my plugin one by one, and see which is the plugin that cause the problem. And it turn out is the sitemap generator that exhaust the memory in the server.

    I also found a article that talk about this problem:
    http://www.quickonlinetips.com/archives/2009/04/sitemap-generator-wordpress-plugin-internal-server-errors/

    This article said that the plugin will consume a lot of our server MEMORY USAGE. But this plugin is very useful and hardly to find an alternative. If you think your blog don't need it, than you can just deactivated it. But how if you still want to use it?

    Well, the solution is go to your XML Sitemap Generator panel, and scroll down until you see this (under Advanced options) :

    [Try to increase the memory limit to: 16M ]

    just change the value to 32M,or 64M, or 128M(depending on your web server allowed size.) And it work for me!

    You can also try tp Limit the number of posts in the sitemap or Try to increase the execution time limit if increasing memory doesn't work.

    Hope this will help the people that have the same problem like mine.

Topic Closed

This topic has been closed to new replies.

About this Topic