graham's avatar
Level 12

Fix for Vagrant/Homestead - El Capitan

It looks like the Beta of OS X (El Capitan) breaks Vagrant.

It's reported that this is because /usr/bin is no longer writeable and anything that was previously installed there (e.g. Vagrant) is removed.

This is the fix that worked for me:

sudo ln -s /opt/vagrant/bin/vagrant /usr/local/bin/vagrant

Hat tip to pointless ramblings: http://pointlessramblings.com/posts/El_Capitan/

0 likes
16 replies
olimorris's avatar

Great tip @Graham . I had a few problems with Yosemite beta (admittedly I was running XAMPP) at the time so I may give El Capitan a whirl.

Are you enjoying it so far?

graham's avatar
Level 12

@olimorris no problems with it apart from homestead failing to start because of the Vagrant issue.

The only real difference I'm seeing so far is a performance boost, especially on Safari.

mikebronner's avatar

I did not experience these issues in Beta 2 (just updating in case anyone else is reading this looking for compatibility issues).

raphael's avatar

Graham, are you sure about that command? On my El Capitan there is no /opt/ directory in root:

/opt/vagrant/bin/vagrant: No such file or directory
AlexanderWright's avatar

Bother. I'm getting the following error:

Bringing machine 'default' up with 'virtualbox' provider...
==> default: Checking if box 'laravel/homestead' is up to date...
==> default: Clearing any previously set network interfaces...
There was an error while executing `VBoxManage`, a CLI used by Vagrant
for controlling VirtualBox. The command and stderr is shown below.

Command: ["hostonlyif", "create"]

Stderr: 0%...
Progress state: NS_ERROR_FAILURE
VBoxManage: error: Failed to create the host-only adapter
VBoxManage: error: VBoxNetAdpCtl: Error while adding new interface: failed to open /dev/vboxnetctl: No such file or directory
VBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component HostNetworkInterface, interface IHostNetworkInterface
VBoxManage: error: Context: "int handleCreate(HandlerArg*, int, int*)" at line 66 of file VBoxManageHostonly.cpp
Prullenbak's avatar

I had the same problem as @AlexanderWright Reinstalled Virutalbox (5.0.4) and then got the error

The provider 'virtualbox' that was requested to back the machine
'default' is reporting that it isn't usable on this system. The
reason is shown below:

Vagrant has detected that you have a version of VirtualBox installed
that is not supported. Please install one of the supported versions
listed below to use Vagrant:

4.0, 4.1, 4.2, 4.3

Then also reinstalled vagrant, and now it seems to be working again...

mark's avatar

After upgrading to ElCap, I had similar issues to that mentioned above: I upgraded to VirtualBox 5.0.6 then re-installed Vagrant 1.7.4 to get back up and running.

5 likes
cynosure's avatar

Just wanted to confirm that Mark's steps worked for me!! Thanks.

1 like
erikverbeek's avatar

After updating to El Capitan I got the following error when trying to run Homestead. "The guest machine entered an invalid state while waiting for it to boot."

Updating VirtualBox and Vagrant worked for me too. Thanks for the tip Mark.

1 like
foodics's avatar

After upgrading I get this:

default: Warning: Connection timeout. Retrying...

Fo multiple times and then nothing, Any Ideas?

1 like
livingos's avatar

Reinstall/update VirtualBox and Vagrant and everything will be well.

robjbrain's avatar

I've had the same issue after upgrading to el capitan, re-installed virtualbox and vagrant, but now vagrant up leeds to endless "default: Warning: Connection timeout. Retrying..."

Had a google but can't find any solutions from people having the same message. Anyone else encountered this?

robjbrain's avatar

Found the answer myself here:

http://stackoverflow.com/questions/22575261/vagrant-stuck-connection-timeout-retrying#answer-23095019

I'll summarise incase anything ever happens to that link.

It's because the virtual box is waiting for some sort of user input, e.g. an enter key to say what mode to boot into. You can get around it like this:

  1. Leave vagrant up running with it's connection timeout retrying errors.
  2. Open a second terminal window
  3. vboxmanage list runningvms
  4. You should see something like: "homestead" {8ab82fe5-2005-4eec-8bdf-2cace9dad657}
  5. vboxmanage controlvm homestead keyboardputscancode 1c
  6. Go back to the first terminal window and it should now boot up

Please or to participate in this conversation.