2

This question already has an answer here:

I am using Ubuntu 16.04 64-bit. I was trying to uninstall VirtualBox, but I got a lot of errors which ended with a warning telling me that my Software Centre has failed. I restarted the system and was going to try again. I ran: apt-get update and apt-get upgrade before trying anything else.

When I ran the upgrade command, the VirtualBox automatically got installed along with it, but after throwing a lot of warnings at me (I don't remember exactly what those were).

I think I should uninstall this and start fresh but when I try to uninstall using apt-get remove virtualbox* --purge, I got these results:

ananthan@ananthan-X556UQK~$ sudo apt-get remove virtualbox* --purge 
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'virtualbox-source' for glob 'virtualbox*' 
Note, selecting 'virtualbox-guest-utils' for glob 'virtualbox*' 
Note, selecting 'virtualbox-ose' for glob 'virtualbox*' 
Note, selecting 'virtualbox-guest-modules' for glob 'virtualbox*' 
Note, selecting 'virtualbox-guest-additions-iso' for glob 'virtualbox*' 
Note, selecting 'virtualbox-guest-dkms' for glob 'virtualbox*' 
Note, selecting 'virtualbox-dkms' for glob 'virtualbox*'
Note, selecting 'virtualbox-ext-pack' for glob 'virtualbox*' 
Note, selecting 'virtualbox' for glob 'virtualbox*' 
Note, selecting 'virtualbox-guest-source' for glob 'virtualbox*' 
Note, selecting 'virtualbox-ose-fuse' for glob 'virtualbox*' 
Note, selecting 'virtualbox-qt' for glob 'virtualbox*' 
Note, selecting 'virtualbox-2.0' for glob 'virtualbox*' 
Note, selecting 'virtualbox-2.1' for glob 'virtualbox*' 
Note, selecting 'virtualbox-2.2' for glob 'virtualbox*' 
Note, selecting 'virtualbox-modules' for glob 'virtualbox*' 
Note, selecting 'virtualbox-3.0' for glob 'virtualbox*' 
Note, selecting 'virtualbox-3.1' for glob 'virtualbox*' 
Note, selecting 'virtualbox-3.2' for glob 'virtualbox*' 
Note, selecting 'virtualbox-4.0' for glob 'virtualbox*' 
Note, selecting 'virtualbox-4.1' for glob 'virtualbox*' 
Note, selecting 'virtualbox-4.2' for glob 'virtualbox*' 
Note, selecting 'virtualbox-4.3' for glob 'virtualbox*' 
Note, selecting 'virtualbox-5.0' for glob 'virtualbox*' 
Note, selecting 'virtualbox-5.1' for glob 'virtualbox*' 
Note, selecting 'virtualbox-dbg' for glob 'virtualbox*' 
Note, selecting 'virtualbox-guest-X11' for glob 'virtualbox*' 
Note, selecting 'virtualbox-guest-additions' for glob 'virtualbox*' 
Package 'virtualbox-ose' is not installed, so not removed 
Package 'virtualbox-ose-fuse' is not installed, so not removed 
Note, selecting 'virtualbox-dkms' instead of 'virtualbox-modules' 
Package 'virtualbox-2.0' is not installed, so not removed 
Package 'virtualbox-2.1' is not installed, so not removed 
Package 'virtualbox-2.2' is not installed, so not removed 
Package 'virtualbox-3.0' is not installed, so not removed 
Package 'virtualbox-3.1' is not installed, so not removed 
Package 'virtualbox-3.2' is not installed, so not removed 
Package 'virtualbox-4.0' is not installed, so not removed 
Package 'virtualbox-4.1' is not installed, so not removed 
Package 'virtualbox-4.2' is not installed, so not removed 
Package 'virtualbox-4.3' is not installed, so not removed 
Package 'virtualbox-5.0' is not installed, so not removed 
Package 'virtualbox-guest-additions' is not installed, so not removed 
Package 'virtualbox-5.1' is not installed, so not removed. Did you mean 'virtualbox-5.1:i386'?   
Package 'virtualbox' is not installed, so not removed 
Package 'virtualbox-dbg' is not installed, so not removed 
Package 'virtualbox-dkms' is not installed, so not removed 
Package 'virtualbox-ext-pack' is not installed, so not removed

It is telling me that it is unable to install anything because nothing has been installed, however I am able to open VirtualBox so it must be installed. I am apprehensive about trying it out in this form.

How do I uninstall this? Or should I try to use this as it is?

marked as duplicate by Eric Carvalho, Charles Green, Anwar, Elder Geek, waltinator May 9 '17 at 15:32

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 1
    Maybe you are using Oracle VirtualBox instead of the VirtualBox from the official Ubuntu 16.04 repositories. When you open VirtualBox and select Help -> About VirtualBox does it say "Oracle"? – karel May 2 '17 at 10:45
  • 1
    How did you install VIrtualbox in the first, this will determine how its removed. – George Udosen May 2 '17 at 11:21
  • @karel. Thanks a lot. I had installed the oracle VirtualBox and that was the problem. I believe I managed to uninstall it now. – ANANDA PADHMANABHAN S May 2 '17 at 11:39
  • 1
    This tells you which version you have sudo dpkg -l | grep virtualbox - then, if installed, remove it with e.g. sudo apt-get purge virtualbox-5.1:i386. – Takkat May 2 '17 at 11:46
  • 1
    @Takkat a better command might be dpkg -l *virtualbox* | grep ii, as this would catch more, ie: virtualbox-5.1.22, etc. and only show installed packages. – heynnema May 2 '17 at 13:53
1

Maybe you are using Oracle VirtualBox instead of the VirtualBox from the official Ubuntu 16.04 repositories. When you open VirtualBox and select Help -> About VirtualBox does it say "Oracle"? If so, the terminal output in your question indicates that VirtualBox from the default Ubuntu repositories is not currently installed.

I had installed Oracle VirtualBox and that was the problem.

Not the answer you're looking for? Browse other questions tagged or ask your own question.