Solvedbento Timeout error during vagrant up

When I run vagrant up on bento/ubuntu-14.04 or bento/centos-7.2, I get a timeout error. Other boxes, such as ubuntu/trusty64, work fine.

I'm in an nested virtualization environment.

  • Host machine is Ubuntu 14.04 (bento/ubuntu-14.04) running on VMware Fusion.
  • Guest machines are running on VirtualBox.

My scenario used to work - I noticed the break when I upgraded to VMware Fusion 8.5. I'm not sure whether that's a factor or a coincidence. VT-x is enabled on the host.

Repro steps

Works as expected: ubuntu/trusty64

root@workstation:~# vagrant init ubuntu/trusty64
A `Vagrantfile` has been placed in this directory. You are now
ready to `vagrant up` your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
`vagrantup.com` for more information on using Vagrant.
root@workstation:~# vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'ubuntu/trusty64'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'ubuntu/trusty64' is up to date...
==> default: Setting the name of the VM: root_default_1475671742463_5033
==> default: Clearing any previously set forwarded ports...
==> default: Fixed port collision for 22 => 2222. Now on port 2200.
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 22 (guest) => 2200 (host) (adapter 1)
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2200
    default: SSH username: vagrant
    default: SSH auth method: private key
    default:
    default: Vagrant insecure key detected. Vagrant will automatically replace
    default: this with a newly generated keypair for better security.
    default:
    default: Inserting generated public key within guest...
    default: Removing insecure key from the guest if it's present...
    default: Key inserted! Disconnecting and reconnecting using new SSH key...
==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
    default: The guest additions on this VM do not match the installed version of
    default: VirtualBox! In most cases this is fine, but in rare cases it can
    default: prevent things such as shared folders from working properly. If you see
    default: shared folder errors, please make sure the guest additions within the
    default: virtual machine match the version of VirtualBox you have installed on
    default: your host and reload your VM.
    default:
    default: Guest Additions Version: 4.3.36
    default: VirtualBox Version: 5.0
==> default: Mounting shared folders...
    default: /vagrant => /root

SSH timeout: bento/ubuntu-14.04

root@workstation:~# vagrant init bento/ubuntu-14.04
A `Vagrantfile` has been placed in this directory. You are now
ready to `vagrant up` your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
`vagrantup.com` for more information on using Vagrant.
root@workstation:~# vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'bento/ubuntu-14.04'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'bento/ubuntu-14.04' is up to date...
==> default: Setting the name of the VM: root_default_1475671874908_72192
==> default: Fixed port collision for 22 => 2222. Now on port 2200.
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 22 (guest) => 2200 (host) (adapter 1)
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2200
    default: SSH username: vagrant
    default: SSH auth method: private key
Timed out while waiting for the machine to boot. This means that
Vagrant was unable to communicate with the guest machine within
the configured ("config.vm.boot_timeout" value) time period.

If you look above, you should be able to see the error(s) that
Vagrant had when attempting to connect to the machine. These errors
are usually good hints as to what may be wrong.

If you're using a custom box, make sure that networking is properly
working and you're able to connect to the machine. It is a common
problem that networking isn't setup properly in these boxes.
Verify that authentication configurations are also setup properly,
as well.

If the box appears to be booting properly, you may want to increase
the timeout ("config.vm.boot_timeout") value.

SSH timeout: bento/centos-7.2

root@workstation:~# vagrant init bento/centos-7.2
A `Vagrantfile` has been placed in this directory. You are now
ready to `vagrant up` your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
`vagrantup.com` for more information on using Vagrant.
root@workstation:~# vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'bento/centos-7.2'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'bento/centos-7.2' is up to date...
==> default: Setting the name of the VM: root_default_1475672366835_73211
==> default: Fixed port collision for 22 => 2222. Now on port 2200.
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 22 (guest) => 2200 (host) (adapter 1)
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2200
    default: SSH username: vagrant
    default: SSH auth method: private key
Timed out while waiting for the machine to boot. This means that
Vagrant was unable to communicate with the guest machine within
the configured ("config.vm.boot_timeout" value) time period.

If you look above, you should be able to see the error(s) that
Vagrant had when attempting to connect to the machine. These errors
are usually good hints as to what may be wrong.

If you're using a custom box, make sure that networking is properly
working and you're able to connect to the machine. It is a common
problem that networking isn't setup properly in these boxes.
Verify that authentication configurations are also setup properly,
as well.

If the box appears to be booting properly, you may want to increase
the timeout ("config.vm.boot_timeout") value.

Versions

root@workstation:~# vagrant --version
Vagrant 1.8.4
root@workstation:~# VBoxManage --version
5.0.26r108824
root@workstation:~# vagrant box list
bento/centos-7.2   (virtualbox, 2.3.0)
bento/ubuntu-14.04 (virtualbox, 2.3.0)
ubuntu/trusty64    (virtualbox, 20160928.0.0)
21 Answers

✔️Accepted Answer

I had these same issues with migrating to bento/ubuntu-16.04 version 2.30 (2.29 worked for me). I am using virtualbox. Looking at the version 2.30 virtual machine, I noticed that network Adapter 1 cable connected was unchecked. Sure enough, I compared the box.ovf files for version 2.29 and 2.30 and the cable="true" setting was missing in 2.30.

I was able to get my vagrant ups to work by changing the following in (mac host) ~/.vagrant.d/boxes/bento-VAGRANTSLASH-ubuntu-16.04/2.30/virtualbox/box.ovf:

Change:
<Adapter slot="0" enabled="true" MACAddress="080027B55B5E" type="82540EM">

to:
<Adapter slot="0" enabled="true" MACAddress="080027B55B5E" cable="true" type="82540EM">

Can someone else confirm this change from 2.29 to 2.30?

Other Answers:

Also if you want to solve this issue via just Tue Vagrantfile: vb.customize ["modifyvm", :id, "--cableconnected1", "on"].

I can confirm that shuhaowu's Vagrantfile fix:

vb.customize ["modifyvm", :id, "--cableconnected1", "on"]

works for bento/ubuntu-16.04 (latest Vagrant, latest VB, MacOS 10.11.6).

Have exactly the same problem with bento/centos-7.2 and bento/ubuntu-14.04, ubuntu/trusty64 is Ok) ( all on VirtualBox MacOS)

It seems that the problem is that for whatever reason the network interfaces inside the VMs interfaces are not configured when VM is booted, so the ssh connection from the host times out after the default 5 mins.

have not looked at it further yet, will revisit when have more time.

actually figure ran into this issue trying to us kitchen. I was able to edit my .kitchen.yml file to force the cable connection:

driver:
name: vagrant
customize:
cableconnected1: "on"

Related Issues:

64
bento Timeout error during vagrant up
I had these same issues with migrating to bento/ubuntu-16.04 version 2.30 (2.29 worked for me) I am ...
12
aws sdk java v2 Java SDK does not support EKS IAM for service accounts
@endre-synnes The issue is due to WebIdentityTokenFileCredentialsProvider is not in the default cred...
9
aws sdk java S3 doesObjectExist throws 403 Forbidden
Thanks @vitorreis for the link This is indeed a feature of S3 to prevent the leakage of whether or n...
65
wslu Cannot create directory "//.cache": Permission denied
Hello Here an improved version Background Information: Build: 17763 WSL: Ubuntu 18.04.03 Version: ws...
331
psutil psutil fails to install on python3.6 and Ubuntu16.04
I was just about to comment the same after I read the install file: https://github.com/giampaolo/psu...
358
atom Sometimes opening a file, Atom does not open in a new tab
This feature is called Pending Pane Items (formerly known as Preview Tabs) – this allows you to quic...
191
steam for linux symbol lookup error: /usr/lib/i386-linux-gnu/libxcb-dri3.so.0: undefined symbol: xcb_send_request_with_fds
Hello @milankragujevic this issue is already being tracked at #4816 Your system information Steam cl...
176
atom MacOS Mojave: The text in the editor is dimmed / hard to read.
Hey folks could you try running this command and then restart Atom: Hat tip to @alexanderyakusik in ...
155
node Error: Cannot find module 'internal/fs' when npm install on mac
If you run rm -rf /usr/local/lib/node_modules/npm and then re-install Node.js does it work? ...
147
node Missing stack traces from async functions after the first await
Thanks! And to put a point on the real problem Version: v7.7.3 Platform: Windows 7x64 The purpose of...
142
atom Add config option for MRU tabs
So a temporary fix for this issue is to insert this into the keymap correct? Prerequisites Can you r...
139
ddev In WSL2 ddev start fails at docker-credential-desktop.exe, "error listing credentials"
I had to set credsStore: in my ~/.docker/config.json .. it was previously set to credentials.exe ...
129
node Fatal error in ../deps/v8/src/api.cc, line 1051
i got it fixed Ran following commands Thanks node version 7.3.0 (even tried with 7.4.0 ...
116
dash to dock Dash to dock shows on lockscreen
Ok resolved the issue by removing default ubuntu-dock@ubuntu.com: The dash to dock isnt disabled whe...
110
cncjs npm v5.0.3 installation integrity checksum failure
@pluggee @nomykk Have you tried npm install --update-binary --no-shrinkwrap? I had luck with that co...
109
node "ReferenceError: v8debug is not defined" when doing remote debug
bnoordhuis is right just add --expose_debug_as=v8debug to the Node parameters text field until JetBr...
108
atom "Multi Cursor on Click" seems to always be disabled in Atom 1.48.0
@HugoMcPhee posted and deleted a comment linking to #20804 which does indeed seem to offer a fix for...
104
nodegit Can't install via NPM
Latest Xcode just straight up broke things all across the world Try running sudo xcode-select --inst...
100
steam for linux Steam fails to start on new account because of outdated libxcb
LD_PRELOAD='/usr/$LIB/libstdc++.so.6 /usr/$LIB/libgcc_s.so.1 /usr/$LIB/libxcb.so.1 /usr/$LIB/libgpg-...
100
termux packages npm install: Unhandled rejection Error: EACCES: permission denied
Give ownership to npm like this: uname -a: Linux localhost 3.18.14-11422779 #1 SMP PREEMPT Thu Jun 1...
96
electron builder Can not build the windows installer on macOS Catalina version 10.15
electron-builder 22.2.0 now includes a targeted workaround extracting the NSIS uninstaller without t...
96
node HTTP/HTTPS client requests throwing EPROTO
It sounds like you are trying to use port 80 for https? Reproduced via: My code is littered with bot...
91
electron builder Built application displays nothing but a white screen
If any of you guys use React Router one of the thing that might break your Electron build is Browser...
86
alacritty Tmux austostart?
It should be like this: Which operating system does the issue occur on? MacOS Catalina I understood ...
84
node Debugging v8.5 - always pauses in async_hooks.js on promise rejection
This also reproes in Node 8.6 Is anyone looking into this? Seems to be affecting quite a few people ...
83
atom Uncaught Error: Setting active pane that is not present in pane container
Alright so as an update [Enter steps to reproduce:] @ungb's repro steps from below: Open Atom with a...
83
atom Font Rendering issue with freetype 2.8.1
Workaround: Prerequisites [X ] Put an X between the brackets on this line Description The fonts are ...
80
node Can’t import fs Promises API with ECMAScript Modules
I may be missing something but: isn't good enough? Version: v10.2.1 Platform: Windows 10 64-bit Subs...
79
toggldesktop Linux: Ubuntu 16.04 installs GStreamer 1.0 series, not 0.10 series, by default
And a quick workaround tested on my machine with Ubuntu 16.10: In Ubuntu 16.04 (xenial) the core des...
78
alacritty Support for Alt+key (option as meta)
With latest alacritty and tmux I finally got forward and backward movement with the following: ...
78
node Chrome DevTools not able to connect to Node inspect since 7.5.0
I suspect #9691 is responsible Version: 7.5.0 ...
76
termux app 403 forbidden while update or pkg Install
If someone facing the issue when you run pkg install ... Issue : when ever I try to update / upgrade...
75
gitsome Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-7SrToZ/gitsome/
I had the same problem on OSX and Solve my issue (I have both python versions installed). ...
71
polybar Dropping Unmatched Character
OK after quite a while fighting with this I've managed to get rid of the warnings On my (Arch) box s...
68
atom Unable to installing atom-amd64.deb on Ubuntu 17.04
I had the same issue when installing on 17.04 Prerequisites Put an X between the brackets on this li...
67
node setInterval callback function unexpected halt
@apapirovski @benjamingr @Fishrock123 I was just able to reproduce this with a smaller example 😁 I ...
65
node crypto, bad decrypt
Ok so the problem is in padding This is actually a common issue when users are encrypting in one lan...
64
atom [1.19.0] [macOS] Atom CLI doesn't open native tabs
@dannyradden open file /Applications/Atom.app/Contents/Resources/app/src/main-process/atom-window.js...
63
steam for linux Steam crashes at launch (since last update or the one before) on Kubuntu 19.04
Any progress? Cuda is essential to many So until a fix steam is unusable forever to us Tired of tryi...
63
peek convert fails due to resource limits
I think I've found the issue or at least a workaround Hi I'm on Debian with version below ...
59
electron builder Error: Application entry file "build/electron.js" in the "<path>/dist/mac/<app-name>/Contents/Resources/app.asar" does not exist.
Somehow setting files work Version: 19.49.0 Target: mac I'm using create-react-app and also followed...
57
electron builder dev-app-update.yml not found
Maybe this will help someone for solving this issue For me it worked creating the dev-app-update.yml...
57
electron builder Unable to access a file inside asar pacakge
I understand that it will directly copy the file inside myscripts folder instead of the complete hie...
56
xrdp Problem on debian - black screen
Hi I ran into the same issue on Debian testing and opened a bug on the Debian bug tracking system (D...
54
systemd systemd can't handle the process previlege that belongs to user name startswith number, such as 0day
Let's look if it's actually invalid.. Submission type Bug report systemd version the issue has been ...
54
hyper Drag and drop does not work, in the terminal window anymore
guys I create a plugin for this: https://github.com/qweasd1/hyper-drop-file just hyper install hyper...
53
community edition MS Teams don't work
As a quick and dirty hack: edit the service open the “Advanced” section Seeing error when trying to ...
52
singularity /bin/bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
This worked for me: Enjoy. Hi The wrapper that starts my app tries to perform some setlocale command...
51
node Bundle node 8 with npm 4 until npm 5 is fixed
Or maybe just run npm install -g npm@4 If npm 5 isn't working for you instead of adding vitriol to a...
50
alacritty Alt-Left/Right and Home/End don't work and prevent alacritty from closing
@spacecowboy I added the following lines to support skipping words via Alt+Left and Alt+Right on mac...