WordPress.org

Ready to get started?Download WordPress

Forums

Fatal error: out of memory error (specific to comments) (8 posts)

  1. coeurmechante
    Member
    Posted 10 months ago #

    Hi,
    I'm getting the above-mentioned error, but no suggestions seem to solve it. I still get it when deactivating all plugins and using Twenty Ten/Twelve/Thirteen themes. I tried to increase my memory limit in wp-config and through .htaccess.

    Interestingly, it seems to only appear in instances where comments should be listed-- in the Recent Comments area on the admin dashboard (preventing the rest of the page from loading), on edit-comments, and on the edit-post page in the comments section.

    I've optimized my database, and culled old comments, and nothing.

    On the front-end, on my most recent post, comments aren't displaying (there should be 21 total). The site lists "21 comments" and just doesn't display them. They're in the database and the number 21 appears by the post title in admin.

    Has anyone experienced this memory leak specific to comments?

    I'm running WP 3.7, though the problem existed prior to the upgrade. My client isn't sure when the comments disappeared from the front end, though the post in question is about a month old.

  2. Tara
    Member
    Posted 10 months ago #

    whta is the full error message?

    I tried to increase my memory limit in wp-config and through .htaccess.

    Increased from what to what?
    Have you checked with your hosting provider if they allow increasing memory limit that way?

  3. coeurmechante
    Member
    Posted 10 months ago #

    Full message on dashboard:

    Fatal error: Out of memory (allocated 73662464) (tried to allocate 40 bytes) in /homepages/20/d128477246/htdocs/markbraverman/wp-includes/functions.php on line 2617

    on edit-comments.php:

    Fatal error: Out of memory (allocated 73662464) (tried to allocate 49 bytes) in /homepages/20/d128477246/htdocs/markbraverman/wp-includes/cache.php on line 457

    I tried increasing to 128mb, just for kicks. The host is 1and1, who says that we're allocated 30mb, and using 17mb, so I can't figure out what's happening.

  4. Tara
    Member
    Posted 10 months ago #

    I still get it when deactivating all plugins and using Twenty Ten/Twelve/Thirteen themes.

    Have you tried:
    - resetting the plugins folder by FTP or PhpMyAdmin. Sometimes, an apparently inactive plugin can still cause problems (because the hooks remain unless plugins completely removed or some plugins stick around in cached files. So by renaming the folder, you break them and force them inactive).
    - If the above troubleshooting steps fail to resolve the issue, try manually re-uploading all files and folders EXCEPT the wp-config.php file and the /wp-content/ directory from a fresh download of WordPress. Make sure that you delete the old copies of files & folder before uploading the new ones. Read the Manual Update directions first!
    - Always backup everything (including your database) before doing any actions, just in case.

  5. vividsoftwaresolutions
    Member
    Posted 10 months ago #

    I suspect its a server memory problem:
    Try this:
    1. Install the "wp-memory-usage" plugin, it will show you your mem consumption: http://wordpress.org/plugins/wp-memory-usage/

    2. open your wp-config file which located at the root of your WordPress install, and paste the following code in it.

    [php]define(‘WP_MEMORY_LIMIT’, ‘XXX’);[/php]

    XXX is the desired MB limit like 64MB, 80MB, etc, at any increment of 8MB. By default it should be 32MB. Example:

    [php]define(‘WP_MEMORY_LIMIT’, ’64M’);[/php]

    Once saved, WordPress will be able to use as much memory as specified. Done.

    If you still get the error after this fix, then please contact your host.

  6. coeurmechante
    Member
    Posted 10 months ago #

    Hi,
    @tara, I tried both of those suggestions. Thank you. The problem persists. I've contacted my host, who suggested putting a php.ini in wp-admin. I've done this too, and still nothing. I've written them back and hope to get some kind of support, but they don't seem to have any great ideas, or a decent support forum. Any other idea?

    @vividsoftwaresolutions. Done. My memory consumption is 17mb. Doesn't seem enough to take me down so hard, does it?

    Again, the problem seems specific to any calls for comments, if that rings a bell.

  7. Tara
    Member
    Posted 10 months ago #

    After all these troubleshooting steps failing to resolve the issue, it seems the problem may be server related.

    Someone else?

  8. vividsoftwaresolutions
    Member
    Posted 10 months ago #

    Can you query the comments table via PHP?

    Try something like

    $args = array('status' => 'approve');
    
    $comments_query = new WP_Comment_Query;
    $comments = $comments_query->query( $args );

    I have not tested the code but you can give it a try ..

Reply

You must log in to post.

About this Topic