Cannot update Virtual Box to work on Rocky 9.8

After the update from Rocky 9.7 to 9.8, my VirtualBox (7.0.26) wants to be updated but it won’t let me. Trying to run it, it says “run /sbin/vboxconfig”. I get compilation errors with unsupported 7.0.26 so I download and try to install latest 7.2.8 (dnf install <7.2.8 rpm file>). I get large numbers of messages about conflicts with old version files, So to get rid of the old version, I did all of these things, retrying the install each time, giving same conflict messages:

“dnf remove <old 7.0 rpm file>” says it is alreadry gone and nothing to do.

“lsmod | grep vbox” shows no vbox modules currently installed

“dnf clean all” removes 77 files

Getting desperate, I now try to remove all traces of vbox 7.0 by strongarm methods:

/etc/vbox was already empty

“rm -rf /usr/share/virtualbox/src/vboxhost” and attempted install – same errors

Cleaned out /usr/bin/vbox, /usr/bin/Virtualbox, /usr/lib/virtualbox, /usr/share/virtualbox/nls, stale link from /usr/src/vboxhost-7.0.26 to /usr/share/virtualbox/src/vboxhost.

Now the files mentioned in the install conflict messages all do not exist, but I still get the errors on attempted dnf install. If I try to just reinstall the old version 7.0 from the rpm, dnf says it is already installed. Can someone tell me: (1) Can any version of VirtualBox be made to install on Rocky 9.8? (2) If so, how do I get rid of the conflicts with 7.0.26 errors? (3) Or is there some other package in Rocky that will let me run my Win 11 virtual machine–preferably one that is compatible with my existing Virtual Box VM files–or reinstall Win 11 in new VM manager if necessary?

Sorry for the long message, I tried to be concise, George Reeke

Have you verified that EPEL is installed. I have not used Virtual Box in a while and I am not sure there are no EPEL dependencies.

Your third option:
I currently use KVM/Qemu as my hypervisor. The Virtual Box .vdi file can be converted into the .qcow2 file by the “qemu-img convert -f <vbdisk.vdi>” command. Make sure to have a backup of the .vdi file first and read up on it.

Lookup KVM/Qemu vs Virtual Box. There are differences in how they are implemented. KVM generally has better performance and is a solid choice. If you go KVM/Qemu, you may need to change from nftables to iptables to enable external network access for your guest. This is done via “/etc/libvirt/network.conf” and change to “firewall_backend=iptables”

Yes, EPEL is instaalled and I use some stuff from there.

Thanks for the KVM/Qemu advice. I am looking into it.

But first, I have a thought based on my original post: “dnf remove” the old Virtual box says it is removed and there is nothing to do, but “dnf install” the new version thinks there are conflicts with the old version. Seems dnf has a conflict in its internal record keeping–part of it thinks the old version is gone, part of it thinks it is still there (and finds conflicts with files I have bodily erased).

So: can someone tell me how to make dnf completely forget it ever knew about the old version? Then it should be able to install the new one OK. I have read the man page several times and cannot see how to do this.

This is a compatibility issue caused by the kernel change in EL 9.8, which removed certain features. See the github issue

It will be automatically resolved once VirtualBox is updated to version 7.2.9. In the meantime, you can also try installing the 7.2.9 test build.

Problem solved. Berlin: Thanks for that hint re 7.2.9. For the record, this is what I did:

Deleted all the old VirtualBox files. Got the VirtualBox 7.2.9 test build. They supplied a .rpm, not a .run as their web page stated. So I used rpm instead of dnf to install it. Used “rpm -iv --nodeps --replacefiles <7.2.9 rpm file>” – the “nodeps” got rid of the conflict messages. This installs with no errors and Virtual Box runs. Can’t run my old Win11 VM though–get the “Duplicate UUID” error discussed elsewhere on the internet. I used the solution of deleting all the files for the old VM except the .vdi virtual hard drive, made a new VM in a new directory, added the old .vdi as its hard drive, and it all works. Hope this helps somebody.

George Reeke