0

I tried to follow another question that had the same problem but the command:

sudo apt-get install linux-headers-$(uname -r) build-essential virtualbox-5.1 dkms
returns E: Package 'virtualbox-5.1' has no installation candidate
Can anyone help me with this?

I had this all working then I rebooted and my virtualbox installation had vanished .... which I'm sure is a whole another can of worms. I just want Virtualbox installed. Please help.

Just FYI I try and install this through Ubuntu Software (after downloading 5.1) and the Install button goes gray for about two seconds then in my launcher an icon comes up and says "waiting to install"

A solution to either of these problems would suffice .. help.

George Udosen
  • 36,677
Trenton
  • 71
  • Did these linux-headers-$(uname -r) build-essential dkms install when you tried? There are two options to installing virtualbox 1) from ubuntu repos, 2) from deb file downloaded from oracle site. The issue your having is that the version you seek is too recent to be found in the official repos. So that won't fly – George Udosen Sep 17 '17 at 14:13
  • No ... it returned .... Reading package lists... Done Building dependency tree
    Reading state information... Done Package virtualbox-5.1 is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source

    E: Package 'virtualbox-5.1' has no installation candidate I downloaded the deb from oracle site, when I try and install it via the Software center it installs for 2 secs then puts an icon on my launcher says waiting to install and never does anything ... is there another way to do this?

    – Trenton Sep 17 '17 at 14:16
  • By return you mean it didn't install? Run which virtualbox – George Udosen Sep 17 '17 at 14:17
  • i did not install ... at least I dont think it did .. the message I received and posted did not look very promising – Trenton Sep 17 '17 at 14:19
  • ok, now run this from terminal. First change into the folder with that deb file then run sudo dpkg -i <name_of_virtualbox_file>.deb – George Udosen Sep 17 '17 at 14:21
  • 1
    A MILLION thank you's for the expert and fast answers ... it looks like it is working now.!! – Trenton Sep 17 '17 at 14:24
  • Great glad I could help! – George Udosen Sep 17 '17 at 14:25

1 Answers1

-1

Install gdebi:

sudo apt-get install gdebi

Then download the .deb file and run:

gdebi your_file.deb 

(First cd to where your file is.)

Eliah Kagan
  • 117,780
joblade
  • 61
  • 1
  • 5