• Resolved 2fer

    (@dominolady)


    I’m using example.com for the URLs here because there still is no content added to the WP install because I cannot get past the errors. I had downloaded a copy of WP 7.0.1 to install but the installer grabbed the more recent 7.0.2 which might want a newer version.

    I visited the install URI: https://example.com/wp/wordpress/

    ERROR messages shown on white screen:

    Fatal error: Allowed memory size of 41943040 bytes exhausted (tried to allocate 20480 bytes) in /home/account/public_html/wp/wordpress/wp-includes/class-wp-theme-json.php on line 1213:
    " $new_selectors[] = $to_prepend . $sel; }"

    Fatal error: Allowed memory size of 41943040 bytes exhausted (tried to allocate 20480 bytes) in /home/account/public_html/wp/wordpress/wp-includes/class-wp-fatal-error-handler.php on line 76:<br>" $error = error_get_last();"<br><br>I visited: https://example.com/wp/wordpress/wp-admin/<br><br>ERROR messages shown on white screen:<br><br>Fatal error: Allowed memory size of 41943040 bytes exhausted (tried to allocate 8192 bytes) in /home/account/public_html/wp/wordpress/wp-admin/includes/template.php on line 2627:<br>" unset( $other_attributes&#091;'id'] );"<br><br>There has been a critical error on this website. Please check your site admin email inbox for instructions. If you continue to have problems, please try the support forums.<br><br>Learn more about troubleshooting WordPress.<br><br>Fatal error: Allowed memory size of 41943040 bytes exhausted (tried to allocate 12288 bytes) in /home/account/public_html/wp/wordpress/wp-includes/functions.php on line 655:<br>" return @unserialize( trim( $data ) ); }"

    My best guess is that the PHP 8.1 is not up to the task but it is the most recent version available to me. I set wp-config.php temporarily to:

    // Enable Debug logging to the /wp-content/debug.log file
    define( 'WP_DEBUG_LOG', true );

    (only for the time it took to visit those two URIs.)

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator threadi

    (@threadi)

    The message indicates that the memory_limit used by your hosting provider is too low. That in itself is surprising, especially since WordPress doesn’t require a high value here. So it must be set very low. See: https://kinsta.com/blog/php-memory-limit/

    Thread Starter 2fer

    (@dominolady)

    Thank you both, mohamedjailani and threadi, I will submit a ticket at the host. It is a VPS account and I’ve seen similar things on other domains there but it wasn’t breaking the sites. That information at Kinsta was a big help to understand what happened, why and how to fix it. Much appreciated!

    Thread Starter 2fer

    (@dominolady)

    I submitted a ticket to the host and after a short time I received this response:

    First, I updated the memory_limit in php.ini to 512M and set the
    post_max_size to 256M, as these are more optimal values for your PHP
    configuration.

    Additionally, I allocated 128M of memory in wp-config.php as requested. By
    default, WordPress only allocates 40M of memory, so I increased this by adding the
    following line:
    define(‘WP_MEMORY_LIMIT’, ‘128M’);

    So I got more than I had asked for and I was immediately able to log in and find it all functional. It looks like I need to apply these settings to the other WP sites. I had seen a lot of those ‘out of memory’ errors in the past but they weren’t breaking those sites at least. I hope this information might be helpful.

Viewing 3 replies - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.