-
-
Notifications
You must be signed in to change notification settings - Fork 6.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
a big bug in yii2 migrate #10301
Labels
Comments
怎么看像是db没有连接上呢 |
You don't have access to DBMS from where you're running migrate. That's not Yii problem but your environment config. |
i can be sure my config is not problems,you can have a try with vagrant environment ,the migration really not work |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
while your enviroment is build by vagrant virtual machine ,the yii2 migrate will be not work properly,but when you ssh to virtual machine it will be work,the Exception is:
D:\www\data\game4039>yii migrate
Warning: Invalid argument supplied for foreach() in D:\www\data\game4039\vendor\yiisoft\y
ii2\helpers\BaseArrayHelper.php on line 121
Call Stack:
0.0005 127104 1. {main}() D:\www\data\game4039\yii:0
0.0095 912056 2. yii\helpers\BaseArrayHelper::merge() D:\www\data\game4039\yii:
24
Yii Migration Tool (based on Yii v2.0.7-dev)
Exception 'yii\db\Exception' with message 'SQLSTATE[HY000] [2002] 由于目标计算机积极拒绝
,无法连接。
'
in D:\www\data\game4039\vendor\yiisoft\yii2\db\Connection.php:538
Stack trace:
#0 D:\www\data\game4039\vendor\yiisoft\yii2\db\Connection.php(848): yii\db\Connection->op
en()
#1 D:\www\data\game4039\vendor\yiisoft\yii2\db\Connection.php(835): yii\db\Connection->ge
tMasterPdo()
#2 D:\www\data\game4039\vendor\yiisoft\yii2\db\Command.php(218): yii\db\Connection->getSl
avePdo()
#3 D:\www\data\game4039\vendor\yiisoft\yii2\db\Command.php(833): yii\db\Command->prepare(
true)
#4 D:\www\data\game4039\vendor\yiisoft\yii2\db\Command.php(361): yii\db\Command->queryInt
ernal('fetchAll', NULL)
#5 D:\www\data\game4039\vendor\yiisoft\yii2\db\mysql\Schema.php(198): yii\db\Command->que
ryAll()
#6 D:\www\data\game4039\vendor\yiisoft\yii2\db\mysql\Schema.php(97): yii\db\mysql\Schema-
The text was updated successfully, but these errors were encountered: