Impossible to install Virtualbox extension pack

Has anyone installed the Virtualbox extension pack in Silverblue? I tried after installing virtualbox from RPM and from repo, using the GUI and the CLI and had no success. because the structure (/usr/lib/…) is read-only the application cannot install it, and I can’t find an rpm to install it with. The message from the GUI install is:

{

Result Code: NS_ERROR_FAILURE (0x80004005)
Component: ExtPackManagerWrap
Interface: IExtPackManager {70401eef-c8e9-466b-9660-45cb3e9979e4}

}

and from CLI is:

{
VBoxManage extpack install Oracle_VM_VirtualBox_Extension_Pack-*.vbox-extpack
WARNING: The vboxdrv kernel module is not loaded. Either there is no module
available for the current kernel (5.7.16-200.fc32.x86_64) or it failed to
load. Please recompile the kernel module and install it by

       sudo /sbin/vboxconfig

     You will not be able to start VMs until this problem is fixed.

VBoxManage: error: ‘/var/home/fernando/Oracle_VM_VirtualBox_Extension_Pack-*.vbox-extpack’ file not found
VBoxManage: error: Details: code NS_ERROR_FAILURE (0x80004005), component ExtPackFileWrap, interface IExtPackFile, callee nsISupports
VBoxManage: error: Context: “Install(fReplace, __null, ptrProgress.asOutParam())” at line 1360 of file VBoxManageMisc.cpp

}

Any clue as to what I should do?

Silverblue comes with the virtualbox-guest-additions package pre-installed so I’m sure what’s needed on top of that to make it work. What are you missing exactly?

Boy, now I am realy confused. I installed Vbox, then will install Vagrant and only then start to use, right now just for some tests (At this point I am just stepping by step a Vagrant tutorial). What I believed I was trying to install were the Host extensions pack, to access USB and have webcam. But it might well be I just didn’t understand at all. Are there actually host extensions at all? Will USB, Webcam and such work without any extensions pack on my Silverblue host?

P.S: Many thanks for your reply, it is really insightfull. It turns out at some point of my tinkering I did recieve a message from the OS saying something that came around to ‘That pack is already installed’. I think it was when I tried forcing the FS to be read-write (which I could not do) and using Vboxmanage CLI. I just couldn’t wrap my mind around it.

I’m not sure I understood correctly what you are trying to do. Do you want to:

  • Use SIlverblue inside a VirtualBox VM: The virtualbox-guest-additions should probably be enough.
  • Install VirtualBox to run VMs on a Silverblue system: You probably need to use rpm ostree install ./virtualbox.rpm that you downloaded from the VirtualBox webiste.

If you want to run VMs on Silverblue with Vagrant, I would also suggest trying vagrant-libvirt to run them via libvirt.

My physical os is Silverblue, and I want to run Virtualbox on it, to host other OSs. To use USB 2.0 or 3.0 on those OSs, to use a webcam on those OSs and maybe other features, I understood installing VB’s host extension pack is necessary. The pack you are supposed to open with Virtualbox itself. This is what I can’t manage to do.

Then you probably are in the second case:

I also found this that may work (needs to be updated to use the latest version of Fedora): https://gist.github.com/cho2/5afd0fdc3d3d601e9a02bee973bd8917

I’m guessing @loulafg probably knows some of this already (for the extensions pack case), but here’s some detailed background for everyone and some suggestions on what @loulafg can do further down:

Background info

VirtualBox is in an RPM and can be installed with rpm-ostree. However, VirtualBox’s extension pack (which is what @loulafg is asking about) is not in an RPM, so you cannot overlay it on Silverblue.

The filename is Oracle_VM_VirtualBox_Extension_Pack-6.1.12.vbox-extpack, found from https://www.virtualbox.org/wiki/Downloads

The reason why Oracle doesn’t include it in VirtualBox is due to licensing.

Explanation of the (intentional) license issues

VirtualBox is actually Open Core. VirtualBox itself is Open Source, but the extension pack adds “USB 2.0 and USB 3.0 devices, VirtualBox RDP, disk encryption, NVMe and PXE boot for Intel cards”. Yeah, a lot of what’s in the extension pack is actually useful and provided by default in other VMs (such as qemu and anything powered by libvirt).

The licensing? Oracle intentionally muddles with it. They release the extensions as personal use only and go after people (with lawyers) who use it for anything other than personal use. (So, do not use it unless it’s for 100% personal use only or if you pay Oracle for it under their terms.)

Back to the problem

As Silverblue’s OS partition is basically read-only, you cannot add software on top of the base except as RPMs using rpm-overlay. (Or you run it in containers with podman, toolbox, and Flatpak. It’s also possible to compile software an install it locally or in /usr/local/...)

But the VirtualBox extension pack isn’t any of that.

The solution

VirtualBox

As far as I’m aware, there isn’t a solution to use VirtualBox extensions on Silverblue. If you really need the extensions, then I think you will have to use normal, non-Silverblue Fedora for now.

If the features in the VirtualBox extensions pack are just optional for your use, you can use VirtualBox still on Fedora Silverblue — but just with USB1 support and without the other features it provides. It’s not optimal, but it would still work for some uses.

Vagrant with libvirt

If you do need to use vagrant, then rpm-ostree install vagrant-libvirt (and reboot).

Interactive alternatives

If you’re using virtual machines directly, I can highly recommend both GNOME Boxes and virt-manager. Both work fine with other OSes (for example: all Linux distros, Windows, Haiku, FreeDOS, and *cough* even macOS with a bit of fiddling), and don’t require adding any proprietary modules to work.

GNOME Boxes

GNOME Boxes is a nicer, simpler UI. You can install it with rpm-ostree install gnome-boxes (and reboot) or use the Flatpak from Flathub. (If you want to connect to the VM from your host, you should use the overlay. The flatpak version has a different networking mode that prevents this.)

virt-manager

virt-manager is a more advanced UI. It’s not as simple, but provides many more options. Install it as an overlay with rpm-ostree install virt-manager (and reboot). If you have GNOME Boxes and virt-manager

2 Likes

To add a bit more to this (excellent!) response: kernel modules like the VirtualBox extensions must be rebuilt on every kernel release. There are a couple of mechanisms in place to automate this, and most notably in Fedora land, we have DKMS and akmods. akmods is what most of the third party drivers in RPMFusion use, and rpm-ostree does have mechanisms to be able to install these. However, the VBox extensions use DKMS, which rpm-ostree does not support.

2 Likes

Thanks to all. @garrett, your answers really clarified the issue, you are spot on, it´s just impossible to do for now, I should to learn to use one of the other software suits you recomended, I’ll try gnome boxes.