• Resolved Steven Davis

    (@stevendavis2018)


    After enabling the cache feature I received the error below:

    [30-Jun-2024 04:02:47 UTC] PHP Fatal error: Uncaught Error: Call to undefined function wp_cache_get() in /volume1/web/familyhistories/wp-includes/option.php:602
    Stack trace: 0 /volume1/web/familyhistories/wp-includes/option.php(164): wp_load_alloptions() 1 /volume1/web/familyhistories/wp-includes/l10n.php(63): get_option(‘WPLANG’) 2 /volume1/web/familyhistories/wp-includes/l10n.php(165): get_locale() 3 /volume1/web/familyhistories/wp-includes/l10n.php(1369): determine_locale() 4 /volume1/web/familyhistories/wp-includes/l10n.php(1400): _load_textdomain_just_in_time(‘wp-optimize’) 5 /volume1/web/familyhistories/wp-includes/l10n.php(194): get_translations_for_domain(‘wp-optimize’) 6 /volume1/web/familyhistories/wp-includes/l10n.php(306): translate(‘User is logged …’, ‘wp-optimize’) 7 /volume1/web/familyhistories/wp-content/plugins/wp-optimize/cache/file-based-page-cache-functions.php(38): __(‘User is logged …’, ‘wp-optimize’) 8 [internal function]: wpo_cache(‘…’, 9)

Viewing 4 replies - 1 through 4 (of 4 total)
  • I’m sorry you’re experiencing PHP errors after enabling the cache feature. It looks like the error involves an undefined function related to caching. Could you let me know if you have any other caching plugins installed or if there have been any recent changes to your site’s configuration? Also, try clearing your cache in all forms, including browser cache and any server-side cache, to see if that resolves the issue. This information will help me diagnose the issue more effectively.

    Thread Starter Steven Davis

    (@stevendavis2018)

    I do not have any specific caching plugins except WP-Optomize. The only other plugin, I am aware of, that uses caching is Smart Slider. I cleared the caches in Smart Slider and WP-Optomize.

    My site has slowed down after the last few WP upgrades. No idea why as I have not added / changed any pages or added any plugins. I did have a few large packet errors, this year, which I have not seen in the previous eight years of using WP.

    “WordPress database error Got a packet bigger than ‘max_allowed_packet’ bytes for query UPDATE wpfh1_options SET option_value.”

    These packet errors range in size from 2,101kb to 10,151kb in size.

    Thanks for the additional details, Steven. Given that you only have WP-Optimize and Smart Slider using caching, and considering the recent packet errors you mentioned, it sounds like there might be an underlying issue with your database configuration or the size of the data being handled.

    Here are a few steps to troubleshoot and potentially resolve the issue:

    1. Contact Hosting Provider to Increase max_allowed_packet Size:
      • The max_allowed_packet setting in your MySQL configuration controls the maximum size of a packet that can be sent. Please contact your hosting provider and ask them to increase this value to 64M ( max_allowed_packet=64M) if it is currently set to a lower value. After this change, they will need to restart the MySQL server.
    2. Disable and Re-enable WP-Optimize Cache:
      • Sometimes, simply toggling the cache settings can help resolve configuration issues. Disable the cache in WP-Optimize, clear all caches, and then re-enable it.
    3. Check for Large Options:
      • Large options stored in the database can cause performance issues. Check your wp_options table for any unusually large entries and consider cleaning them up if necessary.

    Additionally, it’s important to note that your server plays a major role in the performance of your site. If your server is under heavy load or has limited resources, it can significantly slow down your site. Ensuring your server has adequate resources and is well-configured can help improve your site’s performance.

    Please try these steps and let me know if the issue persists. If you continue to experience problems, we might need to look deeper into your server configuration and logs for more insights.

    Thread Starter Steven Davis

    (@stevendavis2018)

    Thank you for the response. The packet size has been increased.

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

The topic ‘Enabling cache causes PHP errors’ is closed to new replies.