从ubuntu卸载mongoDB [英] Uninstall mongoDB from ubuntu

查看:78
本文介绍了从ubuntu卸载mongoDB的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经按照安装MongoDB中的命令安装了MongoDB 3.0.1.在我的ubuntu 14.04 64位系统上的Ubuntu社区版上,我安装了 Robomongo 界面来使用它.

I have installed MongoDB 3.0.1 following the commands in Install MongoDB Community Edition on Ubuntu on my ubuntu 14.04 64 bit system and I installed Robomongo interface to use that.

当我尝试使用Robomongo连接MongoDB时,出现一个错误,提示授权失败.我发现添加了对SCRAM-SHA-1身份验证(MongoDB 3.0+)的支持,这说明了Robomongo 0.8.5不完全支持MongoDB 3.0.X.

When I try to connect MongoDB using Robomongo I get an error that authorization failed. I found Add support for SCRAM-SHA-1 authentication (MongoDB 3.0+) which explains that Robomongo 0.8.5 doesn't support MongoDB 3.0.X fully.

作为回应,我想删除MongoDB 3.0.1并安装MongoDB 2.2.

In response, I want to remove MongoDB 3.0.1 and install MongoDB 2.2.

我尝试了以下命令:

 apt-get remove --purge mongodb

还有

apt-get autoremove --purge mongodb

在两种情况下,我都遇到以下错误:

In both cases I got the following error:

无法打开锁文件/var/lib/dpkg/lock-打开(13:权限被拒绝) E:无法锁定管理目录(/var/lib/dpkg/),您是root吗?"

" Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied) E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?"

任何帮助将不胜感激.

推荐答案

sudo service mongod stop
sudo apt-get purge mongodb-org*
sudo rm -r /var/log/mongodb
sudo rm -r /var/lib/mongodb

这对我有用

这篇关于从ubuntu卸载mongoDB的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆