Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Vagrant is attempting to interface with the UI in a way that requires a TTY

Problem: vagrant up fails with the error below. I am running vagrant on Windows 7 and the base box is Ubuntu )( files.vagrantup.com/precise32.box ).

how can it be fixed?

    vagrant.bat up

Bringing machine 'default' up with 'virtualbox' provider...
[default] Clearing any previously set forwarded ports...
[default] Clearing any previously set network interfaces...
[default] Available bridged network interfaces:
1) Intel(R) PRO/1000 EB Network Connection with I/O Acceleration
2) Intel(R) PRO/1000 PL Network Connection
Vagrant is attempting to interface with the UI in a way that requires
a TTY. Most actions in Vagrant that require a TTY have configuration
switches to disable this requirement. Please do that or run Vagrant
with TTY.

Process finished with exit code 1

thanks

like image 700
sl5 Avatar asked May 13 '14 13:05

sl5


5 Answers

This worked for me on cygwin:

Or add this to ~/.bashrc:

export VAGRANT_DETECTED_OS=cygwin

Then I got the "Vagrant displays a message that it needs to run some internal upgrades..."

Edit - Oops! Spoke to soon. During its updates, I got Warning: Authentication failure. Retrying... until timeout :P

Edit 2 - I was able to fix it by setting config.ssh.private_key_path to the .vagrant.d/insecure_private_key in my Windows user's home directory.

like image 154
user151841 Avatar answered Sep 23 '22 05:09

user151841


I had the same error while destroying a Vagrant Box. I simply added -f and it did the job.

vagrant destroy m001 -f

This is happening because when script attempts vagrant destroy, Vagrant asks for [Yes/No] confirmation. Adding -f skips that.

like image 41
Zwadderich Avatar answered Sep 22 '22 05:09

Zwadderich


I got the same error after upgrading Vagrant from 1.4 to 1.6.3 (Windows 7).

Running VAGRANT_HOME\bin\vagrant.exe manually resolved this issue for me:

  • Execute VAGRANT_HOME\bin\vagrant.exe
  • Vagrant displays a message that it needs to run some internal upgrades
  • "Press any key to continue"...
  • Once the process finished (it took several minutes), I was able to proceed with Vagrant instance launch as usual.
like image 26
Al Belsky Avatar answered Sep 24 '22 05:09

Al Belsky


This is caused by Vagrant finding multiple Ethernet interfaces that can be used as public network and Vagrant cannot decide which one to use.

There are 3 options:

  1. Deactivate one of the 2 adapters, so that Vagrant can use the other

  2. Specify the Ethernet adapter you would like Vagrant to use in the vagrantfile. Like this:

    app.vm.network "public_network", bridge: "Intel(R) PRO/1000 PL Network Connection"
    
  3. Running the vagrant executable manually as already described in Al Belsky's answer

like image 26
phpPhil Avatar answered Sep 24 '22 05:09

phpPhil


If you are on Windows and are starting Vagrant through MinGW (Git Bash for example) and get this message, try running it once through Windows' default cmd.exe. You are then able to answer the question about your network adapters.

like image 32
chrki Avatar answered Sep 24 '22 05:09

chrki