Ubuntu – How to completely uninstall mongodb 2.6.3


I am running the following command:

sudo apt-get remove mongodb

And it's giving this output:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package 'mongodb' is not installed, so not removed
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

But mongodb is still installed on my Ubuntu 13.04 system, so how can I uninstall it..?

Best Answer

Try searching for installed mongo packages with dpkg :

$ sudo dpkg -l | grep mongo

The above command should output a list of packages with mongo in the name.

If files exist on the system, following an apt-get remove mongo, try and run the command again with the --purge switch, using a wildcard search for the name:

sudo apt-get remove mongodb* --purge
Related Question