I have been having some issues running with Drush with Acquia DAMP stack.

Drush 5.7 was installed, and I could not run upgrades via Terminal, but had to manually install v.5.9. If I run drush status, all looks OK. But running drush uli comes up with the following response:

drush uli
Command user-login needs a higher bootstrap level to run - you will [error]
need to invoke drush from a more functional Drupal environment to run
this command.
The drush command 'uli' could not be executed. [error]
Drush was not able to start (bootstrap) the Drupal database. [error]
Hint: This may occur when Drush is trying to:
* bootstrap a site that has not been installed or does not have a
configured database. In this case you can select another site with a
working database setup by specifying the URI to use with the --uri
parameter on the command line. See `drush topic docs-aliases` for
details.
* connect the database through a socket. The socket file may be
wrong or the php-cli may have no access to it in a jailed shell. See
http://drupal.org/node/1428638 for details.

Drush was attempting to connect to:
Drupal version : 7.23
Site URI : http://default
Default theme : garland
Administration theme: garland
PHP configuration :
Drush version : 5.9
Drush configuration:
Drupal root : /Users/User/sites/omega4_test2
Site path : sites/default
Modules path : sites/all/modules
Themes path : sites/all/themes
File directory path: sites/default/files
%paths : Array

Any ideas on resolving this?

Comments

karolus’s picture

OK--
Did more install attempts. Now have the latest version of pear and drush installed, but still an issue with magic quotes and Console table 1.1.3. When attempting to update in Terminal, this is what I see:

Drush needs to download a library from http://download.pear.php.net/package/Console_Table-1.1.3.tgz in order to function, and the attempt to download this file automatically failed because you do not have permission to write to the library directory /usr/lib/php/pear/drush/lib. To continue you will need to manually download the package from http://download.pear.php.net/package/Console_Table-1.1.3.tgz, extract it, and copy the directory into your /usr/lib/php/pear/drush/lib directory.

Since it was indicating a permissions issue, I went to change the permissions by using the following Terminal command:
$ chmod 755 /usr/lib/php/pear/drush/lib

Still no change when attempting to install after this. Any thoughts?

karolus’s picture

Status: Active » Closed (fixed)

Did more checking, found issue unrelated to Drush, after complete reinstallation of software.

It was due to the way the site's settings.php file was handled in Acquia DAMP. Basically, it creates a folder within /sites named [your sitename].localhost, where a settings.php file is auto-generated. Copying this file into the /default folder takes care of this problem.

kbell’s picture

You can, by the way control how that subfolder is handled by setting the name of your site (upon import or creation) to something like (subdomain = local) and domain = (mysite.com); then you wind up with a local site called local.mysite.com:8085 (or whatever port number you're using). Then the settings.php file that is generated isn't named .localhost anymore; it's just set inside the sites/local.mysite subfolder as settings.php.