My OS and all packages were updated and functional. I received an upgrade notice for virtualbox, so I let it update. It failed and left my OS unstable.
So I remove it completely:
sudo dpkg --purge virtualbox-qt
sudo dpkg --purge virtualbox
sudo dpkg --purge virtualbox-dkms
sudo dpkg --purge dkms
sudo apt autoremove
sudo find / -name vbox # delete anything found by this command
sudo find / -name virtualbox # delete anything found by this command
Now I have a "clean" system. So I do:
sudo apt install virtualbox
And it always gets this far then freezes:
Setting up virtualbox-dkms (5.2.10-dfsg-6ubuntu18.04.1) ...
Loading new virtualbox-5.2.10 DKMS files...
Building for 4.15.0-23-generic
Building initial module for 4.15.0-23-generic
I can't even ctrl-c, so:
- I kill the process
- of course then
dpkg
says to dosudo dpkg --configure -a
, so I do that, then retry - but it gets stuck in the same place
- so I remove everything again, retry, and it freezes there again, etc.
Some notes:
- When I originally installed vbox I used a script to sign its modules so I don't need to disable secure boot. I don't want to disable secure boot now either.
- Is there a way I can examine some log to tell me what is going wrong? I looked at
/var/log/syslog
but there is nothing interesting in there.
I finally figured out that apt provides
5.2.10
but oracle's latest is5.2.12
.So I added the key and repository to apt. Then installed
virtualbox-5.2
package. It works.Not ideal, because there's all sorts of stuff that now wants to remove it and install
virtualbox
instead, and I need to remember to disallow that every time.But at least it works. Once
5.2
is in the apt repos, I guess I can switch back.I installed virtualbox 5.2 on Ubuntu 18.04 but it does not work. See did not working instruction (if you are interested in it) https://www.virtualbox.org/wiki/Linux_Downloads
On my other computer with Linux Mint 18.3 Sylvia everything work after simple command: