Tagged: Object Cache, Redis
- AuthorPosts
Gregor
GuestHi, I am getting this exact error message when I activate the Object Cache. I don’t have a clue how this happened:
The Object Cache add-in file object-cache.php is not a W3 Total Cache drop-in. Remove it or disable Object Caching. <input type="button" class="button" value="Yes, remove it for me" onclick="w3tc_beforeupload_unbind(); document.location.href='https://hanfjournal.de/wp-admin/admin.php?page=w3tc_general&w3tc_default_remove_add_in=objectcache&_wpnonce=93a8e27d2d';" />
It’s a fresh install, all settings default. However W3 Cache was installed before some time ago and then removed.
Second problem: When I test Redis on the advanced object cache configuration page, it always fails. The server has Redis activated, I can set this in the hosting config tool, but W3 seems to be unable to connect. What can I do?
Marko Vasiljevic
KeymasterHello Gregor,
Thank you for reaching out, and I am happy to help!
As the notification suggests, the drop-in file that is detected is not a W3 Total Cache drop-in.Please try to manually delete the file from the wp-content folder and re-enable Object Caching.
As for the Redis, if this is not fixed when the mentioned file is deleted, please check with your hosting provider if you can restart the RedisLet me know if this helps!
Gregor
GuestThanks! Deleting this file has helped, error message gone. Also with help of my hosters support, I found out that first, Redis was not not fully enabled yet (had to be specifically enabled on that domain), and second, in W3 cache advanced settings I had to enter as Redis hostname exactly this:
/run/redis/redis.sock
W3 says “Test passed.” and I think it’s working great.
Gregor
GuestUpdate: it seemed like it was working, but then I noticed that trying to access the site from another browser or device (not logged in as admin) always resulted in a critical WP error. Turning off object cache, it is working again. I also activated page cache with Redis, no problems with that.
I caught these error messages when object cache with Redis was enabled:
Fatal error: Uncaught RedisException: OOM command not allowed when used memory > ‘maxmemory’. in /web/wp-content/plugins/w3-total-cache/Cache_Redis.php:199
Stack trace:
#0 /web/wp-content/plugins/w3-total-cache/Cache_Redis.php(199): Redis->setex()
#1 /web/wp-content/plugins/w3-total-cache/PgCache_ContentGrabber.php(360): W3TC\Cache_Redis->get_with_old()
#2 /web/wp-content/plugins/w3-total-cache/PgCache_ContentGrabber.php(288): W3TC\PgCache_ContentGrabber->_extract_cached_page()
#3 /web/wp-content/advanced-cache.php(42): W3TC\PgCache_ContentGrabber->process()
#4 /web/wp-settings.php(99): include(‘/web/…’)
#5 /web/wp-config.php(109): require_once(‘/web/…’)
#6 /web/wp-load.php(50): require_once(‘/web/…’)
#7 /web/wp-blog-header.php(13): require_once(‘/web/…’)
#8 /web/index.php(17): require(‘/web/…’)
#9 {main} thrown in /web/wp-content/plugins/w3-total-cache/Cache_Redis.php on line 199Fatal error: Uncaught RedisException: OOM command not allowed when used memory > ‘maxmemory’. in /web/wp-content/plugins/w3-total-cache/Cache_Redis.php:150
Stack trace:
#0 /web/wp-content/plugins/w3-total-cache/Cache_Redis.php(150): Redis->setex()
#1 /web/wp-content/plugins/w3-total-cache/ObjectCache_WpObjectCache_Regular.php(388): W3TC\Cache_Redis->set()
#2 /web/wp-content/plugins/w3-total-cache/ObjectCache_WpObjectCache_Regular.php(532): W3TC\ObjectCache_WpObjectCache_Regular->set()
#3 /web/wp-content/plugins/w3-total-cache/ObjectCache_WpObjectCache.php(196): W3TC\ObjectCache_WpObjectCache_Regular->add()
#4 /web/wp-content/object-cache.php(206): W3TC\ObjectCache_WpObjectCache->add()
#5 /web/wp-includes/option.php(650): wp_cache_add()
#6 /web/wp-includes/option.php(164): wp_load_alloptions()
#7 /web/wp-includes/default-constants.php(176): get_option()
#8 /web/wp-settings.php(444): wp_plugin_directory_constants()
#9 /web/wp-config.php(109): require_once(‘/web/…’)
#10 /web/wp-load.php(50): require_once(‘/web/…’)
#11 /web/wp-blog-header.php(13): require_once(‘/web/…’)
#12 /web/index.php(17): require(‘/web/…’)
#13 {main} thrown in /web/wp-content/plugins/w3-total-cache/Cache_Redis.php on line 150Marko Vasiljevic
KeymasterHello Gregor,
The maxmemory is a Redis configuration setting.
Can you please check Redis configuration on your server and check the maxmemoryThanks!
Marko Vasiljevic
KeymasterHello Gregor,
The maxmemory is a Redis configuration setting.
Can you please check Redis configuration on your server and check the maxmemoryThanks!
- AuthorPosts