Hi there!

I have installed a new drupal recently, and drush refuses to work. Can anyone help troubleshooting this? This is the complete error message:

E: Drush was not able to start (bootstrap) Drupal.
Hint: This error often occurs when Drush is trying to bootstrap a site
that has not been installed or does not have a configured $db_url.
Drush was looking in the site ''. You can select another site
with a working database setup by specifying the URI to use with the --uri
parameter on the command line or $options['uri'] in your drushrc.php file.

My site is properly installed, and configured, drush module is installed. The settings file is in sites/default/settings.php. I am launching this from the drupal base directory.

What's the URI the error message is talking about? Does it mean the URL of the website, the URI of the database connection, or what?

Comments

vingborg’s picture

The --uri settings refers to the site uri.

You can specify it on the command line like this: drush ... --uri=http://localhost, where "..." is your drush command (incl. options).

Or you can take another look at the README.txt and/or the example drushrc.php.

grendzy’s picture

Status: Active » Closed (duplicate)
scresante’s picture

For me, the problem was that php was incorrectly installed to both /usr/local/bin and /usr/bin
Solution: make sure that `which php` is the version you actually want to use.

mattcasey’s picture

on Windows 7 at least, it is "where php"