Using vget command results in an infinite loop. I have to terminate the loop by hitting ctrl-c.
This symptom happens with Drush 2.1 or current HEAD (2009-Dec-15 bundle, downloaded today). See below for system configuration info.
[user@host html]$ drush vget site_offline
site_offline: "0"
site_offline: "0"
site_offline: "0"
... snip ...
And it happens whether I give a full variable name or a partial one... and I note that the loop stays stuck on the first database result returned:
[user@host html]$ drush vget site
site_403: ""
site_403: ""
site_403: ""
... snip ...
System Configuration
Drupal version is 5.7 (yes, I know it's an old version, I'm preparing to update it now, which is why I'm trying out Drush).
[user@host html]$ drush status
PHP configuration : /etc/php.ini
...snip...
Drupal version : 5.7
Site Path : sites/default
Site URI : http://default
Database Driver : mysql
Database Hostname : localhost
...snip...
Database : Connected
Drupal Bootstrap : Successful
Drupal User : Anonymous
[user@host]$ php --version
PHP 5.2.9 (cli) (built: Jul 22 2009 06:06:23)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies
with eAccelerator v0.9.5.3, Copyright (c) 2004-2006 eAccelerator, by eAccelerator
[user@host]$ uname -a
Linux hostname 2.6.18-028stab064.7-ent #1 SMP Thu Aug 20 22:25:02 MSD 2009 i686 i686 i386 GNU/Linux
I don't know if this is due to the presence of the Zend/eAccelerator opcode cache; I can't disable eAccelerator right now but I'll investigate that soon.
I will also investigate whether this is due to the fact that I'm running against Drupal 5.7... I hope not. I'd like to be able to use Drush to update older sites rather than have to update first, then use Drush!
Comments
Comment #1
greg.1.anderson commentedWhat is the output of
drush -v -d vget site_offline?Comment #2
mcurry commentedComment #3
greg.1.anderson commentedThat is odd indeed. I have no experience with Drupal 5.x; perhaps someone else can help.
In the meantime, I would definitely recommend that you get drush up and running on a scratch Drupal 6 site, and then add in the modules you are using in Drupal 5.7 one at a time, confirming that drush continues to work as you go. This will at least isolate the problem to Drupal 5.7 (which does seem to be the likely culprit, given the warning above on module.inc line 217). This will not be wasted work, as it will allow you to verify that all of the modules you need are available and work before you begin migrating your data.
Comment #4
mcurry commentedThanks for your prompt response. I'll investigate further...
Comment #5
mcurry commentedUpdate, for anyone interested in this issue. I upgrade the site to Drupal 5.21, and all modules are now up-to-date. I don't plan on upgrading to D6 just yet, for a variety of reasons. The issue continues to manifest itself.
edit: removed dumb question. The search continues...
Comment #7
mcurry commentedEdit: second dumb question unasked. Time to go back to db_result() school.
Edit # 2: Looks like
db_result()(which is called bydrush_db_result()in D5 and D6) needs a row cursor parameter in D5 and D6 -- otherwise, it always returns the first row of the resultset. See:#36892: Make db_result more useable.
Also appears that
vgetjust plain doesn't work in D5 (and perhaps D6) based on my research. But, I've been wrong several times today...Comment #8
greg.1.anderson commentedLooks like you're doing some good work tracking down this issue. A few comments and suggestions:
Good luck.
Comment #9
moshe weitzman commentedComment #10
jonhattanIt works for me. Probably fixed in some commit: http://drupalcode.org/viewvc/drupal/contributions/modules/drush/commands...
Comment #11
moshe weitzman commented