• Resolved adalov

    (@adalov)


    Hi,

    we use W3TC with the DB Cache option enabled. Unfortunately, when WP-Cron w3_dbcache_cleanup runs, it throws the following error shown by Query Monitor:
    /wp-content/cache/db/options/): Failed to open directory: No such file or directory:

    • wp-content/plugins/w3-total-cache/Util_File.php:133
    • opendir()
      wp-content/plugins/w3-total-cache/Util_File.php:133
    • W3TC\Util_File::rmdir()
      wp-content/plugins/w3-total-cache/Util_File.php:172
    • W3TC\Util_File::emptydir()
      wp-content/plugins/w3-total-cache/Cache_File.php:281
    • W3TC\Cache_File->flush()
      wp-content/plugins/w3-total-cache/DbCache_WpdbInjection_QueryCaching.php:410
    • W3TC\DbCache_WpdbInjection_QueryCaching->_flush_cache_for_sql_group()
      wp-content/plugins/w3-total-cache/DbCache_WpdbInjection_QueryCaching.php:342
    • W3TC\DbCache_WpdbInjection_QueryCaching->update()
      wp-content/plugins/w3-total-cache/DbCache_WpdbNew.php:150
    • W3TC\DbCache_WpdbNew->update()
      wp-includes/option.php:520
    • update_option()
      wp-includes/option.php:990

    The error also seems to temporarily slow down the website (at least in the backend).

    Further info: Object cache is disabled because Redis / Memcached is not available on the shared server. We would therefore like to leave DB Cache enabled.

    Is there any solution for this / any tweak to the settings that could prevent this? Would it be advisable to turn off the w3_dbcache_cleanup cron-job completely or have it run at intervals >3600?

    Thanks in advance!

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @adalov

    Thank you for reaching out and I am happy to assist you with this.

    In general, it’s not recommended to use Object Cache or Database Cache when the only available caching method is Disk, and one of the reasons is the one you are presenting.

    In most cases, it’s much faster to fetch the data from the database then from the disk, and there are no discrepancies in this case.

    What you can try is to manually delete the /wp-content/cache/db/ folder and see if the issue reoccurs.
    I would recommend disabling the DB cache entirely if the only available caching method is Disk.

    Thanks!

    Thread Starter adalov

    (@adalov)

    Hi Marko,

    thanks! The manual delete did not help, so we disabled DB cache as you advised.

    Another quick and general question in this respect: Given the small / neglectable positive impact of disk caching and the advantages of Redis / Memcached, would you disrecommend using shared hosting that does not offer those in general? Maybe a dumb question, but some big(!) (German) hosting providers currently do not offer Redis / Memcached in their WordPress shared hosting plans at all and maybe that might be a reason to stay away from those “service providers” in the future? Just curious what is your personal take on that.

    Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @adalov

    This depends on many things, like the type of website for example. If you are using a simple blog website, shared hosting is fine since you do not need DB caching in this case or Object Caching. Almost all service providers are offering some type of a shared hosting which is much more affordable for smaller websites.

    When using an ecommerce website or a website with a lot of comments, etc, it’s best to use VPS or Dedicated server.

    I hope this helps!

    Thanks!

    Thread Starter adalov

    (@adalov)

    Thx!

    Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @adalov

    You are most welcome!

    We would really appreciate it if you could take a minute and post a review here. This will help us to continue offering a top-notch product to users.
    Thanks!

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘/wp-content/cache/db/options/: Failed to open directory: No such file …’ is closed to new replies.