• Resolved Andries Jansen

    (@jansencws)


    Hello,

    I’ve got these errors for multiple sites on one server:

    Got error ‘PHP message: RedisException: READONLY You can’t write against a read only replica. in ../wp-content/object-cache.php:1070\n
    Stack trace:\n
    #0 ../wp-content/object-cache.php(1070): Redis->del(‘domain…’)\n
    #1 ../wp-content/object-cache.php(80): WP_Object_Cache->delete(‘rocket_cloudfla…’, ‘transient’, 0)\n
    #2 ../wp-includes/option.php(729): wp_cache_delete(‘rocket_cloudfla…’, ‘transient’)\n
    #3 ../wp-content/plugins/wp-rocket/inc/Addon/ServiceProvider.php(72): delete_transient(‘rocket_cloudfla…’)\n
    #4 ../wp-content/plugins/wp-rocket/ inc/Addon/ServiceProvider.php(59): WP_Rocket\\Addon\\ServiceProvider->addon_cloudflare(Object(WP_Rocket\\Admin\\Options_Data))\n
    #5 ../wp-content/plugins/wp-rocket/inc/Engine/Container…’

    Got error ‘PHP message: RedisException: READONLY You can’t write against a read only replica. in ../wp-content/object-cache.php:1014\n
    Stack trace:\n#
    0 ../wp-content/object-cache.php(1014): Redis->set(‘domain…’, ‘a:378:{s:7:”sit…’, Array)\n
    #1 ../wp-content/object-cache.php(931): WP_Object_Cache->add_or_replace(true, ‘alloptions’, Array, ‘options’, 0)\n
    #2 ../wp-content/object-cache.php(36): WP_Object_Cache->add(‘alloptions’, Array, ‘options’, 0)\n
    #3 ../wp-includes/option.php(258): wp_cache_add(‘alloptions’, Array, ‘options’)\n
    #4 ../wp-includes/functions.php(1717): wp_load_alloptions()\n
    #5 ../wp-includes/load.php(664): is_blog_installed()\n
    #6 …..’

    WP: 5.5.3
    Redis Object Cache: 2.0.15
    REDIS_VERSION: 6.08
    GOSU_VERSION: 1.12

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

    (@tillkruess)

    Hi Andries, can you post your diagnostics?

    Thread Starter Andries Jansen

    (@jansencws)

    Hi Till,

    First domain:
    Status: Connected
    Client: PhpRedis (v5.3.2)
    Drop-in: Valid
    Disabled: No
    Filesystem: Working
    Ping: 1
    Errors: []
    PhpRedis: 5.3.2
    Predis: Not loaded
    Credis: Not loaded
    PHP Version: 7.3.24
    Plugin Version: 2.0.15
    Redis Version: 6.0.8
    Multisite: Yes
    Global Prefix: “”
    Blog Prefix: 1
    WP_REDIS_PREFIX: “domainname.nl:”
    WP_CACHE_KEY_SALT: “domainname.nl:”
    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”,
    “redis-cache”,
    “blog_meta”
    ]
    Ignored Groups: [
    “counts”,
    “plugins”,
    “themes”,
    “wordfence”,
    “wordfence-ls”
    ]
    Unflushable Groups: []
    Drop-ins: [
    “advanced-cache.php v by “,
    “maintenance.php v by “,
    “Redis Object Cache Drop-In v2.0.15 by Till Krüss”
    ]

    Second domain:
    Status: Connected
    Client: PhpRedis (v5.3.2)
    Drop-in: Valid
    Disabled: No
    Filesystem: Working
    Ping: 1
    Errors: []
    PhpRedis: 5.3.2
    Predis: Not loaded
    Credis: Not loaded
    PHP Version: 7.3.24
    Plugin Version: 2.0.15
    Redis Version: 6.0.8
    Multisite: No
    Global Prefix: “koek_”
    Blog Prefix: “koek_”
    WP_REDIS_PREFIX: “domainname.nl:”
    WP_CACHE_KEY_SALT: “domainname.nl:”
    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”,
    “redis-cache”,
    “blog_meta”
    ]
    Ignored Groups: [
    “counts”,
    “plugins”,
    “themes”,
    “wordfence”,
    “wordfence-ls”
    ]
    Unflushable Groups: []
    Drop-ins: [
    “advanced-cache.php v by “,
    “maintenance.php v by “,
    “Redis Object Cache Drop-In v2.0.15 by Till Krüss”
    ]

    Plugin Author Till Krüss

    (@tillkruess)

    Mhh, it looks like you’re not setting a host, so I assume it’s a local instance at 127.0.0.1.

    What hosting provider are you using?

    
    READONLY You can’t write against a read only replica.
    

    This leads me to believe it only occurs occasionally when your Redis server is replaced with a failover/standby instance.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘READONLY You can’t write against a read only replica’ is closed to new replies.