WordPress.org

Forums

[resolved] Fatal error? (12 posts)

  1. chrisebbeck
    Member
    Posted 5 years ago #

    Hi,

    Can anybody help me?
    on my dashboard in wordpress I often get a fatal error message like:
    "Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 491520 bytes) in /home/hairloom/public_html/wp-includes/class-simplepie.php on line 4184"

    or

    "Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 1311905 bytes) in /home/hairloom/public_html/wp-includes/http.php on line 1358"

    I don't know what this means, can somebody help me out?

    I can't update wordpress to 3.0 because of this and I can't add some plugins either.

    Thanks.

  2. esmi
    Forum Moderator
    Posted 5 years ago #

    You need to increase the amount of memory available to WordPress.

    http://wordpress.org/extend/plugins/memory-bump/
    http://wordpress.org/support/topic/253495#post-1017842

  3. chrisebbeck
    Member
    Posted 5 years ago #

    Hi,

    The bump won't work for me.
    Any idea where I can access my PHP.ini file so I can change it from there?
    Or my .htaccess file?

    Thanks for your help.

  4. chrisebbeck
    Member
    Posted 5 years ago #

    I found my .htaccess file.

    where would I add "php_value memory_limit 32M"

    At the moment this is what it looks like:

    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>

    # END WordPress

  5. James Huff
    Volunteer Moderator
    Posted 5 years ago #

    Put it at the very top, above # BEGIN WordPress .

  6. chrisebbeck
    Member
    Posted 5 years ago #

    Thanks but I get an internal server error when I do this.

    I will try to add "define('WP_MEMORY_LIMIT', '32M');"
    to my wp-config.php

    Does anyone have any idea where to add this in there?

    Thanks!

  7. James Huff
    Volunteer Moderator
    Posted 5 years ago #

    Add it immediately below the define('DB_COLLATE', ''); line.

  8. chrisebbeck
    Member
    Posted 5 years ago #

    Thanks for your quick response.

    Unfortunately this hasn't worked.

    What should I do now? Nothing has worked for me.

  9. James Huff
    Volunteer Moderator
    Posted 5 years ago #

    Contact your hosting provider and ask them to bump PHP's memory allocation for you.

  10. chrisebbeck
    Member
    Posted 5 years ago #

    Hi again,
    I have contacted my host provider.
    They have advised me to do the following:

    "Please create php.ini file and then put memory_limit = whatever memory
    you want to set. Once it's done upload it to the directory where you are running that php script."

    I don't know how or what to do with thi. I am not sure how to create the php.ini file or where I should put it.

    Can you help me out again?
    Pleeeaaasssseee?

  11. chrisebbeck
    Member
    Posted 5 years ago #

    Ok I fixed this and it was very simple.

    I tried all of the following and none worked:
    1. If you have access to your PHP.ini file, change the line in PHP.ini
    If your line shows 32M try 64M:
    memory_limit = 64M ; Maximum amount of memory a script may consume (64MB)

    2. If you don't have access to PHP.ini try adding this to an .htaccess file:
    php_value memory_limit 64M

    3. Try adding this line to your wp-config.php file:
    Increasing memory allocated to PHP
    define('WP_MEMORY_LIMIT', '64M');

    4. Talk to your host.

    I have no access to my php.ini file. So I created my own php.ini file with the following in it and added to my wp-admin folder.

    <? phpinfo(); ?>
    memory_limit = 128M

    and it is all fixed!
    So simple, I have been trying to work this out all week.

  12. downsouth
    Member
    Posted 5 years ago #

    @chrisebbeck

    I too have been searching for days for the answer and tried all the same things with no luck at all. Like you, putting the php.ini file in wp-admin with this was the key:

    <? phpinfo(); ?>
    memory_limit = 128M

    I'm very appreciative that you posted.

Topic Closed

This topic has been closed to new replies.

About this Topic