1

I am using Ubuntu 12.10.

I downloaded from virtualbox.org the virtualbox package 4.2.4*.deb.

I wanted to install it with dpkg -i and terminal requested me to use command alien instead.

So I did alien <package> then dpkg -i <package> and used virtualbox.

Now I want to uninstall virtualbox (because something went wrong) because it was not installed with sudo apt-get install.

I want to use command dpkg -e <package> or dpkg --purge <package> but this ends with report

file or directory not found

Then

sudo dpkg -l | grep virtualbox

reports:

ii  virtualbox-4.2                                  4.2.4-81684~Ubuntu~quantal                     amd64        Oracle VM VirtualBox
rc  virtualbox-qt                                   4.1.18-dfsg-1ubuntu1.1                         amd64        x86 virtualization solution - Qt based user interface

what should I do next ?

dschinn1001
  • 3,773
  • 6
  • 27
  • 39

4 Answers4

2

Run this command in a terminal window:

sudo apt-get purge virtualbox-4.2 virtualbox-qt

That should remove them both.

Eric Carvalho
  • 53,609
  • 102
  • 137
  • 162
MiJyn
  • 3,326
  • 20
  • 25
  • thank you ! I was blind ! of course sudo apt-get purge virtualbox is not sufficient and so system does not know which package. sudo apt-get purge virtualbox-4.2 virtualbox-qt is the solution ! – dschinn1001 Nov 29 '12 at 18:51
  • Glad to know it works! Could you mark it as the correct answer then? – MiJyn Nov 29 '12 at 18:52
2

You can also use sudo apt-get purge virtualbox*, which should also remove both.

Eric Carvalho
  • 53,609
  • 102
  • 137
  • 162
1

Try like this

sudo apt-get --remove purge virtualbox-4.2 virtualbox-qt
Florian Diesch
  • 86,013
  • 17
  • 224
  • 214
Beginner
  • 491
  • 1
  • 9
  • 28
1

I also had run like this

sudo apt-get purge virtualbox-\*

But was not removing completely

To me following worked (Was trying this on Ubuntu 15.10 and Oracle Virtualbox 5.x)

dpkg -l | grep virtualbox

which listed as below

# dpkg -l | grep virtualbox ii virtualbox-5.0:i386 5.0.12 104815~Ubuntu~wily i386 Oracle VM VirtualBox

Then i used the command

sudo apt-get purge virtualbox-5.0:i386

Basav
  • 111
  • 4