简体   繁体   English

随着stdin,start,ssh,stderr和stdout错误,Vagrant up失败

[英]Vagrant up fails with stdin, start, ssh, stderr & stdout errors

I cannot for the life of me...after reinstalling all things VVV/VBox(4.3.10) & running vagrant up --provision figure out why this beauty(VVV) wont run. 我不能为我的生活...重新安装所有的东西VVV / VBox(4.3.10)和运行流浪汉 - 提供弄清楚为什么这个美丽(VVV)不会运行。 I'm unable to access any of the wordpress sites such as http://local.wordpress.dev/ . 我无法访问任何wordpress网站,如http://local.wordpress.dev/

Specs: Windows 8.1 Cygwin 规格:Windows 8.1 Cygwin

Final lines after running the cmd -> vagrant up --provision 运行cmd后的最后一行 - > vagrant up --provision

==> default: http://gruntjs.com/getting-started
==> default: Downloading phpMyAdmin 4.1.14...
==> default: Restart Nginx...
==> default:  * Restarting nginx nginx
==> default:    ...done.
==> default: Cleaning the virtual machine's /etc/hosts file...
==> default: Adding domains to the virtual machine's /etc/hosts file...
==> default:  * Added vvv.dev from /srv/www/vvv-hosts
==> default:  * Added local.wordpress.dev from /srv/www/vvv-hosts
==> default:  * Added local.wordpress-trunk.dev from /srv/www/vvv-hosts
==> default:  * Added src.wordpress-develop.dev from /srv/www/vvv-hosts
==> default:  * Added build.wordpress-develop.dev from /srv/www/vvv-hosts
==> default: -----------------------------
==> default: Provisioning complete in 1636 seconds
==> default: External network connection established, packages up to date.
==> default: For further setup instructions, visit http://vvv.dev
==> default: Running provisioner: shell...
    default: Running: inline script
==> default: stdin: is not a tty
==> default: start: Job is already running: mysql
The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!

chmod +x /tmp/vagrant-shell && /tmp/vagrant-shell

Stdout from the command:



Stderr from the command:

stdin: is not a tty
start: Job is already running: mysql

Where am I going wrong? 我哪里错了?

Add the following line in your Vagrantfile 在Vagrantfile中添加以下行

config.ssh.shell = "bash -c 'BASH_ENV=/etc/profile exec bash'"

This starts bash as a non-login shell, but also tells it to source /etc/profile, which I hypothesised to be the only reason to use a login shell by default. 这将bash作为非登录shell启动,但也告诉它来源/ etc / profile,我假设这是默认情况下使用登录shell的唯一原因。 Works for me with the stock precise64 Vagrant box. 适用于我的股票exact64 Vagrant框。

Not anything you are doing. 不是你在做什么。 Apparently this is a known issue. 显然这是一个已知问题。

I fixed it by running vagrant ssh 我通过运行vagrant ssh修复它

and then 然后

sudo service mysql restart || true

You can find a record of the issue here 您可以在此处找到问题的记录

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM