I've updated drush from 4.5 to 5.1. Everything else seems to work fine but "drush up" does nothing. I'm running this locally on OSX.

Running with "drush -v up" produces the following

Initialized Drupal 7.12 root directory at /Volumes/Macintosh HD/Applications/MAMP/htdocs/hhp2011                                    [notice]
Initialized Drupal site default at sites/default                                                                                    [notice]
Loading release_info engine.                                                                                                        [notice]
Loading version_control engine.                                                                                                     [notice]
Loading package_handler engine.                                                                                                     [notice]
Executing: wget --version
Executing: curl --version
php /Users/martin/drush/drush.php  --backend=2 --verbose --root='/Volumes/Macintosh HD/Applications/MAMP/htdocs/hhp2011'            [notice]
--uri=http://default batch-process 206 206 2>&1
php /Users/martin/drush/drush.php  --backend=2 --verbose --root='/Volumes/Macintosh HD/Applications/MAMP/htdocs/hhp2011'            [notice]
--uri=http://default batch-process 206 206 2>&1

The last line gets repeated over and over again in a loop.

Comments

svdoord’s picture

I have the same problem. Any news on this?

Initialized Drupal site default at sites/default                        [notice]
Loading release_info engine.                                            [notice]
Loading version_control engine.                                         [notice]
Loading package_handler engine.                                         [notice]
Executing: wget --version
php /Applications/MAMP/drush/drush.php  --backend=2 --verbose           [notice]
--root=/Users/stefan/Documents/Projects/Torkest/drupal
--uri=http://default batch-process 44 44 2>&1
php /Applications/MAMP/drush/drush.php  --backend=2 --verbose           [notice]
--root=/Users/stefan/Documents/Projects/Torkest/drupal
--uri=http://default batch-process 44 44 2>&1
php /Applications/MAMP/drush/drush.php  --backend=2 --verbose           [notice]
--root=/Users/stefan/Documents/Projects/Torkest/drupal
--uri=http://default batch-process 44 44 2>&1

(repeat ad infinitum)

Anonymous’s picture

Same problem, drush up is looping forever in Drush 5 on my server. I'm using it with the -l flag for a multisite install if that matters.

moshe weitzman’s picture

Category: support » bug
Priority: Normal » Major

If anyone is willing, it would be helpful if you could create a site-archive and post it here. You would have to sanitize the database and filesystem if you have any private data there.

Also, use updatecode and then updatedb. Those are the 2 steps that update command does and it would help isolate the problem if more if we know where the problem is.

Anonymous’s picture

Here is the output of updatecode. It happens at that step:

drushclp upc -v admin_menu
Initialized Drupal 7.12 root directory at [notice]
/home/web/actonweb/acton-drupal7
Initialized Drupal site www.clpress.com at sites/clpress.com [notice]
Loading release_info engine. [notice]
Loading version_control engine. [notice]
Loading package_handler engine. [notice]
Executing: wget --version
php /home/web/actonweb/drush/drush.php --backend=2 --verbose [notice]
--root=/home/web/actonweb/acton-drupal7 --uri=http://www.clpress.com
batch-process 59 59 2>&1
php /home/web/actonweb/drush/drush.php --backend=2 --verbose [notice]
--root=/home/web/actonweb/acton-drupal7 --uri=http://www.clpress.com
batch-process 59 59 2>&1

... to eternity with the last php line.

I thought it might be that my server's php command is 5.2.1 while I run the virtualhost at 5.2.16, but when I aliased php to the 5.2.16 version it didn't make a difference.

jonhattan’s picture

Version: 7.x-5.1 »
Status: Active » Postponed (maintainer needs more info)

please post the debug output: drush -d upc .

Perhaps you're hitting #1420372: Modules being checked for updates multiple times..? See comment #2 there.

datarazor’s picture

Hi there, I get the exact same issue. Here is the result of my output:

drush -d upc
Bootstrap to phase 0. [0.01 sec, 2.59 MB]                            [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drush() [0.01 sec, 2.76 MB] [bootstrap]
Cache HIT cid: 5.1-commandfiles-0-6f3ae3e8b3564f22a2c62e2d023e3dc5 [0.02 sec, 2.78 MB]                       [debug]
Bootstrap to phase 0. [0.08 sec, 6.11 MB]                                                                [bootstrap]
Bootstrap to phase 6. [0.1 sec, 6.11 MB]                                                                 [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drupal_root() [0.1 sec, 6.11 MB]                                [bootstrap]
Initialized Drupal 7.12 root directory at /Users/xomox/webdev/sites/earthco [0.14 sec, 8.53 MB]             [notice]
Drush bootstrap phase : _drush_bootstrap_drupal_site() [0.14 sec, 8.53 MB]                               [bootstrap]
Initialized Drupal site default at sites/default [0.14 sec, 8.53 MB]                                        [notice]
Cache HIT cid: 5.1-commandfiles-2-c32acd775c18a90c5b41d0fc9accf5ab [0.14 sec, 8.54 MB]                       [debug]
Drush bootstrap phase : _drush_bootstrap_drupal_configuration() [0.14 sec, 8.53 MB]                      [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drupal_database() [0.15 sec, 8.54 MB]                           [bootstrap]
Successfully connected to the Drupal database. [0.15 sec, 8.54 MB]                                       [bootstrap]
Drush bootstrap phase : _drush_bootstrap_drupal_full() [0.16 sec, 9.1 MB]                                [bootstrap]
Cache HIT cid: 5.1-commandfiles-5-61b45d63e5e13883b43827fd25c83ac9 [0.37 sec, 22.63 MB]                      [debug]
Drush bootstrap phase : _drush_bootstrap_drupal_login() [0.38 sec, 22.91 MB]                             [bootstrap]
Successfully logged into Drupal as Anonymous (uid=0) [0.38 sec, 23.08 MB]                                [bootstrap]
Found command: pm-updatecode (commandfile=pm) [0.38 sec, 23.08 MB]                                       [bootstrap]
Loading release_info engine. [0.44 sec, 23.17 MB]                                                           [notice]
Loading version_control engine. [0.45 sec, 23.31 MB]                                                        [notice]
Loading package_handler engine. [0.45 sec, 23.34 MB]                                                        [notice]
Executing: wget --version
Executing: curl --version
Including /Users/xomox/drush/commands/pm/updatecode.pm.inc [0.46 sec, 23.36 MB]                          [bootstrap]
Obtaining admin_menu project path. [0.68 sec, 24.99 MB]                                                      [debug]
Obtaining ctools project path. [0.68 sec, 24.99 MB]                                                          [debug]
Obtaining taxonomy_menu project path. [0.68 sec, 24.99 MB]                                                   [debug]
Obtaining views project path. [0.68 sec, 25 MB]                                                              [debug]
Backend invoke: php /Users/xomox/drush/drush.php  --backend=2 --verbose --debug                            [command]
--root=/Users/xomox/webdev/sites/earthco --uri=http://default batch-process 37 37 2>&1 [0.92 sec, 25.37
MB]
php /Users/xomox/drush/drush.php  --backend=2 --verbose --debug --root=/Users/xomox/webdev/sites/earthco    [notice]
--uri=http://default batch-process 37 37 2>&1 [0.92 sec, 25.38 MB]
Backend invoke: php /Users/xomox/drush/drush.php  --backend=2 --verbose --debug                            [command]
--root=/Users/xomox/webdev/sites/earthco --uri=http://default batch-process 37 37 2>&1 [1.19 sec, 25.41
MB]
php /Users/xomox/drush/drush.php  --backend=2 --verbose --debug --root=/Users/xomox/webdev/sites/earthco    [notice]
--uri=http://default batch-process 37 37 2>&1 [1.19 sec, 25.41 MB]
Backend invoke: php /Users/xomox/drush/drush.php  --backend=2 --verbose --debug                            [command]
--root=/Users/xomox/webdev/sites/earthco --uri=http://default batch-process 37 37 2>&1 [1.47 sec, 25.42
MB]

This last line then loops forever, just gaining in MB with each loop... ad infinitude.

I tried to follow:
http://drupal.org/node/1420372

http://drupal.org/node/1387034

http://drupal.org/node/1352102

But none of the solutions given (or workarounds) help.

Deleted queues table, ran drush cc all, ran drush pm-refresh, restarted my apache and mysql server, nothing improves the situation. I should add that drush works fine on drupal 6 sites, but on drupal 7 sites, it just loops for ever (aka hangs) and doesn't ever do anything.

Additional info:
Was attempting to use:
drush up drupal
to go from Drupal 7.12 to 7.14.

Thanks for any help you can offer.

sam moore’s picture

Same problem here.
On drush pm-update, it seems to do the code updates, but stall at the DB update. just sits there forever.
I finally killed the drush process and ran the updates from the Drupal admin interface, and that was successful.

Would be glad to post a sample site if that would help - I have something in development that's fairly innocuous...?

moshe weitzman’s picture

As I posted in #3, a site-archive posted here would be most appreciated. Also, please try with latest dev snapshot of Drush and not just with 5.1

moshe weitzman’s picture

I just went through the scenario posted here and could not reproduce the bug using current drush from git master

- download drupal-7.12
- install 7.12
- updatecode to 7.14
- updatedb

That sequence ran fine.

sam moore’s picture

Sadly, the site's way too big to upload - just noticed the 3MB limit.
I could pop it on a server somewhere for you if you like - drop me a note at info at resonetrics dot com if that would help..

moshe weitzman’s picture

Yes, that would help. Please upload it and post the URL here. That way, many people can work on the fix.

sam moore’s picture

http://dl.dropbox.com/u/78569432/bluec_db.sql.zip and
http://dl.dropbox.com/u/78569432/bluec.tar.gz

I hacked some users out of the SQL - the current superuser is called "superuser" and its password is "Strang3l0v3" - hope I didn't break the SQL in the process.

Anyway post again if you need more info on the site.
It is up to date, so you may want to roll back a db update or two...

moshe weitzman’s picture

Thanks. I just got this running but I don't see how to reproduce a problem. i temporarily added a new update function and updatedb handled it fine.

sam moore’s picture

Well I'm mystified. I've been seeing this for a few update rounds now, just figured it was something on my VPS.
I'll see if I can get it to happen on my local MAMP setup. Not today though, sorry...

PS just in general, thanks for a lovely piece of kit. It really does help a lot.

sam moore’s picture

Moshe, could you give some idea of the most critical bits of tech in the environment that drush relies on? I'd like to try comparing my VPS vs. local environments, and don't know where to look for significant differences.
So particular libraries? PHP version? Anything like that.

ebenfarnworth’s picture

Subscribing

Anonymous’s picture

My problem was actually that Drush was using an older PHP version on the server. When I configured the DRUSH_PHP variable to the one the sites use things seemed to start working. The other PHP didn't have PDO.

Anonymous’s picture

Aha. My .bash_profile file had an "export PATH" that didn't exist. I updated this to the correct php directory and all is working with drush 5.2.

sam moore’s picture

Just a quick update on this - updated drush to 5.2 and things are back to normal now.

moshe weitzman’s picture

Category: bug » support
Status: Postponed (maintainer needs more info) » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.