Tagged: 

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #157011 Reply
    Gregor
    Guest

    Hi there, I’m trying to set up W3 Total Cache on a few websites that run on a dedicated server. For Cache Method, there always is the choice between Disk (Basic/Enhanced) and Redis in W3 general settings, all others options are grey.

    Redis is better, isn’t it? I am unsure because it is listed for “Multiple servers” in the dropdown menu. Should I prefer Disk because this server is a single server?

    Also I have a few Redis configuration options on the server for each site and domain: Number of databases (16), Max memory (64MB), Key eviction policy (noeviction). Should I leave them at their defaults (in parentheses)? The websites are very different in size: one has around 10000 posts, another less than 30 posts or pages, one is a WooCommerce shop.

    #157021 Reply

    Hello Gregor,

    Thank you for reaching out, and I am happy to help!

    In the W3 Total Cache, the Disk caching method writes the cached files to disk. As for Redis, this is a memory caching method and it performs much faster, and it’s a recommended option for Object Caching and Database Caching.
    Disk: Enhanced is the best option for the Page Cache; however, you can also use Redis for this.

    As for the Redis configuration, 64MB is not suggested for caching.
    You need to configure your Redis cache server so it “evicts” data from the cache rather than just continuing to fill up your RAM. Look here https://raw.githubusercontent.com/redis/redis/7.2/redis.conf for the maxmemory and maxmemory-policy settings. With a 4 GiB server for example you can set them as follows:

    maxmemory 512mb
    maxmemory-policy allkeys-lfu

    Let me know if this helps!

    Thanks!

    #157124 Reply
    Gregor
    Guest

    Thanks a lot! Big questions answered. First I changed the Redis configuration to use “allkeys-lfu”.
    Now I’m thinking about the memory setting. This server has 64 GB RAM but it’s serving ~30 WP websites. Still much more memory than necessary and I guess I could use up to 32 GB for Redis, or is it too much?
    Not 32 GB for each website as they all have their own Redis configuration. Maybe 8 GB for the most active site and ~2 GB each for some others.

Viewing 3 posts - 1 through 3 (of 3 total)
Reply To: Cache method Disk vs. Redis and Redis settings (Page Cache, Object Cache)
Your information: