How to completely uninstall VirtualBox?

Discussions related to using VirtualBox on Windows hosts.
Post Reply
Peppy
Posts: 5
Joined: 25. Apr 2020, 00:59

How to completely uninstall VirtualBox?

Post by Peppy »

Error message when trying to start a VM
Error message when trying to start a VM
vbox_fail2.png (55.04 KiB) Viewed 15105 times
Host OS: Windows 10 Pro, version 1909 (4/8/2020_, os build 18363.778
VirtualBox version: 6.1 (various) and 6.0 (various)
Guest OS: Ubuntu 18.04.4, 64-bit

I'm trying to uninstall VirtualBox and install another version. Using the standard Windows 10 "Add or Remove" programs tool, I removed VBox 6.1.4 and installed 6.1.0. When I tried to run either an existing virtual machine or a new virtual machine, I got an error popup: "Failed to open a session for the virtual machine ...".

When I uninstalled VBox 6.1.0 and re-installed VBox 6.1.4, I got the same message.

When I installed VBox 6.1.0, I got the same message. Sample error popup shown below.

[img]vbox_fail2.png[/img]

From this, I figured that some critical file didn't get deleted by the uninstall, or rewritten during the install. Anyway, right now I can't run ANY virtual machine from VirtualBox. How can I completely uninstall VirtualBox so that it installs correctly?

EDIT: I searched for "can't completely uninstall virtualbox windows 10" on the Web, but I want to ask here before trying any of the solutions the search engine offered.
scottgus1
Site Moderator
Posts: 20945
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows, Linux

Re: How to completely uninstall VirtualBox?

Post by scottgus1 »

We can't see the second image, but the first image, "VERR_NEM_VM_CREATE_FAILED" error, means that some service in Windows 10 that uses Microsoft Hyper-V is active in your host PC OS. In most cases Hyper-V blocks Virtualbox. It is probable that the 6.1.6 you were running had some more code to run under Hyper-V that 6.1.0 does not have.

Chances are there is nothing left over or missing from the Virtualbox installation.

I see that you are trying my suggestion I made in your other topic viewtopic.php?f=6&t=97903&p=474815#p474815 to roll back Virtualbox. I really appreciate your willingness to help. But I had an idea pop in mind that maybe it's Hyper-V that is causing the checksum problem you posted about, not the version of Virtualbox.

Could you pause for a moment, uninstall 6.1.0, and reinstall 6.1.6, and then follow this to remove Hyper-V:

1. Shut down all programs. You will have to reboot your host.

2. Look into the 64-bits tutorial below, 2nd post, points 2 & 3 and ensure that none of these things are running.

3. Find the Command Prompt icon, right click it and choose Run As Administrator.

4. Enter this command:
bcdedit /set hypervisorlaunchtype off
5. Enter this command:
shutdown -s -t 2
6. When the computer turns off, unplug it for 20 seconds. Then plug it in again and boot up Windows 10.

Your Virtualbox should be running now. If Virtualbox still complains of the "VERR_NEM_VM_CREATE_FAILED" error, try all the steps again. If you still have the error, post back exactly what you did and we'll try to help some more.

For further info, see I have a 64bit host, but can't install 64bit guests and https://www.tenforums.com/tutorials/139 ... puter.html
Peppy
Posts: 5
Joined: 25. Apr 2020, 00:59

Re: How to completely uninstall VirtualBox? [SOLVED]

Post by Peppy »

Well, that fixed it. Thanks.

Further details in the other post which you mentioned.
scottgus1
Site Moderator
Posts: 20945
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: VirtualBox+Oracle ExtPack
Guest OSses: Windows, Linux

Re: How to completely uninstall VirtualBox?

Post by scottgus1 »

Thanks, Peppy! So just to doublecheck, you reinstalled 6.1.6 and turned off Hyper-V-related services, then the guest started checksumming properly?
Post Reply