2

I have updated to Ubuntu 13.04 and now I can't run virtual-box I have installed dkms many times please help the problem shown is

Result Code: 
NS_ERROR_FAILURE (0x80004005)
Component: 
Machine
Interface: 
IMachine {22781af3-1c96-4126-9edf-67a020e0e858}

Use 'apt-get autoremove' to remove it.
0 upgraded, 0 newly installed, 0 to remove and 182 not upgraded.
N: Ignoring file 'virtualbox.li' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension
N: Ignoring file 'virtualbox.li' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension

I think it might be an underlining issue when I updated. I Tried googling it.

Braiam
  • 67,791
  • 32
  • 179
  • 269
user186275
  • 21
  • 3

4 Answers4

4

Virtual Box does not need DKMS to install but with DKMS the kernel modules will be reinstalled after a kernel upgrade.

After a fresh install it is always a good idea to perform an update of all packages for bugfixes (you have 182 package in the queue there):

sudo apt-get update && sudo apt-get dist-upgrade

Then you may have to load the virtualbox kernel modules only if you had removed DKMS from the default installation.

If this did not resolve your issue you may have installed an incompatible version of Virtual Box still. This needs to be purged before we can install an up to date version. Removing Virtual Box depends very much on how you had installed it in the first place. You may have to run e.g.

sudo apt-get purge virtualbox

or

sudo apt-get purge virtualbox-<xxx> # replace <xxx> with the version installed

After that we can re-install the latest version of virtualbox as depicted in the answer below (I recommend the latest bugfix release from Oracle rather than the version from the repositories):

Takkat
  • 142,284
2

First of all, you have to remove wrong repository:

sudo rm /etc/apt/sources.list.d/virtualbox.li

Then, upgrade your system

sudo apt-get update
sudo apt-get upgrade
rpadovani
  • 1,170
  • 2
    Could you please elaborate what does this do? – Braiam Aug 22 '13 at 11:22
  • sudo rm /etc/apt/sources.list.d/virtualbox.li rm: cannot remove ‘/etc/apt/sources.list.d/virtualbox.li’: No such file or directory and it is installed – user186275 Aug 22 '13 at 12:34
2
sudo rm /etc/apt/sources.list.d/virtualbox.li
sudo apt-get update
sudo apt-get upgrade

Run these commands for update your OS.

The fololowings for install dkms and set for vboxdrv:

sudo apt-get install dkms
sudo /etc/init.d/vboxdrv setup
ubuntu_tr
  • 665
1

Adding to Takkat answer, you have a malformed file name in your /etc/souces.list.d. The best way to solve this is not deleting the file, but renaming it:

sudo mv /etc/apt/sources.list.d/virtualbox.li /etc/apt/sources.list.d/virtualbox.list
sudo apt-get update
sudo apt-get upgrade

This will take away the N: Ignoring file 'virtualbox.li' in directory '/etc/apt/sources.list.d/' as it has an invalid filename extension line, and also will upgrade your 183 packages.

Braiam
  • 67,791
  • 32
  • 179
  • 269
  • hi i still have 182 not upgraded and i tried a purge but the files are still there – user186275 Aug 22 '13 at 12:06
  • Some years ago @htorque posted a solution for bug 611925 to suppress this IMO non fatal apt notice. The dist-upgrade should not stop from a notice on a bad but ignored file anyway. – Takkat Aug 22 '13 at 12:24