VirtualBox: Module vboxdrv not found in directory /lib/modules/5.9.8-2-MANJARO

I am using Manjaro version

Linux XXXX-manjaro 5.9.8-2-MANJARO #1 SMP PREEMPT Wed Nov 18 06:38:03 UTC 2020 x86_64 GNU/Linux

I tried to install virtual box and it got installed using the below steps

sudo pacman -S virtualbox

Then i tried to load the kernel module

sudo pacman -S linux59-virtualbox-host-modules – I hope this is the right module

sudo modprobe vboxdrv

Getting error as modprobe: FATAL: Module vboxdrv not found in directory /lib/modules/5.9.8-2-MANJARO

Need your assistance on the same

Does this not help?

https://wiki.manjaro.org/index.php/VirtualBox

1 Like

@tuxmanjarino _ I tried that link but the kernel version was 5.4 in the document and they loaded linux54-virtualbox-host-modules but for version 5.9 not sure which version of hostmodules to load

It clearly states:

To install VirtualBox, you need to install the packages virtualbox and linux*-virtualbox-host-modules . The latter must match the version of the kernel you are running.

yeah i tried to install sudo pacman -S linux59-virtualbox-host-modules following my version 5.9 but getting as error if i try to do vboxreload

Why not simply reboot the system? :slight_smile:

Hi @bogdancovaciu did a reboot and tried the command but getting failed to load the module again, what else do i need to check ?

$ sudo modprobe vboxdrv [12:42:26]
[sudo] password for sampath:
modprobe: FATAL: Module vboxdrv not found in directory /lib/modules/5.9.11-3-MANJARO
FAIL: 1

Ok, this is not quite consistent and i don’t know how you do the updates and the installation. This is what should make things work:

sudo pacman-mirrors -f5 && sudo pacman -Scc && sudo pacman -Syyu virtualbox virtualbox-guest-iso linux59-virtualbox-host-modules

Reboot after that.

2 Likes

I had the same problem! The error is happening because you installed virtualbox before installing the kernel headers. Even though your virtualbox installation is fine, the kernel modules were not built.

A easy solution would be reinstall virtualbox after installing the kernel header. This will make sure that virtualbox kernel modules are build against your kernel

Also remember you’ll be needing community/virtualbox-host-dkms for host kernel modules

1 Like

@bogdancovaciu - It is working now. Thankyou so much for your assistance . I could able to load the module. Works like charm !

Thankyou @BangaliBabu

1 Like

Is this not something a package manager should solve (pull in the necessary dependencies) ?

Wiki says $ sudo pacman -Syu virtualbox [etc…], OP was on an old kernel and did sudo pacman -S virtualbox .

Well not exactly. Dealing with things like kernel headers is not that straight forward. Mainly because you can’t always be sure which Kernel the user is running. This is why applications that need to use kernel headers require manual installations of the kernel headers

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.