• Resolved taidgh

    (@taidgh)


    Hi All,

    I installed W3 Total Cache 2 weeks ago. Two days ago my home page stopped working and instead forced a file download called “download” with no file extension. This was only for non logged in users. Logged in users did not have an issue and logged out users could see pages other pages aside from the home page.

    I rebooted the server and it seemed to work again. Yesterday it happened again and I checked the logs:

    [Thu Jul 13 00:27:36.686782 2023] [php:error] [pid 21121] [client 154.209.125.78:23612] PHP Fatal error:  Uncaught Error: Call to undefined function mysql_connect() in /var/www/html/wp-includes/class-wpdb.php:2054\nStack trace:\n#0 /var/www/html/wp-content/plugins/w3-total-cache/DbCache_WpdbNew.php(100): wpdb->db_connect()\n#1 /var/www/html/wp-includes/class-wpdb.php(773): W3TC\\DbCache_WpdbNew->db_connect()\n#2 /var/www/html/wp-content/plugins/w3-total-cache/DbCache_WpdbNew.php(221): wpdb->__construct()\n#3 /var/www/html/wp-content/plugins/w3-total-cache/DbCache_WpdbInjection.php(38): W3TC\\DbCache_WpdbNew->default_initialize()\n#4 /var/www/html/wp-content/plugins/w3-total-cache/DbCache_WpdbNew.php(107): W3TC\\DbCache_WpdbInjection->initialize()\n#5 /var/www/html/wp-content/plugins/w3-total-cache/DbCache_WpdbNew.php(362): W3TC\\DbCache_WpdbNew->initialize()\n#6 /var/www/html/wp-content/plugins/w3-total-cache/DbCache_WpdbInjection_QueryCaching.php(294): W3TC\\_CallUnderlying->initialize()\n#7 /var/www/html/wp-content/plugins/w3-total-cache/DbCache_WpdbNew.php(107): W3TC\\DbCache_WpdbInjection_QueryCaching->initialize()\n#8 /var/www/html/wp-content/plugins/w3-total-cache/DbCache_Wpdb.php(53): W3TC\\DbCache_WpdbNew->initialize()\n#9 /var/www/html/wp-content/db.php(81): W3TC\\DbCache_Wpdb::instance()\n#10 /var/www/html/wp-includes/load.php(570): require_once('...')\n#11 /var/www/html/wp-settings.php(124): require_wp_db()\n#12 /var/www/html/wp-config.php(128): require_once('...')\n#13 /var/www/html/wp-load.php(50): require_once('...')\n#14 /var/www/html/wp-blog-header.php(13): require_once('...')\n#15 /var/www/html/index.php(17): require('...')\n#16 {main}\n  thrown in /var/www/html/wp-includes/class-wpdb.php on line 2054

    Any help would be much appreciated as W3 Total Cache is a notable improvement (apart from when it borks my site!)

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

    (@vmarko)

    Hello @taidgh

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

    Most likely the problem is with the double compression issue. If you have gzip compression enabled in Performance>Browser Cache, please disable it for HTML&XML save all settings and purge the cache and let me know if the problem persists.

    The error you shared indicates a problem with connecting to the database. Can you please share what is the caching method you are using for DB caching and have you tried clearing the db table?

    Thanks!

    Thread Starter taidgh

    (@taidgh)

    Hi @vmarko I am using Redis for DB cache.

    I disabled gzip and it now appears to be working correctly.

    Very much appreciate your help on this. It minimises the cold sweat when things go wrong.
    Going to check on it hourly today to make sure it is still not an issue.

    Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @taidgh

    Thank you for your feedback. Most likely you have another compression somewhere enabled which is causing double compression if the gzip is enabled.

    Let me know if the issue continues to persist.

    Thanks!

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Homepage downloading cache (not showing the page’ is closed to new replies.