acquia / blt

Acquia's toolset for automating Drupal 8 and 9 development, testing, and deployment.
https://docs.acquia.com/blt/
GNU General Public License v2.0
443 stars 397 forks source link

SQL Sync Fails #3964

Closed mikemadison13 closed 4 years ago

mikemadison13 commented 4 years ago

This may be related to https://github.com/acquia/blt/issues/3658

Describe the bug After upgrading from Drush 9.5.2 to Drush 10.1.1 I can no longer perform blt sync:db operations from the cloud.

Note that earlier today I updated to BLT 11.x and Drupal 8.7.11 without incident in the Lando VM. All works fine. As soon as I update everything else this starts happening.

To Reproduce Steps to reproduce the behavior, ideally starting from a fresh install of BLT:

  1. Clone https://github.com/Drupal4Gov/Drupal-GovCon-2017/ and lando start and ask me to give you access to the DGC sub if you don't have it
  2. Update composer.json to remove the drush constraint and update drupal/core to be ^ instead of ~
  3. Run composer update
  4. Run lando blt sync:db

Expected behavior Database syncs

Detailed error output

lando blt sync:db -vvv
info: Bootstraping...
info: config bootstrap beginning...
debug: Emitting event pre-bootstrap-config
debug: Event pre-bootstrap-config has 0 listeners
verbose: Loading event pre-engine-start priority 2
verbose: Loading event pre-engine-start priority 3
verbose: Plugin lando-core loaded from /snapshot/lando/build/cli/plugins/lando-core/index.js
debug: Plugin lando-core has {"config":{"appEnv":{"COLUMNS":256,"LANDO":"ON","LANDO_WEBROOT_USER":"www-data","LANDO_WEBROOT_GROUP":"www-data","TERM":"xterm","LANDO_HOST_UID":"501","LANDO_HOST_GID":"20","LANDO_HOST_USER":"mike.madison","LANDO_CA_CERT":"/lando/certs/lndo.site.pem","LANDO_CA_KEY":"/lando/certs/lndo.site.key","LANDO_CONFIG_DIR":"/Users/mike.madison/.lando","LANDO_DOMAIN":"lndo.site","LANDO_HOST_HOME":"/Users/mike.madison","LANDO_HOST_OS":"darwin","LANDO_HOST_IP":"host.docker.internal","LANDO_MOUNT":"/app"},"appLabels":{"io.lando.container":"TRUE","io.lando.id":"d89d187b273710cf4de8454d820c113142a2def9"},"gid":"20","uid":"501","username":"mike.madison","caCert":"/Users/mike.madison/.lando/certs/lndo.site.pem","caDomain":"lndo.site","caKey":"/Users/mike.madison/.lando/certs/lndo.site.key","caProject":"landocasetupkenobi38ahsokad89d187b273710cf4de8454d820c113142a2def9"}}
verbose: Plugin lando-events loaded from /snapshot/lando/build/cli/plugins/lando-events/index.js
debug: Plugin lando-events has undefined
verbose: Loading event pre-engine-start priority 1
verbose: Loading event pre-engine-start priority 2
verbose: Plugin lando-networking loaded from /snapshot/lando/build/cli/plugins/lando-networking/index.js
debug: Plugin lando-networking has {"config":{"networkBridge":"lando_bridge_network"}}
verbose: Plugin lando-pantheon loaded from /snapshot/lando/build/cli/plugins/lando-pantheon/index.js
debug: Plugin lando-pantheon has undefined
verbose: Loading event post-bootstrap-config priority 5
verbose: Plugin lando-proxy loaded from /snapshot/lando/build/cli/plugins/lando-proxy/index.js
debug: Plugin lando-proxy has {"config":{"proxy":"ON","proxyCert":"/certs/cert.crt","proxyKey":"/certs/cert.key","proxyName":"landoproxyhyperion5000gandalfedition","proxyDash":"58087","proxyCache":"proxyCache","proxyHttpPort":"80","proxyHttpsPort":"443","proxyHttpFallbacks":["8000","8080","8888","8008"],"proxyHttpsFallbacks":["444","4433","4444","4443"],"proxyDomain":"lndo.site","proxyIp":"127.0.0.1"}}
verbose: Plugin lando-recipes loaded from /snapshot/lando/build/cli/plugins/lando-recipes/index.js
debug: Plugin lando-recipes has undefined
verbose: Plugin lando-services loaded from /snapshot/lando/build/cli/plugins/lando-services/index.js
debug: Plugin lando-services has undefined
verbose: Plugin lando-sharing loaded from /snapshot/lando/build/cli/plugins/lando-sharing/index.js
debug: Plugin lando-sharing has undefined
verbose: Plugin lando-test loaded from /snapshot/lando/build/cli/plugins/lando-test/index.js
debug: Plugin lando-test has {"plugin-test":true}
verbose: Plugin lando-tooling loaded from /snapshot/lando/build/cli/plugins/lando-tooling/index.js
debug: Plugin lando-tooling has undefined
debug: Emitting event post-bootstrap-config
debug: Event post-bootstrap-config has 1 listeners
info: config bootstrap completed.
info: tasks bootstrap beginning...
debug: Emitting event pre-bootstrap-tasks
debug: Event pre-bootstrap-tasks has 0 listeners
debug: Autoloaded task config
debug: Autoloaded task destroy
debug: Autoloaded task info
debug: Autoloaded task list
debug: Autoloaded task logs
debug: Autoloaded task poweroff
debug: Autoloaded task rebuild
debug: Autoloaded task restart
debug: Autoloaded task share
debug: Autoloaded task start
debug: Autoloaded task stop
debug: Autoloaded task version
debug: Autoloaded task init
debug: Autoloaded task ssh
debug: Emitting event post-bootstrap-tasks
debug: Event post-bootstrap-tasks has 0 listeners
info: tasks bootstrap completed.
info: engine bootstrap beginning...
debug: Emitting event pre-bootstrap-engine
debug: Event pre-bootstrap-engine has 0 listeners
debug: Automoved scripts from /snapshot/lando/build/cli/plugins/lando-core/scripts to /Users/mike.madison/.lando/scripts and setting 755
debug: Automoved scripts from /snapshot/lando/build/cli/plugins/lando-pantheon/scripts to /Users/mike.madison/.lando/scripts and setting 755
debug: Automoved scripts from /snapshot/lando/build/cli/plugins/lando-recipes/scripts to /Users/mike.madison/.lando/scripts and setting 755
debug: Automoved scripts from /snapshot/lando/build/cli/plugins/lando-services/scripts to /Users/mike.madison/.lando/scripts and setting 755
debug: Automoved scripts from /snapshot/lando/build/cli/plugins/lando-sharing/scripts to /Users/mike.madison/.lando/scripts and setting 755
debug: Emitting event post-bootstrap-engine
debug: Event post-bootstrap-engine has 0 listeners
info: engine bootstrap completed.
info: Bootstrap completed.
debug: Emitting event cli-answers
debug: Event cli-answers has 0 listeners
debug: Emitting event cli-blt-answers
debug: Event cli-blt-answers has 0 listeners
debug: Emitting event cli-run
debug: Event cli-run has 0 listeners
debug: Emitting event cli-blt-run
debug: Event cli-blt-run has 0 listeners
debug: Emitting event pre-blt
debug: Event pre-blt has 0 listeners
verbose: Running ["/Applications/Docker.app/Contents/Resources/bin/docker","exec","--tty","--interactive","--user","www-data","--workdir","/app","--env","PHP_MEMORY_LIMIT=-1","drupalgovcon_appserver_1","/app/vendor/bin/blt","sync:db","-vvv"] in /Users/mike.madison/git/Drupal-GovCon-2017 with options {"mode":"attach","detached":false}
debug: With stdio={"stdio":["inherit","inherit","ignore"]}, mode=attach, detached=false, cwd=/Users/mike.madison/git/Drupal-GovCon-2017
^Cverbose: /Applications/Docker.app/Contents/Resources/bin/docker,exec,--tty,--interactive,--user,www-data,--workdir,/app,--env,PHP_MEMORY_LIMIT=-1,drupalgovcon_appserver_1,/app/vendor/bin/blt,sync:db,-vvv finished with code 130
debug: Emitting event pre-engine-up
debug: Event pre-engine-up has 0 listeners
^[[Adebug: Engine is up.
debug: Emitting event post-engine-up
debug: Event post-engine-up has 0 listeners
debug: Emitting event pre-engine-isRunning
debug: Event pre-engine-isRunning has 0 listeners
debug: Emitting event post-engine-isRunning
debug: Event post-engine-isRunning has 0 listeners
debug: Logging metrics data {"context":"local","devMode":false,"instance":"d89d187b273710cf4de8454d820c113142a2def9","nodeVersion":"v10.4.1","mode":"cli","os":{"type":"Darwin","platform":"darwin","release":"19.2.0","arch":"x64"},"product":"lando","version":"3.0.0-rc.20","message":"","stack":"Error\n    at module.exports.sh.Promise.try.then (/snapshot/lando/build/cli/lib/shell.js:0:0)\nFrom previous event:\n    at Shell.sh (/snapshot/lando/build/cli/lib/shell.js:0:0)\n    at Object.exports.dockerExec (/snapshot/lando/build/cli/plugins/lando-tooling/lib/utils.js:0:0)\n    at module.exports.lando.Promise.try.then.then.map.each.runner (/snapshot/lando/build/cli/plugins/lando-tooling/lib/build.js:0:0)\n    at runCallback (timers.js:696:18)\n    at tryOnImmediate (timers.js:667:5)\n    at processImmediate (timers.js:649:5)\nFrom previous event:\n    at Object.run (/snapshot/lando/build/cli/plugins/lando-tooling/lib/build.js:0:0)\n    at engineRunner (/snapshot/lando/build/cli/lib/bootstrap.js:0:0)\n    at module.exports.parseToYargs.checkForUpdates.then.lando.bootstrap.then.lando.events.emit.then.then.then.then.then (/snapshot/lando/build/cli/lib/cli.js:0:0)\nFrom previous event:\n    at module.exports.parseToYargs.checkForUpdates.then.lando.bootstrap.then.lando (/snapshot/lando/build/cli/lib/cli.js:0:0)\nFrom previous event:\n    at module.exports.parseToYargs.checkForUpdates.then (/snapshot/lando/build/cli/lib/cli.js:0:0)\n    at runCallback (timers.js:696:18)\n    at tryOnImmediate (timers.js:667:5)\n    at processImmediate (timers.js:649:5)\nFrom previous event:\n    at Object.handler (/snapshot/lando/build/cli/lib/cli.js:0:0)\n    at Object.runCommand (/snapshot/lando/build/cli/node_modules/yargs/lib/command.js:238:44)\n    at Object.parseArgs [as _parseArgs] (/snapshot/lando/build/cli/node_modules/yargs/yargs.js:1063:30)\n    at Function.get [as argv] (/snapshot/lando/build/cli/node_modules/yargs/yargs.js:1004:21)\n    at Cli.run (/snapshot/lando/build/cli/lib/cli.js:0:0)\n    at Object.<anonymous> (/snapshot/lando/build/cli/bin/lando.js:0:0)\n    at Module._compile (pkg/prelude/bootstrap.js:1254:22)\n    at Object.Module._extensions..js (internal/modules/cjs/loader.js:711:10)\n    at Module.load (internal/modules/cjs/loader.js:610:32)\n    at tryModuleLoad (internal/modules/cjs/loader.js:549:12)\n    at Function.Module._load (internal/modules/cjs/loader.js:541:3)\n    at Function.Module.runMain (pkg/prelude/bootstrap.js:1309:12)\n    at startup (internal/bootstrap/node.js:274:19)\n    at bootstrapNodeJSCore (internal/bootstrap/node.js:608:3)","action":"error","created":"2019-12-19T00:18:47.267Z"}
^C
macbookpro-mikemadison:Drupal-GovCon-2017 mike.madison$ 
macbookpro-mikemadison:Drupal-GovCon-2017 mike.madison$ 
macbookpro-mikemadison:Drupal-GovCon-2017 mike.madison$ 
macbookpro-mikemadison:Drupal-GovCon-2017 mike.madison$ lando blt sync:db -v
info: Bootstraping...
info: config bootstrap beginning...
info: config bootstrap completed.
info: tasks bootstrap beginning...
info: tasks bootstrap completed.
info: engine bootstrap beginning...
info: engine bootstrap completed.
info: Bootstrap completed.
[Acquia\Blt\Robo\Tasks\DrushTask] Running /app/vendor/bin/drush cache-clear drush --no-interaction -v --ansi &&
 /app/vendor/bin/drush sql-sync @dgc.test @self --target-dump=/tmp/tmp.target.sql.gz --structure-tables-key=lightweight --create-db --no-interaction -v --ansi &&
 /app/vendor/bin/drush cr --no-interaction -v --ansi &&
 /app/vendor/bin/drush sql-sanitize --no-interaction -v --ansi in /app/docroot
 [success] 'drush' cache was cleared.
 [info] Executing: ssh -o PasswordAuthentication=no capitalcamp.test@staging-7892.prod.hosting.acquia.com 'drush core-status --fields=db-name --format=json --uri=capitalcampstg.prod.acquia-sites.com --root=/var/www/html/capitalcamp.test/docroot'
Enter passphrase for key '/user/.ssh/id_rsa': 
 [info] Executing: /app/vendor/drush/drush/drush core-status --fields=db-name --format=json --uri=http://local.capitalcamp.com --root=/app/docroot
You will destroy data in drupal8 and replace with data from staging-7892.prod.hosting.acquia.com/capitalcampstg.
 [notice] Starting to create database on target.
 [info] Executing: /app/vendor/drush/drush/drush sql-create --create-db --target-dump=/tmp/tmp.target.sql.gz --ansi --no-interaction --structure-tables-key=lightweight --strict=0 --uri=http://local.capitalcamp.com --root=/app/docroot
 [notice] Starting to dump database on source.
 [info] Executing: ssh -o PasswordAuthentication=no capitalcamp.test@staging-7892.prod.hosting.acquia.com 'drush sql-dump --create-db --target-dump=/tmp/tmp.target.sql.gz --ansi --no-interaction --structure-tables-key=lightweight --strict=0 --gzip --result-file=auto --format=json --uri=capitalcampstg.prod.acquia-sites.com --root=/var/www/html/capitalcamp.test/docroot'
Enter passphrase for key '/user/.ssh/id_rsa': 

In ProcessBase.php line 172:

  [InvalidArgumentException]  
  Output is empty.            

Exception trace:
  at /app/vendor/consolidation/site-process/src/ProcessBase.php:172
 Consolidation\SiteProcess\ProcessBase->getOutputAsJson() at /app/vendor/drush/drush/src/Commands/sql/SqlSyncCommands.php:152
 Drush\Commands\sql\SqlSyncCommands->dump() at /app/vendor/drush/drush/src/Commands/sql/SqlSyncCommands.php:59
 Drush\Commands\sql\SqlSyncCommands->sqlsync() at n/a:n/a
 call_user_func_array() at /app/vendor/consolidation/annotated-command/src/CommandProcessor.php:257
 Consolidation\AnnotatedCommand\CommandProcessor->runCommandCallback() at /app/vendor/consolidation/annotated-command/src/CommandProcessor.php:212
 Consolidation\AnnotatedCommand\CommandProcessor->validateRunAndAlter() at /app/vendor/consolidation/annotated-command/src/CommandProcessor.php:178
 Consolidation\AnnotatedCommand\CommandProcessor->process() at /app/vendor/consolidation/annotated-command/src/AnnotatedCommand.php:302
 Consolidation\AnnotatedCommand\AnnotatedCommand->execute() at /app/vendor/symfony/console/Command/Command.php:255
 Symfony\Component\Console\Command\Command->run() at /app/vendor/symfony/console/Application.php:1000
 Symfony\Component\Console\Application->doRunCommand() at /app/vendor/symfony/console/Application.php:255
 Symfony\Component\Console\Application->doRun() at /app/vendor/symfony/console/Application.php:148
 Symfony\Component\Console\Application->run() at /app/vendor/drush/drush/src/Runtime/Runtime.php:118
 Drush\Runtime\Runtime->doRun() at /app/vendor/drush/drush/src/Runtime/Runtime.php:49
 Drush\Runtime\Runtime->run() at /app/vendor/drush/drush/drush.php:72
 require() at /app/vendor/drush/drush/drush:4

sql:sync [--no-dump] [--no-sync] [--runner RUNNER] [--create-db] [--db-su DB-SU] [--db-su-pw DB-SU-PW] [--target-dump TARGET-DUMP] [--source-dump [SOURCE-DUMP]] [--extra-dump] [-h|--help] [-q|--quiet] [-v|vv|vvv|--verbose] [-V|--version] [--ansi] [--no-ansi] [-n|--no-interaction] [-d|--debug] [-y|--yes] [--no] [--remote-host REMOTE-HOST] [--remote-user REMOTE-USER] [-r|--root ROOT] [-l|--uri URI] [--simulate] [--pipe] [-D|--define DEFINE] [--skip-tables-key SKIP-TABLES-KEY] [--structure-tables-key STRUCTURE-TABLES-KEY] [--tables-key TABLES-KEY] [--skip-tables-list SKIP-TABLES-LIST] [--structure-tables-list STRUCTURE-TABLES-LIST] [--tables-list TABLES-LIST] [--notify] [--druplicon] [--xh-link XH-LINK] [--] <command> <source> <target>

[Acquia\Blt\Robo\Tasks\DrushTask]  Exit code 1  Time 48.346s
01:10 total time elapsed.

BLT doctor output

lando blt doctor
+---------------------------+--------------------------------------------+
| Property                  | Value                                      |
+---------------------------+--------------------------------------------+
| %paths.%root              | /app/docroot                               |
| %paths.%site              | sites/default                              |
| %paths.%modules           | sites/all/modules                          |
| %paths.%themes            | sites/all/themes                           |
| %paths.%config-sync       | /app/config/default                        |
| alias-searchpaths.0       | /app/drush/sites                           |
| blt-version               | 11.0.1                                     |
| composer-version          | Composer version 1.8.4 2019-02-11 10:52:10 |
| config-sync               | /app/config/default                        |
| db-driver                 | mysql                                      |
| db-hostname               | database                                   |
| db-name                   | drupal8                                    |
| db-password               | drupal8                                    |
| db-port                   | 3306                                       |
| db-username               | drupal8                                    |
| drupal-settings-file      | sites/default/settings.php                 |
| drupal-version            | 8.8.1                                      |
| drush-alias-files.0       | /app/drush/sites/capitalcamp.site.yml      |
| drush-alias-files.1       | /app/drush/sites/dgc.site.yml              |
| drush-cache-directory     | /var/www/.drush/cache                      |
| drush-conf.0              | /app/vendor/drush/drush/drush.yml          |
| drush-conf.1              | /app/drush/drush.yml                       |
| drush-conf.2              | /app/docroot/sites/default/local.drush.yml |
| drush-script              | /app/vendor/drush/drush/drush              |
| drush-temp                | /tmp                                       |
| drush-version             | 10.1.1                                     |
| modules                   | sites/all/modules                          |
| php-bin                   | /usr/local/bin/php                         |
| php-conf.1                | false                                      |
| php-os                    | Linux                                      |
| root                      | /app/docroot                               |
| site                      | sites/default                              |
| stacks.drupal-vm.inited   | false                                      |
| stacks.dev-desktop.inited | false                                      |
| themes                    | sites/all/themes                           |
| uri                       | http://local.capitalcamp.com               |
+---------------------------+--------------------------------------------+
+----------------------------------------------+--------------------------------------------------------------+
| Check                                        | Problem                                                      |
+----------------------------------------------+--------------------------------------------------------------+
| BehatCheck:checkBaseUrl:uri                  | base_url in tests/behat/local.yml does not match the site    |
|                                              | URI.                                                         |
|                                              |   Behat base_url is set to                                   |
|                                              | http://drupalgovcon.lndo.site.                               |
|                                              |   Drush site URI is set to                                   |
|                                              | http://local.capitalcamp.com.                                |
| ComposerCheck:composer.extra.installer-paths | The Composer configuration for extra.installer-paths differs |
|                                              | from BLT's default, recommended values.                      |
|                                              |   Change your configuration to match BLT's defaults in       |
|                                              |                                                              |
|                                              | vendor/acquia/blt/subtree-splits/blt-project/composer.json.  |
| DrupalCheck:checkDrupalBootstrapped          | Could not bootstrap Drupal via drush without alias.          |
| DrupalCheck:checkDrupalInstalled             | Drupal is not installed.                                     |
|                                              |                                                              |
|                                              | Run `blt drupal:install` to install Drupal locally.          |
| FileSystemCheck:checkFileSystem:%files       | Public files directory is not set.                           |
| FileSystemCheck:checkFileSystem:%private     | Private files directory is not set.                          |
| FileSystemCheck:checkFileSystem:%temp        | Temporary files directory is not set.                        |
| NodeCheck:checkNodeVersionFileExists         | .node-version file exists                                    |
| WebUriCheck:checkUriResponse                 | Did not get a response from http://local.capitalcamp.com     |
|                                              | Is your *AMP stack running?                                  |
|                                              | Is your /etc/hosts file correctly configured?                |
|                                              | Is your web server configured to serve this URI from         |
|                                              | /app/docroot?                                                |
|                                              | Is options.uri set correctly in                              |
|                                              | /app/docroot/sites/default/local.drush.yml?                  |
+----------------------------------------------+--------------------------------------------------------------+
[error]  BLT Doctor discovered one or more critical issues.
For troubleshooting guidance and support, see https://docs.acquia.com/blt/support/ 

System information

Additional context Facepalm.

mikemadison13 commented 4 years ago

I'm currently experimenting with an incremental Drush update. I had been pinned to 9.5.2 and the Drush 10 release says it should work with Drush above 9.6. So, I'm trying a mid-point to bump up to 9.7.x and then to 10.x and we'll see.

mikemadison13 commented 4 years ago

Confirmed. This is an issue with the remote Drush version.

When running Drush 9.5.2 remotely and 10.1.x locally

lando blt sync:db
[Acquia\Blt\Robo\Tasks\DrushTask] Running /app/vendor/bin/drush cache-clear drush --no-interaction --ansi &&
 /app/vendor/bin/drush sql-sync @dgc.dev @self --target-dump=/tmp/tmp.target.sql.gz --structure-tables-key=lightweight --create-db --no-interaction --ansi &&
 /app/vendor/bin/drush cr --no-interaction --ansi &&
 /app/vendor/bin/drush sql-sanitize --no-interaction --ansi in /app/docroot
 [success] 'drush' cache was cleared.
Enter passphrase for key '/user/.ssh/id_rsa': 
You will destroy data in drupal8 and replace with data from staging-7801.prod.hosting.acquia.com/capitalcampdev.
 [notice] Starting to create database on target.
 [notice] Starting to dump database on source.
Enter passphrase for key '/user/.ssh/id_rsa': 

In ProcessBase.php line 172:

  Output is empty.  

sql:sync [--no-dump] [--no-sync] [--runner RUNNER] [--create-db] [--db-su DB-SU] [--db-su-pw DB-SU-PW] [--target-dump TARGET-DUMP] [--source-dump [SOURCE-DUMP]] [--extra-dump] [-h|--help] [-q|--quiet] [-v|vv|vvv|--verbose] [-V|--version] [--ansi] [--no-ansi] [-n|--no-interaction] [-d|--debug] [-y|--yes] [--no] [--remote-host REMOTE-HOST] [--remote-user REMOTE-USER] [-r|--root ROOT] [-l|--uri URI] [--simulate] [--pipe] [-D|--define DEFINE] [--skip-tables-key SKIP-TABLES-KEY] [--structure-tables-key STRUCTURE-TABLES-KEY] [--tables-key TABLES-KEY] [--skip-tables-list SKIP-TABLES-LIST] [--structure-tables-list STRUCTURE-TABLES-LIST] [--tables-list TABLES-LIST] [--notify] [--druplicon] [--xh-link XH-LINK] [--] <command> <source> <target>

[Acquia\Blt\Robo\Tasks\DrushTask]  Exit code 1  Time 01:07
macbookpro-mikemadison:Drupal-GovCon-2017 mike.madison$ drush @dgc.dev status
 Drupal version   : 8.7.11                                                    
 Site URI         : capitalcampdev.prod.acquia-sites.com                      
 DB driver        : mysql                                                     
 DB hostname      : staging-7801                                              
 DB port          : 3306                                                      
 DB username      : s8093                                                     
 DB name          : capitalcampdev                                            
 Database         : Connected                                                 
 Drupal bootstrap : Successful                                                
 Default theme    : twentynineteen                                            
 Admin theme      : seven                                                     
 PHP binary       : /usr/local/php7.2/bin/php                                 
 PHP config       : /usr/local/php7.2/etc/cli/php.ini                         
 PHP OS           : Linux                                                     
 Drush script     : /mnt/www/html/capitalcampdev/vendor/drush/drush/drush     
 Drush version    : 9.5.2                                                     
 Drush temp       : /mnt/tmp/capitalcampdev                                   
 Drush configs    : /etc/drush/drush.yml                                      
                    /mnt/www/html/capitalcampdev/vendor/drush/drush/drush.yml 
                    /mnt/www/html/capitalcampdev/drush/drush.yml              
 Install profile  : lightning                                                 
 Drupal root      : /mnt/www/html/capitalcampdev/docroot                      
 Site path        : sites/default                                             
 Files, Public    : sites/default/files                                       
 Files, Private   : /mnt/files/capitalcamp.dev/sites/default/files-private    
 Files, Temp      : /mnt/tmp/capitalcampdev                                   
Connection to staging-7801.prod.hosting.acquia.com closed.

When running Drush 9.7.1 remotely and 10.1.x locally

lando blt sync:db
[Acquia\Blt\Robo\Tasks\DrushTask] Running /app/vendor/bin/drush cache-clear drush --no-interaction --ansi &&
 /app/vendor/bin/drush sql-sync @dgc.dev @self --target-dump=/tmp/tmp.target.sql.gz --structure-tables-key=lightweight --create-db --no-interaction --ansi &&
 /app/vendor/bin/drush cr --no-interaction --ansi &&
 /app/vendor/bin/drush sql-sanitize --no-interaction --ansi in /app/docroot
 [success] 'drush' cache was cleared.
Enter passphrase for key '/user/.ssh/id_rsa': 
You will destroy data in drupal8 and replace with data from staging-7801.prod.hosting.acquia.com/capitalcampdev.
 [notice] Starting to create database on target.
 [notice] Starting to dump database on source.
Enter passphrase for key '/user/.ssh/id_rsa': 
 [notice] Copying dump file from source to target.

 // Copy new and override existing files at /tmp/tmp.target.sql.gz. The source is                                       
 // capitalcamp.dev@staging-7801.prod.hosting.acquia.com:/home/capitalcamp/drush-backups/capitalcampdev/20191219171735/c
 // apitalcampdev_20191219_171736.sql.gz?: yes.                                                                         

Enter passphrase for key '/user/.ssh/id_rsa': 
 [notice] Starting to import dump file onto target database.
 [success] Cache rebuild complete.
The following operations will be performed:

 * Truncate sessions table.
 * Sanitize text fields associated with users.
 * Sanitize user passwords.
 * Sanitize user emails.
 * Truncate webform submission tables.

 [success] Sessions table truncated.
 [success] user__field_bio table sanitized.
 [success] No text fields for users need sanitizing.
 [success] user__field_drupal_org_username table sanitized.
 [success] user__field_first_name table sanitized.
 [success] user__field_job_title table sanitized.
 [success] user__field_last_name table sanitized.
 [success] No text fields for users need sanitizing.
 [success] user__field_twitter_account table sanitized.
 [success] No text fields for users need sanitizing.
 [success] User passwords sanitized.
 [success] User emails sanitized.
 [success] Webform submission tables truncated.
[Acquia\Blt\Robo\Tasks\DrushTask] Done in 01:56

drush @dgc.dev status
 Drupal version   : 8.7.11                                                    
 Site URI         : http://capitalcampdev.prod.acquia-sites.com               
 DB driver        : mysql                                                     
 DB hostname      : staging-7801                                              
 DB port          : 3306                                                      
 DB username      : s8093                                                     
 DB name          : capitalcampdev                                            
 Database         : Connected                                                 
 Drupal bootstrap : Successful                                                
 Default theme    : twentynineteen                                            
 Admin theme      : seven                                                     
 PHP binary       : /usr/local/php7.2/bin/php                                 
 PHP config       : /usr/local/php7.2/etc/cli/php.ini                         
 PHP OS           : Linux                                                     
 Drush script     : /mnt/www/html/capitalcampdev/vendor/drush/drush/drush     
 Drush version    : 9.7.1                                                     
 Drush temp       : /mnt/tmp/capitalcampdev                                   
 Drush configs    : /etc/drush/drush.yml                                      
                    /mnt/www/html/capitalcampdev/vendor/drush/drush/drush.yml 
                    /mnt/www/html/capitalcampdev/drush/drush.yml              
 Install profile  : lightning                                                 
 Drupal root      : /mnt/www/html/capitalcampdev/docroot                      
 Site path        : sites/default                                             
 Files, Public    : sites/default/files                                       
 Files, Private   : /mnt/files/capitalcamp.dev/sites/default/files-private    
 Files, Temp      : /mnt/tmp/capitalcampdev                                   
Connection to staging-7801.prod.hosting.acquia.com closed.
mikemadison13 commented 4 years ago

@danepowell i would suggest we post a warning somewhere that indicates that you cannot jump directly from Drush 9.5.x to Drush 10.x. Maybe this ticket is sufficient? Otherwise I think we can close this.

See https://github.com/drush-ops/drush/releases/tag/10.0.0-alpha1 for notes re: compatibility with Drush 10.x.

danepowell commented 4 years ago

Thanks for reporting, I've added a warning on this to the BLT 11 release notes: https://support.acquia.com/hc/en-us/articles/360039081454#howtoupgrade

It might also be good to have a dedicated knowledge base entry on this if you're able to create that.

mikemadison13 commented 4 years ago

KB article here - https://support.acquia.com/hc/en-us/articles/360041178353-Updating-to-Drush-10-x

danepowell commented 4 years ago

I noted the "output is empty" message on https://support.acquia.com/hc/en-us/articles/360035203713 since that seemed to be new.

Note sure if this could be prevented with https://github.com/acquia/blt/issues/3685