我尝试安装apt-get install virtualbox
,但由于依赖性问题而失败。
修复它-我试过了sudo dpkg --configure -a
,但过了一会儿就卡住了。
现在,当我尝试安装其他( git )时,它又回到了同样的问题:
guy@desktop:~$ sudo apt-get -f install
[sudo] password for guy:
E: dpkg was interrupted, you must manually run 'sudo dpkg --configure -a' to correct the problem.
guy@desktop:~$ sudo dpkg --configure -a
Setting up virtualbox-dkms (5.2.10-dfsg-6ubuntu18.04.1) ...
Removing old virtualbox-5.2.10 DKMS files...
-------- Uninstall Beginning --------
Module: virtualbox
Version: 5.2.10
Kernel: 4.15.0-23-generic (x86_64)
-------------------------------------
Status: This module version was INACTIVE for this kernel.
depmod...
DKMS: uninstall completed.
------------------------------
Deleting module version: 5.2.10
completely from the DKMS tree.
------------------------------
Done.
Loading new virtualbox-5.2.10 DKMS files...
Building for 4.15.0-23-generic
Building initial module for 4.15.0-23-generic
答案1
使用 VirtualBox v5.2 时遇到同样的问题
尝试:
sudo dpkg -r virtualbox
或者
sudo dpkg -P virtualbox
如果仍然询问 - 使用sudo dpkg --configure -a