Monday, May 24, 2010

HEEELP!!! Drupal WSOD problem... Why and How to recover

Remember the times when you have seen Bill Gates present a Windows feature to the world, and it all suddenly ends in the BSOD (Blue Screen Of Death)? This kind of problem probably gets a couple of MS-engineers fired ASAP.

Drupal has an equivalent to BSOD - The White Screen Of Death (WSOD) Read on to avoid "getting the boot" from your boss or customer for your Drupal website suddenly going white, and not showing any HTML or other code on inspection!

WSOD - Causes
WSOD in Drupal is most likely to bug you when:
  • You've installed (uploaded and activated!) one or several Modules that have bugs in them, or that they together act erroneously (module madness)
  • You've done something terribly wrong in one of the template/theme files
The first case is the most common, also as you will have guessed that the latter case is easily overcome by simply reverting your own code back to functioning state.

Solution to WSOD - Module madness
Drupal keeps a continuous status of which modules you have installed and enabled for your Drupal installation. These informations are collected together in the database of your Drupal installation. So, using your favorite database-editor (e.g. PhpMyadmin for MySQL), you should take the time to locate the table named "_system" (e.g. "drup_system"). In here, you will observe (upon inspection) that it has two data-columns of special significance; "name" and "status". "name" indicates, as you might've guessed - the Module Name, while the status is enabled/disabled (1/0) for each of these modules.
You will therefore need to disable any of the more recent modules that you've installed, and you should be rid of WSOD once more.
Disabling modules is accomplished by - You guessed it - using that same database-editor (PhpMyadmin) and setting the "status" of the suspected Modules to the value of "0" (ZERO).

No comments:

Post a Comment