Support » Plugin: Redis Object Cache » Ignoring users

  • Resolved dino62

    (@dino62)


    I am attempting to prevent users from being cached — specifically I am having an issue with one time login requests where the activation key is being reported as invalid.

    I have confirmed that if I turn off the object cache the password reset problem is resolved.

    I have added the following line to wp-config.php

    define(‘WP_REDIS_IGNORED_GROUPS’, [‘counts’, ‘plugins’, ‘themes’, ‘users’] );

    and have then executed:

    redis-cli flushall

    However, after clearing the cache, executing the following command:

    redis-cli –scan –pattern ‘*users*’ | head -10

    quickly reports new entries in the cache and the password reset issue remains.

    Any ideas?

    (Note, we are using a plugin Restrict Content Pro, that manages the login process but I have confirmed from its source code that it stores the activation key in the standard WP users table)

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

    (@tillkruess)

    Can you post your diagnostics, as well as a short list of keys from your redis-cli –scan –pattern ‘*users*’ | head -10?

    Thread Starter dino62

    (@dino62)

    
    

    Status: Connected
    Client: PhpRedis (v3.1.6)
    Drop-in: Valid
    Disabled: No
    Ping: +PONG
    Errors: []
    PhpRedis: 3.1.6
    Predis: Not loaded
    Credis: Not loaded
    PHP Version: 7.2.24-0ubuntu0.18.04.7
    Plugin Version: 2.0.17
    Redis Version: 4.0.9
    Multisite: No
    Filesystem: Working
    Global Prefix: “tsh_”
    Blog Prefix: “tsh_”
    WP_REDIS_PREFIX: “lkjafskljafjafljaflkjasfljafljflsjflajfaljfqpwirqprir32-8348484”
    WP_CACHE_KEY_SALT: “lkjafskljafjafljaflkjasfljafljflsjflajfaljfqpwirqprir32-8348484”
    WP_REDIS_IGNORED_GROUPS: [“counts”,”plugins”,”themes”,”users”]
    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: [
    “Redis Object Cache Drop-In v2.0.17 by Till Krüss”
    ]

    lkjafskljafjafljaflkjasfljafljflsjflajfaljfqpwirqprir32-8348484tsh:users:555660
    lkjafskljafjafljaflkjasfljafljflsjflajfaljfqpwirqprir32-8348484tsh:users:562216
    lkjafskljafjafljaflkjasfljafljflsjflajfaljfqpwirqprir32-8348484tsh:users:562271
    lkjafskljafjafljaflkjasfljafljflsjflajfaljfqpwirqprir32-8348484tsh:users:556161

    Plugin Author Till Krüss

    (@tillkruess)

    Your ignored groups isn’t ignoring users, maybe you defined the constant to late?

    
    Ignored Groups: [
    “counts”,
    “plugins”,
    “themes”,
    “wordfence”,
    “wordfence-ls”
    ]
    
    Thread Starter dino62

    (@dino62)

    So what is the difference between the Ignored Groups output in the entry diagnostics output and the WP_REDIS_IGNORED_GROUPS: [“counts”,”plugins”,”themes”,”users”] output in the diagnostics output?

    Thread Starter dino62

    (@dino62)

    Not to worry. Your comment helped me figure it out. Moved the WP_REDIS_IGNORED_GROUPS definition before the inclusion of wp-settings.php and users was then correctly ignored. Thanks for the guidance.

Viewing 5 replies - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.