Vagrant on Windows 10 error when you run Vagrant up


I got Vagrant and Virtual Box running on my laptop running WIndows 10 without an issue.

But when I tried to get a vagrant box up it started giving the following error,

$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'scotch/box'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'scotch/box' is up to date...
==> default: Setting the name of the VM: my-project_default_1443152333300_24531
==> 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: E_FAIL
VBoxManage.exe: error: Failed to create the host-only adapter
VBoxManage.exe: error: Operation canceled by the user
VBoxManage.exe: error: Details: code E_FAIL (0x80004005), component VirtualBoxWrap, interface IVirtualBox
VBoxManage.exe: error: Context: "enum RTEXITCODE __cdecl handleCreate(struct HandlerArg *)" at line 71 of file VBoxManageHostonly.cpp

To fix this I followed these steps,

Went to VirtualBox window and,

  1. Open VirtuaBox
  2. Go to File->Preferences->Network->Host-only Networks
  3. Create Manually a new adapater like as follow:

IPv4: 192.168.2.1 (in my example my vm ip is 192.168.2.2 you must use the 3 first parts equal as your ip address and replace the last one by 1)

Mask: 255.255.255.0

BTW I was trying to up the LAMP box given by Scotch.io. You can get here, https://box.scotch.io/

Advertisements

Let me know what you think .. :)

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s