Fix performance problems with VirtualBox

Introduction

If you want to use Linux on Windows, a VM is still a good alternative to WSL. Recently I’ve had massive performance problems with my Linux VM’s after installing WSL. Some workarounds are presented below.

Symptoms

The problems were massively noticed by the following abnormalities.

  • VM is freezing while boot

My Kali-VM has partial needed 10 minutes to boot up or freezed while the boot sequence.

  • High CPU-Load after opening Firefox

This error ran through all Linux VMs, after opening Firefox the VM was massively slowing down. While investigating I opened htop and watched the procs what were happening after opening Firefox. To my shock, the load of the individual processes went to 800%.

  • VM is freezing while the Update process

Here the VM froze while updating the packages. Unfortunately, only a snapshot rollback helped here.

Workarounds and Fix

It took me some time to figure out what was happening and what the reason is for this behavior. At least I can say WSL and VirtualBox is not a good combination.

First of all, you need to deinstall WSL from your workstation. For this open Powershell and list your installed Linux distributions.

wsl -l

Now you can deinstall the subsystem from you workstation

wsl –unregister YOUR-SUB-OS

Alternatively, you can also do this via remove programs in the Control Panel.
After this reboot your System.

Check if the error is fixed, if not open Powershell again and run the following command. This disabled the Hyper Virtualization Feature, which is needed for some virtualization solutions like Docker under windows.

bcdedit /set hypervirsorlaunchtype off

This disables the Hyper Virtualization Feature, which is needed for some virtualization solutions like docke runder windows.

Reboot your system. Now the problem should be fixed and the VM will interact more responsive.

🖤 Did this article help you?
Buy me a coffee and support my work to keep this space 🚀 and ad-free. If you can’t, share my work to reach this 📖 out to more people.

Leave a reply

Your email address will not be published. Required fields are marked *