1

modules can be added manually, but drush dl or drush en produce errors and will not download a module

database section from settings.php

$databases['default']['default'] = array(
    'driver' => 'pgsql',
    'database' => 'drupal7',
    'username' => 'drupal7',
    'password' => 'secretpw',
    'host' => 'localhost',
    'port' => '',
    'prefix' => ''

also, when I run drush sql-cli it ask for a password

results of a module download attempt: "drush dl"

root@list:/usr/share/ilterweb# drush dl admin_menu -vd 
Bootstrap to phase 0. [0 sec, 1.88 MB]                               [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drush() [0.01 sec, 1.99 MB] [bootstrap]
Cache MISS cid: 6.5.0-alias-path--42baa7de58f511c1e70f7cbef941324c [0.01 sec, 2      [debug]
MB]
Cache HIT cid: 6.5.0-commandfiles-0-17d9338540482247f3d013b718aae478 [0.01 sec,      [debug]
2.01 MB]
Bootstrap to phase 0. [0.08 sec, 5.38 MB]                                        [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drupal_root() [0.13 sec, 6.24 MB]       [bootstrap]
Initialized Drupal 7.26 root directory at /usr/share/ilterweb [0.14 sec, 6.24 MB]   [notice]
Drush bootstrap phase : _drush_bootstrap_drupal_site() [0.14 sec, 6.25 MB]       [bootstrap]
Initialized Drupal site default at sites/default [0.14 sec, 6.25 MB]                [notice]
Cache HIT cid: 6.5.0-commandfiles-2-062e26fa8ebdd8c444d688ab9447c986 [0.14 sec,      [debug]
6.25 MB]
Drush bootstrap phase : _drush_bootstrap_drupal_configuration() [0.14 sec, 6.25  [bootstrap]
MB]
Drush bootstrap phase : _drush_bootstrap_drupal_database() [0.16 sec, 6.27 MB]   [bootstrap]
Successfully connected to the Drupal database. [0.16 sec, 6.27 MB]               [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drupal_full() [0.18 sec, 6.78 MB]       [bootstrap]
Cache HIT cid: 6.5.0-install_profile-66ecfeb9791a023150773849f1550c5d [0.37 sec,     [debug]
16.57 MB]
Cache HIT cid: 6.5.0-install_profile-66ecfeb9791a023150773849f1550c5d [0.37 sec,     [debug]
16.57 MB]
Cache HIT cid: 6.5.0-commandfiles-5-d366cec34f20f219c93d2cf7b993082d [0.37 sec,      [debug]
16.58 MB]
Drush bootstrap phase : _drush_bootstrap_drupal_login() [0.37 sec, 16.57 MB]     [bootstrap]
Successfully logged into Drupal as Anonymous (uid=0) [0.38 sec, 16.68 MB]        [bootstrap]
Found command: pm-download (commandfile=pm) [0.38 sec, 16.68 MB]                 [bootstrap]
Loading version_control engine. [0.46 sec, 16.71 MB]                                [notice]
Loading package_handler engine. [0.46 sec, 16.72 MB]                                [notice]
Executing: wget --version
Loading release_info engine. [0.47 sec, 16.75 MB]                                   [notice]
Including /home/ubuntu/.composer/vendor/drush/drush/commands/pm/download.pm.inc  [bootstrap]
[0.48 sec, 16.84 MB]
Calling hook drush_pm_download_validate [0.48 sec, 16.91 MB]                         [debug]
Returned from hook drush_pm_download_validate [0.48 sec, 16.91 MB]                   [debug]
Calling hook drush_pm_download [0.48 sec, 16.93 MB]                                  [debug]
Downloading release history from                                                    [notice]
http://updates.drupal.org/release-history/admin_menu/7.x [0.48 sec, 16.93 MB]
Executing: wget --version
  GNU Wget 1.15 built on linux-gnu.

  +digest +https +ipv6 +iri +large-file +nls +ntlm +opie +ssl/openssl

  Wgetrc:
      /etc/wgetrc (system)
  Locale:
      /usr/share/locale
  Compile:
      gcc -DHAVE_CONFIG_H -DSYSTEM_WGETRC="/etc/wgetrc"
      -DLOCALEDIR="/usr/share/locale" -I. -I../../src -I../lib
      -I../../lib -D_FORTIFY_SOURCE=2 -I/usr/include -g -O2
      -fstack-protector --param=ssp-buffer-size=4 -Wformat
      -Werror=format-security -DNO_SSLv2 -D_FILE_OFFSET_BITS=64 -g -Wall
  Link:
      gcc -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat
      -Werror=format-security -DNO_SSLv2 -D_FILE_OFFSET_BITS=64 -g -Wall
      -Wl,-Bsymbolic-functions -Wl,-z,relro -L/usr/lib -lssl -lcrypto
      -ldl -lz -lidn -luuid ftp-opie.o openssl.o http-ntlm.o
      ../lib/libgnu.a



  Originally written by Hrvoje Niksic <hniksic@xemacs.org>.
  Please send bug reports and questions to <bug-wget@gnu.org>.
Executing: wget -q --timeout=30 -O /tmp/download_filen1hmBh url for admin_menu/7.x
Undefined variable: xml updatexml.inc:475 [1.49 sec, 16.93 MB]                      [notice]
Could not download project status information from                               [error]
(url admin_menu/7.x [1.49 sec, 16.93 MB]
Could not download requested project(s). [1.49 sec, 16.93 MB]                    [error]
Returned from hook drush_pm_download [1.49 sec, 16.93 MB]                            [debug]
Command dispatch complete [1.49 sec, 16.9 MB]                                       [notice]
 Timer  Cum (sec)  Count  Avg (msec) 
 page   1.352      1      1351.72
Peak memory usage was 18.55 MB [1.49 sec, 16.91 MB]      
0

Is drush status working?

If so, go to desire path like sites/all/modules/contrib & try drush dl admin_menu

I think drush expecting higher bootstrap level.

If drush status it's not working, check your drush installation.

0

The easiest way to get Postgres working with Drush is to set up a pgpass file in your home directory.

$ cat $HOME/.pgpass localhost:5432:*:user:secretpassword

Replace 'user' with the user account that is calling Drush. That should clear up your problems with sql-cli and pm-enable.

Your problem with pm-download is a separate issue. When I run the command you show above, the key difference in my log output is:

Executing: wget -q --timeout=30 -O /private/tmp/download_fileoPH7NZ https://updates.drupal.org/release-history/admin_menu/7.x

Note that your line has "url " where it should say "https://updates.drupal.org/release-history/". Drush gets this information from the option --source. Maybe you have define $options['source'] = "url"; somewhere in one of your drushrc.php files? If so, take that out, and it should behave correctly again.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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