Score:0

Drush won't run, 'status' shows web directory twice

ng flag

I have a multi-site Drupal 8 install and Drush has stopped working. All Drush commands fail with a "Bootstrap failed" error.

"Drush status" shows the /web dir twice as the root. Manually adding the root (--root:path) results in the same 'Bootstrap Failed" error

Any idea why the web directory would show twice in the root?

SITE@mi3-sr25 [~/public_html/web]# drush status
 PHP binary    : /opt/alt/php73/usr/bin/php
 PHP config    : /opt/alt/php73/etc/php.ini
 PHP OS        : Linux
 Drush script  : /home/SITE/.composer/vendor/drush/drush/drush
 Drush version : 9.7.3
 Drush temp    : /tmp
 Drush configs : /home/SITE/.composer/vendor/drush/drush/drush.yml
 Drupal root   : /home/SITE/public_html/web/web

I've tried Drush 9 and 10. Checked for any duplicate directories, temporarily removed .htaccess No change.

cn flag
Instead of editing your question with SOLVED, you should add an answer with the SOLVED info.
Score:0
ng flag

The problem was that there were copies of the composer.json and composer.lock files in the /web directory. I removed those and now everything is working.

Score:0
jp flag

For me this was happening because I was calling an 'external' drush on the system. While at the same time, a 'local' drush was inside the vendor/ folder via composer requirements.

Same effect: webroot shows twice. Some drush commands running twice.

I simply moved on and started calling the drush inside vendor/, using a symlink for convenience.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.