With a WSOD upon deployment of a site, should I first clear the cache, check watchdog logs, or check the Apache logs?

drupal.stackexchange https://drupal.stackexchange.com/questions/293631

  •  24-02-2021
  •  | 
  •  

Frage

With a WSOD upon deployment of a Drupal 8 site, should I first clear the cache, check watchdog logs, check the Apache logs, or something else?

I read the Drupal WSOD triage information here But it doesn't seem to share which solution should first be done in this situation.

This seems to indicate that it could be with the DB, so would I need to check that first?

I just noticed Fixing white screens step by step. It seems to suggest that I should look at the system (Apache) logs first. Am I interpreting this correctly?

War es hilfreich?

Lösung

Yes. Because of the variety of possible Drupal stack configurations, it's impossible to say you'll always find your error in an Apache log. However, a WSOD generally means PHP has hit a fatal error and it's configured not to dump sensitive debug info to screen.

If that's the case, you might not even have a working Drupal app to make use of its tools like cache clearing, watchdog, etc., so it's best to find where those PHP errors are dumped so you can get Drupal into a bootstrapped state.

Of course, you should know your stack better than anyone else so a cache clear could eliminate the issue if you know the source of the problem. But if you're unsure, Apache logs are a good first start.

Andere Tipps

Assuming that your site and Apache has worked just fine before the deployment, and since this happens during a code update I'd suggest to always clear the caches first.

$ drush cr

And since data/entities might have changed during the update this then should be followed by database updates.

$ drush -y updb

Then re-check.

Your environment might simply be configured to suppress on-screen error messages. And you very likely get a hint on what's wrong on the command line when performing Drush commands.

I'd also always have a look at Watchdog then before starting to dig through any other logs.

$ drush ws
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit drupal.stackexchange
scroll top