为了账号安全,请及时绑定邮箱和手机立即绑定

找不到命令cim。Drush无法查询数据库

找不到命令cim。Drush无法查询数据库

PHP
RISEBY 2021-04-15 17:19:24
drush cim在Drupal 8中运行命令时,出现以下错误:Command cim was not found. Drush was unable to query the database. As a result, many commands are unavailable. Re-run your command with --debug to see relevant log messages.当我运行该drush cim --debug节目时,以下内容:$ drush cim --debug [preflight] Redispatch to site-local Drush: C:\xampp\htdocs\executive-coatings\docroot/vendor/drush/drush/drush. [preflight] Config paths: C:/xampp/htdocs/executive-coatings/docroot/vendor/drush/drush/drush.yml [preflight] Alias paths: C:/xampp/htdocs/executive-coatings/docroot/drush/sites,C:/xampp/htdocs/executive-coatings/drush/sites,C:/xampp/htdocs/executive-coatings/docroot/drush/sites [preflight] Commandfile search paths: C:\xampp\htdocs\executive-coatings\docroot\vendor\drush\drush\src [debug] Bootstrap further to find cim [0.27 sec, 6.78 MB] [debug] Trying to bootstrap as far as we can [0.27 sec, 6.78 MB] [bootstrap] Drush bootstrap phase: bootstrapDrupalRoot() [0.27 sec, 6.78 MB] [bootstrap] Change working directory to C:\xampp\htdocs\executive-coatings\docroot [0.27 sec, 6.78 MB] [bootstrap] Initialized Drupal 8.6.13 root directory at C:\xampp\htdocs\executive-coatings\docroot [0.28 sec, 6.9 MB] [bootstrap] Drush bootstrap phase: bootstrapDrupalSite() [0.28 sec, 7.15 MB] [bootstrap] Initialized Drupal site default at sites/default [0.29 sec, 7.37 MB] [debug] Could not find a Drupal settings.php file at sites/default/settings.php. [0.29 sec, 7.37 MB] [bootstrap] Drush bootstrap phase: bootstrapDrupalConfiguration() [0.29 sec, 7.37 MB] [debug] Add service modifier [0.29 sec, 7.51 MB]
查看完整描述

3 回答

?
繁华开满天机

TA贡献1816条经验 获得超4个赞

在运行命令drush config-import之前,请先运行此drush cim命令。

欲了解更多信息,请参考这里链接 希望它能解决您的问题。


查看完整回答
反对 回复 2021-04-23
?
翻阅古今

TA贡献1780条经验 获得超5个赞

就我而言,我只是没有启动虚拟服务器(沼泽)。


查看完整回答
反对 回复 2021-04-23
  • 3 回答
  • 0 关注
  • 174 浏览

添加回答

举报

0/150
提交
取消
意见反馈 帮助中心 APP下载
官方微信