0

I moved my local site to shared host.

  • all code has been deployed to the staging server
  • I changed settings.php
  • import the database from local to the staging server database

When I try to reach the site I get an HTTP ERROR 500. In phpMyAdmin I TRUNCATE the cache tables:

TRUNCATE cache_config;
TRUNCATE cache_container;
TRUNCATE cache_data;
TRUNCATE cache_default;
TRUNCATE cache_discovery;
TRUNCATE cache_dynamic_page_cache;
TRUNCATE cache_entity;
TRUNCATE cache_menu;
TRUNCATE cache_render;
TRUNCATE cache_toolbar;

If I look in the error logs I see:

AH01071: Got error 'PHP message: PHP Fatal error:  Class 'Drupal\\Core\\Cache\\DatabaseBackend' not found in /home/mysite.nl/public_html/staging/index.php on line 16\n'

What do I have to do?

  • I think I understand what is causing the problem - a missing DB driver for PHP. However, before "officially" posting my answer I would like some more information. What version of Drush (and Drupal)? – hansfn Oct 18 '18 at 21:59
0

Make sure your database connection to the DB server is correct. I was using an older local password for DB which caused a similar issue when moving to live hosting.

0

I was missing $settings['hash_salt'] = '';. I changed this to $settings['hash_salt'] = 'CHANGE THIS'; after this I could reach the site!

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.