VirtualBox 6.1.28 fails to load R0 module (`VERR_LDR_GENERAL_FAILURE`) on Windows - vagrant

VirtualBox 6.1.28 fails to start a box on Windows with the following error:
Failed to load R0 module C:\Program Files\Oracle\VirtualBox/VMMR0.r0:
SUP_IOCTL_LDR_OPEN failed (VERR_LDR_GENERAL_FAILURE).
Failed to load VMMR0.r0 (VERR_LDR_GENERAL_FAILURE).

VirtualBox v. 6.1.28 is buggy, use another version (e.g. 6.1.26 or 6.1.32) which you can download from https://www.virtualbox.org/wiki/Download_Old_Builds_6_1
The issue is tracked as https://www.virtualbox.org/ticket/20694 and was fixed in v. 6.1.32.

A workaround...
https://www.virtualbox.org/ticket/20694
"The Windows Hypervisor-enforced Code Integrity (HVCI) feature rejects the VirtualBox component VMMR0.r0 (*). A workaround is to disable HVCI aka Memory integrity as follows:
On your Windows host, go to Start > Settings > Update & security > Windows Security > Device security > Core isolation details, turn off Memory integrity and reboot the Windows host.
(*) In the Windows Event Log, under Applications and Service Logs\Microsoft\Windows\CodeIntegrity\Operational, an event with ID 3111 ("The file under validation did not meet the hypervisor-protected code integrity (HVCI) policy.") is logged."

Fixed moving to 6.1.26
On Windows 10:
Uninstall VirtualBox using the control panel "Program and functionalities" tool. DO NOT RESTART YET.
Manually check for the following folders and remove them if they are still there:
C:\Program Files\Oracle\VirtualBox
C:\Program Files (x86)\Oracle\VirtualBox
Note: The folders can be in a different place depending where you installed Oracle VirtualBox; make sure to check the correct folder in case you changed the installation directory.
Go to your %userprofile% directory (eg: C:\users\me) and delete the folders:
.VirtualBox
VirtualBox VMs
Go to RegEdit (WIN+R and type regedit) and click on Computer at the very top.
Then click on "Edit" > "Search" or hit CTRL+F. Type virtualbox and tick all checkboxes.
Find the key Oracle > VirtualBox. It should be in
Computer\HKEY_CURRENT_USER\SOFTWARE\Oracle\VirtualBox
Remove the VirtualBox key.
IMPORTANT: RESTART NOW. Restart your computer!
Install VirtualBox again with the new version.
Thanks to: https://forums.virtualbox.org/viewtopic.php?t=82689

I had the same problem and found a solution. You have to open Oracle VM VirtualBox.exe and move into your machine settings, make sure that in Controller: SATA you have only .iso of your machine, if you have something else, delete it, close Oracle VM VirtualBox. In Control panel find programs and features, delete your Oracle VM VirtualBox. Then download Oracle VM VirtualBox again, it's not necessary, which version you will launch but better the latest or the same you had before. After installation check out a capability of your machine, if it works, you may add other .iso back, if it doesn't work, open settings again and Controller: SATA delete all .iso exclude your machine .iso, then launch the machine again.
It works with my virtual machines, if it's not relevant to your occasion, you can try other variants.

Related

Can no longer access WSL2 files from Windows explorer or launch Windows programs from WSL2

I've been running WSL2 on Windows 10 for several months now and just recently lost these abilities. I can still open a WSL2 terminal and interact with my Ubuntu installation there.
Accessing WSL2 files from explorer
I could previously go to \\wsl$\Ubuntu and see all my WSL2 files. I can still see the Ubuntu folder at \\wsl$, but when I try to open it I get a loading bar and nothing happens (even after waiting for a long time):
Also in Powershell:
Opening Windows program from WSL2
Previously I could open Windows programs like explorer and VSCode from a WSL2 terminal with explorer.exe and code respectively. Now when I try this the terminal just hangs and nothing opens.
Note that I can still navigate to /mnt/ and see all my Windows files from the WSL2 terminal.
I'm running Windows 10 Version 1909 (OS Build 18363.1379) and Ubuntu 20.04.1.
I'm not sure I have an answer for you, but some general troubleshooting steps to try:
Exit your instances and try a wsl --shutdown.
If that works, try turning off Windows Fast Startup. Also avoid hibernation. These are known to interfere with some WSL network functionality.
Try adding the following section to your /etc/wsl.conf:
[interop]
enabled = true
This should be the default, but it wouldn't be the first time we've seen WSL not following the defaults for some reason.
Make sure your Windows temp directory is not compressed
Make sure your distribution folder under %userprofile%/Local/AppData/Packages is not compressed, especially the LocalState subdirectory where the ext4.vhdx lives.
If enabled, try turning off Windows Ransomware Protection
I had the same issue (although on Windows 11). It was very annoying. I noticed that after a restart it was ok, but after a few minutes and almost always after running VSCode, it was breaking again. Here's what worked for me:
exporting my distro (wsl --export <Distro> <FileName>)
unregistering it from WSL (wsl --unregister <Distro>)
uninstalling all WSL-related stuff, like the optional Windows feature, the WSL app from the store (I had them both). I also removed WSLg but I'm not sure if that was necessary
restarting
installing again the app from the store (no need to turn on the optional Windows feature anymore in case you are on build 22000 or higher)
finally just reimporting the distro (wsl --import <Distro> <InstallLocation> <FileName>)
After going through the above steps the issue was resolved and now my WSL2 works like a charm.

The Lxss folder in windows for Bash on Ubuntu on Windows is missing

Problem and Hypothesis
It's a pretty simple problem, I just can't find the Lxss folder in LocalAppData which is suppose to store files from the Bash on Ubuntu on Windows.
I only see one of two possibilities for why this is. Either Windows moved the Lxss folder in an update for Bash on Ubuntu on Windows, or it is an error specific to my system that has caused Windows not to create the Lxss folder. I don't think this is the possibility though because it is a fresh install of windows.
Steps I have tried:
Unhiding files and folders in windows
Shutting down Bash on Ubuntu on Windows and refreshing my LocalAppData
Restarting Windows and checking my LocalAppData
Screenshots of LocalAppData:
I can add more information if needed.
It was actually moved in the latest release to :
C:\Users\%USERNAME%\AppData\Local\Packages\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\LocalState\rootfs\
See this blog post from WLS git repo
You have to uncheck "Hide protected operating system files (recommended)" in the folder options window.
The selected solution is old and valid for Ubuntu only.
For Opensuse leap-15.1 users this is different:
C:\Users\"yourusername"\AppData\Local\Packages\46932SUSE.openSUSE-Leap-15-1_022rs5jcyhyac\LocalState\rootfs
The numbers will differ from version to version and may change in the future.
The trick is to look for something related to Linux in C:\Users\"yourusername">\AppData\Local\Packages\"xxxxx"\LocalState\root\fs
where
"yourusername" is your Windows 10 user login
"xxxxx" is a custom name related to the Linux distribution installed
In the latest version of Windows Fall Creator Update, I found it in C:\Users\%USERNAME%\AppData\Local\lxss\

Jenkins / Vagrant / VirtualBox - Virtualbox is running as the system user?

I'm pretty new to both VirtualBox and Vagrant, but not Jenkins. I have a Jenkins build being run on a Windows slave that is running "vagrant up" in a specific directory. There was a problem with the VM- I went to that directory and tried to manually run vagrant up and it started recloning the box. Investigating, the VirtualBox VMs folder is being stored in /Windows/system32... I have looked and the Jenkins process and the VirtualBox process are definately being run as the user account that is running the jenkins slave. If I log into that account and launch virtualbox, it looks for VMs in the account home directory though!
I could probably fix this by pointing both accounts to a third location, but I would like to understand why this is happening. Any takers?
According to the docs, since VirtualBox 4.0, the default location where virtual machines are saved is the current system user's home directory. So:
C:\Documents and Settings\<username> on Windows
/Users/<username> on Mac OS X
/home/<username> on Linux and Solaris
Take a look at the Default Machine Folder settings of the virtualbox on your Windows slave to see if anyone has changed the path to /Windows/System32
File > Preferences > General > Default Machine Folder
Also, I am assuming you are using the jenkins vagrant plugin to spawn your vagrant box? (If not, you should). AFAIK, that plugin doesn't require any system administrator privilege on the slave machine.

Suddenly getting "Failed to load VMMR0.r0 (VERR_LDR_MISMATCH_NATIVE)"

Failed to load VMMR0.r0 (VERR_LDR_MISMATCH_NATIVE)
My VMs on Virtualbox 4.2 (on Windows 7 32-bit) were running absolutely fine until I started installing a new VM, which would not go beyond the Linux boot screen.
I deleted the VM and created new one, but it still didn't run.
So I installed the new version of VirtualBox (version 4.3.6.r91406) and rebooted the machine; but when I started any of my previously working VMs, I got the following error
Failed to open a session for the virtual machine m14
Failed to load VMMR0.r0
(VERR_LDR_MISMATCH_NATIVE
with the following details:
Result Code: E_FAIL (0x80004005)
Component: Console
Interface: IConsole
{8ab7c520-2442-4b66-8d74-4ff1e195d2b6}
On checking the forums, I saw few posts asking to check the .vbox files. In the directory of the VM, there are two, m14.vbox and m14.vbox-prev.
I removed the prev file and restarted the VM, again got same error, and the m14.vbox-prev file came again. So I then removed the original m14.vbox file and renamed the prev file to original and then started the VM: it still didn't work.
Any clues fixing this?
Hi I had the same problem in version 4.3
I disabled the floppy and the CD into the system configuration of the virtual machine and then the machine has started properly without realizing the error.
Add or update the extension pack.
If that doesn't solves the problem, then uninstall the Virtual Box, delete the following folder:
C:\USERS\<username>\AppData\Local\VirtualStore\Program Files\Oracle
then install Virtual Box again and run it as administrator. (In some cases running it as simple user may work too.)
Run as Administrator
I had the same problem after updating from 4.1 or 4.2, to 4.3.18.
I didn't reboot and the "Right click Virtualbox icon - Run as Administrator" technique worked for me (in Windows).
pls run the vbox-ssl-cacertificate.crt file. That may resolve above problem. This solution works for me.
FINALLY.
A while back I turned on ASLR for everything using EMET. Running EMET again and changing it back to the default of "Application OptIn" + reboot fixed it.
Like akshah123 I had driver verifier (verifier.exe) running because I was diagnosing random BSODs on my laptop. Running:
verifier.exe /reset
and then rebooting fixed this issue for me.
Launching VirtualBox as administrator got my VM running as normal.
Didn't need to try any other approach.

Unable to create Genymotion Virtual Device, file is corrupted

I have successfully installed Genymotion and Virtualbox ,but not able to create virtual devices. virtual device is complete download but file is corrupted, not only one but all
If your are using Ubuntu, I just found the soluction!
Run Genymotion as a SUDO. To do that, open your terminal, go to the Genymotion folder and type:
sudo ./genymotion
Now go and download your Virtual Machine!
Hope it works for you too
I am running genymotion on Mac OS X 10.9.2 and must run Genymotion via sudo.
I created a bash script that I run:
#!/bin/bash
sudo /Applications/Genymotion.app/Contents/MacOS/genymotion
I've named the script run-genymotion.sh.
Make sure to chmod +x ./run-genymotion.sh so it is executable.
Then ./run-genymotion.sh to execute the script via terminal.
If you work in some company and your company has cyberroam configured on it, i.e., if there is restricted access for downloading, then you just need to enable downloading on your system. As I was also having this issue, I had downloaded Genymotion(no restriction occur using 'https') but at the time of downloading for the virtual device its showing message for corrupt files, so just enabled download rights from network admin, then it started to download. I had done full installation process 2 times and both the times the first full download(both times) also showed the same 'corrupt files' message but the second download(both times) succeeded.
Check, in case, if it helps!
This happens because you've ran genymotion for the first time as root.
fix it this way :
sudo rm -rf ~/.Genymobile
and now try again to install a virtual device.
Here's how I did mine. Every single virtual device I downloaded in Genymotion, I was told it is corrupted. What is wrong with Genymotion?
Well, TL;DR, locate the downloaded file, open and run with Virtualbox first time, and come back to Genymotion to run it.
Via nautilus, or your file manager, go to ~/.Genymobile/Genymotion/ova
Double click on the .ova file to open in VirtualBox (or right click and Open with VirtualBox)
You should see the genymotion virtual device listed in the list of Virtual devices in your VirtualBox
Try starting the genymotion virtual device in VirtualBox. You should end up with a terminal prompt after boot.
Do reboot -p shutdown to close the terminal
Open genymotion (I do mine as ~/Developments/Genymotion/genymotion/genymotion)
You should see a virtual device listed in Genymotion
Start it, and you're done.
You may execute genymotion using sudo or change file permissions of genymotion and it's files with:
chown -R username:username /path/to/genymotion
Also change file permissions of the deployed images and cached ova files which are probably in ~/.Genymobile/Genymotion
I'm using genymotion on windows and had the same problem.
I've just changed Virtual Prices Path from C drive to D drive (just another drive) and the problem solved.
These steps work for me:
clear cache file in genymotion settings/misc/clear cache
restart genymotion with admin privilleges

Resources