I have a site running on Drupal. There is a production site, publicly seen online and a development version on a private machine.

When migrating from a devel to a production server I'd like to disable the display of error messages. This could be done in Home » Administration » Configuration » Development (D7). However I'd like to automate that; put a proper SQL query in my migration script (that packs, transfers and 'installs' the page on a production server)

Can anyone help me with that? Thanks!

1 Answer 1


That setting is stored in the variable table as a serialised PHP string (in the "error_level" var) - I wouldn't advise updating that table manually with SQL (although obviously you can if you need to).

Far better would be to install Drush, and use vset as part of your deployment process instead:

drush vset error_level '2'

The available options are:

  • 0 => None
  • 1 => Errors and warnings
  • 2 => All messages
  • 1
    Also possible to put in settings.php file as $conf['error_level'] = 2;
    – Beebee
    Jul 16, 2013 at 12:08
  • @Beebee Good point
    – Clive
    Jul 16, 2013 at 12:09

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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