VirtualBox/Vagrant stopped working after Windows 10 Creators Update - vagrant

I was happily using Vagrant with VirtualBox for my laravel projects (Homestead) but after the Creators Update for Windows 10, VirtualBox stopped working - vagrant up was not throwing any errors and I was even able to vagrant ssh successfully but my web projects were unreachable from the browser.
Initially I was using VirtualBox v.5.1.14 but decided to update to the latest (which is v.5.1.22) - no luck whatsoever, so after reading the answers from this thread I've downgraded to v.5.0.38
Now when I try to vagrant up this error is shown:
vagrant up
Bringing machine 'homestead-7' up with 'virtualbox' provider...
==> homestead-7: Checking if box 'laravel/homestead' is up to date...
==> homestead-7: Resuming suspended VM...
==> homestead-7: Booting VM...
There was an error while executing `VBoxManage`, a CLI used by Vagrant
for controlling VirtualBox. The command and stderr is shown below.
Command: ["startvm", "e5ac5ef8-07fa-412f-b59c-bfd745db047e", "--type", "headless"]
Stderr: VBoxManage.exe: error: Failed to load unit 'cpum' (VERR_INVALID_FLAGS)
VBoxManage.exe: error: Details: code E_FAIL (0x80004005), component ConsoleWrap, interface IConsole
p.s. I've already set Host-Only Network Adapter through preferences in VirtualBox

What I did to resolve the issue was to "plug off" my virtual machine's state using discard, hoping not to lose any information... Now I'm on VirtualBox v.5.1.14 and will stick with it until all things work.

I had to update to Virtualbox Version 5.2 to get my boxes running again.
and also need to reinstall git for windows 2.15.1.2-64 bit and select the option "use windows default console" (cmd.exe) instead of "MinTTY"
With MinTTY the command :
vagrant ssh
will not show the bash command line.
using windows default Console worked.
see more possibe workarounds to this piont also in this git issue
My Working env:
- Windows 10 - 1709 - Build 16299.125
- vagrant 2.0.1
- virtualbox 5.2.0
- git for windows 2.15.1.2. 64 bit

Turning off Hyper-V solved my problem.
Solution:
Control Panel -> Turn Windows Feature on or Off -> Uncheck Hyper-V
I had the same problem. My vagrant up stopped working after the Windows Fall Creators Update (1709). It worked after I turned off Hyper-V.
Current Working Environment:
- Windows 10 (1709)
- Vagrant 1.9.7
- VirtualBox 5.1.32

Related

Change in vagrant requires removal of saved state in VirtualBox

I am running Vagrant 2.2.2 on a MacBook Pro, with VirtualBox, Version 6.0.4 r128413. A Mac update cascaded a need to update these about 2 months ago.
When I enter vagrant status it says "saved". If I run vagrant up the following results:
My-MBP:vbox4 oliverwilliams$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Resuming suspended VM...
==> default: Booting VM...
There was an error while executing `VBoxManage`, a CLI used by Vagrant
for controlling VirtualBox. The command and stderr is shown below.
Command: ["startvm", "894fe7ac-8c87-4c18-8afa-4b24b6268f19", "--type", "headless"]
Stderr: VBoxManage: error: Failed to load unit 'lsilogicscsi' (VERR_SSM_LOADED_TOO_LITTLE)
VBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component ConsoleWrap, interface IConsole
I can "Discard Saved State" and then do vagrant up and it works but that's a pain. I opened the VirtualBox UI, went to Machine > Settings, and under storage (after I discarded saved state but not before), I see Controller:SCSI - no option to change to SATA:AHCI as this post suggests: https://www.virtualbox.org/ticket/18263.
How do I fix this so a saved state can be stored without having to discard it?

VM won't bring up using homestead up

I have no issue running vm's using homestead up but last week I just updated to the latest Windows 10 update and now when I run the command it gives me
There was an error while executing `VBoxManage`, a CLI used by Vagrant
for controlling VirtualBox. The command and stderr is shown below.
Command: ["startvm", "c8da3222-7052-452a-b590-ff7144b50c9e", "--type", "headless"]
Stderr: VBoxManage.exe: error: The virtual machine 'homestead-7' has terminated unexpectedly during startup with exit code 1 (0x1). More details may be available in 'C:\Users\magal\VirtualBox VMs\homestead-7\Logs\VBoxHardening.log'
VBoxManage.exe: error: Details: code E_FAIL (0x80004005), component MachineWrap, interface IMachine
Been searching the web for a solution but got no luck.
Box Version : 2.1.0
Without more info the only advice is to run vagrant destroy && vagrant up If you still have issues after that, consider opening a new issue on https://github.com/laravel/homestead/issues/new
Issue was fixed after upgrading my Virtualbox to 5.2.
On Windows 10, I installed everything as ADMINISTRATOR and only the following configuration worked for me:
Vagrant 1.9.2 : Download Vagrant 1.9.2
Oracle VM VirtualBox 5.1.30 : Download Oracle VM VirtualBox 5.1.30
For older versions of VirtualBox, the virtual machine has terminated unexpectedly.
For newer versions of VirtualBox, the host-only adapter cannot be created.
When you upgrade or downgrade, make sure that you permanently delete (Shift + Delete) the following folders from C:\Users\your-user : .vagrant, .VirtualBox and Virtual VM Machines. When using vagrant up, these folders will be created again.
After each program install and uninstall, make sure to restart your computer. Old files from VirtualMachine and Vagrant are persistent until the OS boots up again.

There was an error while executing `VBoxManage`, a CLI used by Vagrant for controlling VirtualBox. windows 10

I just got laravel homestead to run yesterday using powershell. Now, it won't even run. I just suspended vagrant and turned off my pc. Now it's just giving me this error:
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Checking if box 'laravel/homestead' is up to date...
==> default: Clearing any previously set forwarded ports...
There was an error while executing `VBoxManage`, a CLI used by Vagrant
for controlling VirtualBox. The command and stderr is shown below.
Command: ["modifyvm", "b21f2dd0-7f73-4d0f-b1e0-0f82ecdda1fe",
"--natpf1", "delete", "ssh", "--natpf1", "delete", "tcp33060",
"--natpf1", "delete", "tcp44300", "--natpf1", "delete", "tcp54320",
"--natpf1", "delete", "tcp8000"]
Stderr: VBoxManage.exe: error: Code E_FAIL (0x80004005) - Unspecified
error (extended info not available)
VBoxManage.exe: error: Context: "LockMachine(a->session,
LockType_Write)" at line 493 of file VBoxManageModifyVM.cpp
I had the same problem and the previous answer didn't work for me.
I opened the VirtualBox GUI and saw that the virtual machine was running. I stopped it and then I executed "vagrant up". All worked well.
Ok, so I finally fixed the problem. Tried restarting my laptop and it's not giving me that error anymore. Here's what I did:
Right click on "This PC" / "My Computer" on windows desktop
Select "Properties"
Go to "Advanced" tab
Click "Environment Variables..." at the bottom
Under System Variables click "New..."
Set "Variable name" to "VBOX_INSTALL_PATH"
Set "Variable value" to "C:\Program Files\Oracle\VirtualBox\"
Select "OK" and close all the other settings windows
source: https://github.com/mitchellh/vagrant/issues/3852
Just enable permission for VirtualBox in Security & Privacy
For Mac OS, close all the running VMs and restart the virtual box using following command:
sudo "/Library/Application Support/VirtualBox/LaunchDaemons/VirtualBoxStartup.sh" restart
First of all destroy the virtual box with vagrant destroy.
Navigate to C:\Users\Justice replace justice by username.
Delete the .vagrant.d folder.
Go into VirtualBox VMs folder and delete everything inside it.
Start it again with vagrant up.
It should work fine.
Try to follow these steps
1. Run cmd as Administrator
2. vagrant halt
3. vagrant up
4. if required vagrant provision but once vagrant is up.
Disable Hyper-V virtualization that is enabled in Windows.
Open a command prompt as administrator and run the following command:
dism.exe /Online /Disable-Feature:Microsoft-Hyper-V
Afterwards, reboot the PC and try VirtualBox again.
My error:
Stderr: VBoxManage.exe: error: Failed to open/create the internal network 'HostInterfaceNetworking-VirtualBox Host-Only Ethernet Adapter' (VERR_INTNET_FLT_IF_NOT_FOUND).
VBoxManage.exe: error: Failed to attach the network LUN (VERR_INTNET_FLT_IF_NOT_FOUND)
VBoxManage.exe: error: Details: code E_FAIL (0x80004005), component ConsoleWrap, interface IConsole
I first tried disabling the "VirtualBox Host-Only" adapter. Didn't work. Then tried downgrading virtualbox from 6.1.28 to 6.1.26 and that didn't work. Removed everything and started over with 6.1.26, still didn't work. After going in circles for a while, I realized there was another adapter I did not disable called "Ethernet 5" with a 'VirtualBox Host-Only..." description. Not sure if it was created the first time I ran the virtualbox 6.1.28, but after I disabled it, it worked. Noticed another was created after that ("Ethernet 6"), so pretty sure the first issue was the same as others with the 6.1.28 and then the error changed to what I posted above.
Disable all VirtualBox Host-Only Ethernet Adapter #*, under the Control Panel > Network & Internet > Network Connections.
After the Windows Update, I get this problem too and I think it is the VirtualBox problem. My solution is re-install VirtualBox.
Also make sure VirtualBox directory path C:\Program Files\Oracle\VirtualBox\ is in PATH environment variable.
For me, just restarting the machine solved the problem. I just had install VirtualBox, maybe the paths weren't correctly set.
I was having the same issue and I just had to enable the hardware virtualization in my computer's BIOS as mentioned in Laravel documentation.
If you are using Windows, you may need to enable hardware virtualization (VT-x). It can usually be enabled via your BIOS. If you are using Hyper-V on a UEFI system you may additionally need to disable Hyper-V in order to access VT-x.
May be it to late to provide my experience with this issue. You probably have to restart your machine and after installing virtualbox and make sure the environmental variable has a value of "C:\Program Files\Oracle\VirtualBox"
System Variable Entry
And Path entry at System variable should have %VBOX_MSI_INSTALL_PATH%
%VBOX_MSI_INSTALL_PATH%
MACOS users only -> I had same problem what i did was
Just enable permission for VirtualBox in Security & Privacy for Oracle.
open PowerShell or cmd as administrator
write bcdedit /set hypervisorlaunchtype off
reboot
You might get this error if you are low on free disk space.
1.Go to Oracle Virtual Box
2.Right click on the Virtual Machine and select Discard Saved State.
3.Then try to start the virtual machine using vagrant up.
Full link: https://www.wintips.org/fix-virtualbox-vm-session-was-closed-before-any-attempt-to-power-it-on/

Vagrant up after upgrade to Windows 10

I am trying to vagrant up after my recent upgrade to windows 10, and I get an error:
==> 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: Code E_FAIL (0x80004005) - Unspecified error (extended info not available)
VBoxManage.exe: error: Context: "int __cdecl handleCreate(struct HandlerArg *,int,int *)" at line 66 of file VBoxManageHostonly.cpp
Before the upgrade it worked fine, has anyone figured out how to fix this?
This is how I got my Vagrant to finally work on Windows10:
Uninstall both VirtualBox and Vagrant (backup the old vagrantmachines)
Download and install VirtualBox and the latest Vagrant
There is a released fix for virtual box on https://www.virtualbox.org/ticket/14040
For those using homestead a solution can be found on https://laracasts.com/discuss/channels/general-discussion/windows-10-vagrant-virtualbox-homestead
For some reason the VirtualBox Host-Only Ethernet Adapter was removed once the upgrade to Windows 10 was completed. Removing, rebooting and installing VirtualBox resulted in the installation of the removed Ethernet adapters again and the issue has been solved.
Another fix is to add name: "VirtualBox Host-Only Ethernet Adapter" after config.vm.network in your Vagrant file. In my case:
config.vm.network "private_network", ip: "192.168.33.10", name: "VirtualBox Host-Only Ethernet Adapter"
Vagrant, Virtual Box 4.3
I have upgraded today from Windows 7 Professional to Windows 10.
When I was trying to boot a VM (Laravel Homestead) using vagrant it doesn't start.
I installed VirtualBox and Vagrant (without uninstall and reboot the machine) and then I reboot the machine. Once I did this the VM starts correctly.

Laravel/Homestead - OSX - Vagrant Connection Timeout

Problem
I am attempting to get Laravel Homestead working on my Mac Book Air. I have followed the instruction from http://laravel.com/docs/4.2/homestead but when I vagrant up I get stopped on: default: Warning: Connection timeout. Retrying... After I vagrant up fails because of connection timeout i can not vagrant provision or vagrant reload. I can however vagrant ssh into the machine and I can ping google from the machine. I can also spin up other vagrant boxes on my machine with no problem...
Information:
OS: OSX 10.10 (Yosemite)
Vagrant: 1.6.5
Virtual Box: 4.3.16
I have searched around on the internet and found a few “solutions” that has not worked for me:
Turn on “Hardware Virtualisation”. This is automatically turned on in ant instal based mac computer.
Start VM with v.gui = true. This start the VM with with the server terminal in view. Nothing is throwing any errors. and this did not solve the problem
More Debugging Steps:
Tried just booting up the vagrant box laravel/homestead by running vagrant init laravel/homestead then vagrant up. This still gives the same problem.
I have tried vagrant box laravel/homestead versions 0.1.7, 0.1.8 and 0.1.9(newest) All giving the same problem.
Did you let the vagrant output continue after "default: Warning: Connection timeout. Retrying..." Vagrant may actually be retrying the connection. Sounds like you're exiting out when you see that error instead of waiting for vagrant to finish with an actual exit error
A year old post and maybe you have solved it, but I was struggling with it recently and just managed to solve it.
I had the same problem everything was configured correctly but there was no way to ping 192.168.10.10.
In my case it seemed that net-tools package wasn't installed in my distro (Archlinux) by default so installing it allowed me to connect.
See the relevant section at Archlinux Wiki.
Hope that helps someone.

Resources