Support » Plugin: Redis Object Cache » Running out of memory

  • Resolved Johannes Kinast

    (@goaroundagain)


    Hi,

    since a few days my Redis database regularly runs out of memory and slows down the whole server. I think it’s since the last update to 1.5.7. I had the first issue on April 8th.

    I only use Redis for Redis Object Cache on this server and the database grows up to 8 GB. If I clean the cache the size gets down to 97 MB

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Till Krüss

    (@tillkruess)

    Would you mind posting your diagnostics from the settings?

    Thread Starter Johannes Kinast

    (@goaroundagain)

    I just tried to downgrade to v1.5.6 but that hasn’t helped.

    Status: Verbunden
    Redis Version: 5.0.8
    Client: PhpRedis (v5.2.1)
    Drop-in: Valid
    Ping: 1
    Redis Extension: 5.2.1
    Predis Client: 1.1.1
    PHP Version: 7.4.4
    Multisite: Yes
    Global Prefix: “”
    Blog Prefix: 1
    WP_REDIS_UNFLUSHABLE_GROUPS: [“site-transient”]
    Global Groups: [
    “blog-details”,
    “blog-id-cache”,
    “blog-lookup”,
    “global-posts”,
    “networks”,
    “rss”,
    “sites”,
    “site-details”,
    “site-lookup”,
    “site-options”,
    “site-transient”,
    “users”,
    “useremail”,
    “userlogins”,
    “usermeta”,
    “user_meta”,
    “userslugs”,
    “blog_meta”
    ]
    Ignored Groups: [
    “counts”,
    “plugins”,
    “themes”
    ]
    Unflushable Groups: [
    “site-transient”
    ]
    Dropins:
    – advanced-cache.php v by
    – Query Monitor Database Class v by
    – Redis Object Cache Drop-In v1.5.6 by Till Krüss
    Plugins:
    – Affiliate Link Marker v0.3.0 by Johannes Kinast <johannes@travel-dealz.de> (Active network-wide)
    – Antispam Bee v2.9.1 by pluginkollektiv (Active network-wide)
    – Better Search Replace v1.3.3 by Delicious Brains (Inactive)
    – Broken Link Checker v1.11.12 by WPMU DEV (Active)
    – Colored Admin Post List v2.01 by Stevie (Active network-wide)
    – Debug Bar v1.0 by wordpressdotorg (Active)
    – Debug Bar ElasticPress v1.4 by 10up (Active)
    – Debug Bar Rewrite Rules v0.6.3 by Oleg Butuzov (Inactive)
    – de_DE v0.7.15 by Frank Bültge, Heiko Rabe (Inactive)
    – Easy WP SMTP v1.3.9.2 by wpecommerce, alexanderfoxc (Active network-wide)
    – ElasticPress v3.4.1 by 10up (Active network-wide)
    – HTML Forms v1.3.15 by ibericode (Active network-wide)
    – Individual Multisite Author v1.3.1 by Thomas Maier (Active network-wide)
    – MultilingualPress v3.3.3 by Inpsyde GmbH (Active network-wide)
    – Plugin Report v1.7 by Roy Tanck (Active network-wide)
    – Post Category Filter v1.6.1 by Javier Villanueva (Active network-wide)
    – Post Type Switcher v3.2.0 by John James Jacoby (Active network-wide)
    – Pretty Links Developer Edition v3.1.0 by Blair Williams (Active)
    – Public Post Preview v2.9.0 by Dominik Schilling (Active network-wide)
    – PWA v0.4.0 by PWA Plugin Contributors (Active network-wide)
    – Query Monitor v3.5.2 by John Blackbourn (Active network-wide)
    – Redis Object Cache v1.5.6 by Till Krüss (Active network-wide)
    – Regenerate Thumbnails v3.1.3 by Alex Mills (Viper007Bond) (Inactive)
    – Review v1.2.0 by Johannes Kinast (Active network-wide)
    – Safe SVG v1.9.8 by Daryll Doyle (Active network-wide)
    – Seriously Simple Podcasting v1.20.13 by Castos (Inactive)
    – ShortPixel Image Optimizer v4.17.2 by ShortPixel (Active network-wide)
    – Show Parent Comment v0.2.1 by Stephen Cronin (Scratch99 Design) (Active network-wide)
    – Simple Custom Post Order v2.4.9 by Colorlib (Active network-wide)
    – Subscribe to Comments Reloaded v200205 by WPKube (Inactive)
    – SVG Social Menu v2.0.0 by Florian Brinkmann (Inactive)
    – Table of Contents Plus v2002 by Michael Tran (Active network-wide)
    – Term Management Tools v1.1.4 by scribu (Active network-wide)
    – Two Factor v0.5.1 by Plugin Contributors (Inactive)
    – User Switching v1.5.4 by John Blackbourn & contributors (Active network-wide)
    – Visual Term Description Editor v1.8.1 by Shea Bunge (Active network-wide)
    – WordPress Sentry v3.4.6 by Alex Bouma (Active network-wide)
    – WP-Matomo v1.0.22 by André Bräkling (Active)
    – WP Crontrol v1.7.1 by John Blackbourn & crontributors (Inactive)
    – WP Rocket v3.5.2 by WP Media (Active network-wide)
    – WP Rocket CLI v1.0 by WP Rocket (Active network-wide)
    – WP Rocket | Cache Feed v by WP Rocket Support Team (Active network-wide)
    – WP User Avatars v1.4.0 by John James Jacoby (Active network-wide)
    – Yoast SEO: News v12.4.1 by Team Yoast (Active network-wide)
    – Yoast SEO Premium v13.4 by Team Yoast (Active network-wide)

    Plugin Author Till Krüss

    (@tillkruess)

    You could try running a few days without making site-transient un-flushable and see if that causes it. Other than that, you could also just set a maxmemory-policy that way Redis will delete un-used keys when the memory is full.

    Thread Starter Johannes Kinast

    (@goaroundagain)

    Hi Till,

    thank you for your suggestion. I added site-transient lately because I cache some API response and if I flush the cache too often, I get in trouble with the API limits. Anyway it seems that it doesn’t prevent the transients from flushing. After flushing the redis database is completely empty… I will change it to WP_REDIS_IGNORED_GROUPS

    I set a maxmemory-policy. Hope that helps.

    Thread Starter Johannes Kinast

    (@goaroundagain)

    I watched redis with redis-cli monitor and saw a lot of keys like 2:terms:get_terms-9cdfae0fe36150df41a462e15fdc84c6-0.44170300 1586687153

    The last part of the key seems to be a timestemp. Is this correct? Due to the timestemp I think this key will never hit again.

    Plugin Author Till Krüss

    (@tillkruess)

    Johannes, can you post a full redis-cli monitor log?

    You might have a 3rd party plugin using WP’s object cache the wrong way and filling it up with stale data. The safest way around that is to set a MaxTTL to 48 hours, or something.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Running out of memory’ is closed to new replies.