2

When I use VBoxManage to create a vm I'm told I need to have linux-headers-generic installed. So I try sudo apt-get install linux-headers-standard and get this message:

Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package linux-headers-standard

https://www.tecmint.com/install-kernel-headers-in-ubuntu-and-debian/ presents another way to do this:

sudo apt install linux-headers-$(uname -r)

Unfortunately, that doesn't work either. Here's what I get:

Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package linux-headers-4.19.128-microsoft-standard
E: Couldn't find any package by glob 'linux-headers-4.19.128-microsoft-standard'

Any ideas?

neubert
  • 229
  • 4
    Unfortunately, the base WSL2 kernel does not allow modules to be loaded. You will need to compile and use your own kernel build – matigo Jul 07 '21 at 02:03
  • 1
    And to do that, you'll need the Microsoft patches to the kernel, which you can check out here. – NotTheDr01ds Jul 07 '21 at 23:15
  • 1
    Also note that you would need a recent Windows build for Intel nested virtualization (needed to run VirtualBox under Hyper-V, which is used for WSL2) or Windows Insider/Preview if you have an AMD CPU. Even then, it will likely require changes to VirtualBox. This makes it sound like the VirtualBox nested virtualization support may only be for running other hypervisors under VirtualBox, rather than the other way around. Just not sure whether it will work even after you jump through the kernel hoops. – NotTheDr01ds Jul 07 '21 at 23:18
  • even i went through this. https://github.com/microsoft/WSL2-Linux-Kernel/releases/tag/linux-msft-wsl-5.15.90.1 this might help you. – Tallhypnosis373 Apr 15 '23 at 13:27

0 Answers0