Upgrade Mondodb to 3.0. Any help?


#1

Hi,

I am struggling to update the version of Mongodb to 3.0. This is blocking me to connect me to Mongodb database and it’s been a week that I am trying to resolve this issue.

I always get an error:

2016-05-14T22:26:37.082+0000 Error: 18 { ok: 0.0, errmsg: "auth failed", code: 18 } at src/mongo/shell/db.js:1292 exception: login failed

Any ideas?


#2

Searching Google Results :

And that site tells us to do this to Upgrade to MongoDB 3.0:

sudo mv /var/lib/mongodb /tmp
sudo apt-get purge mongodb-org-server
sudo apt-get install -y mongodb-org-server


#3

Hi, i am fairly new to Linux and new to MongoDB and tried the above 3 sudo commands with the following results:
dizid@demo-project:~/workspace (master) $ sudo apt-get install -y mongodb-org-server
Reading package lists… Done
Building dependency tree
Reading state information… Done
The following packages were automatically installed and are no longer required:
mongodb-org-mongos mongodb-org-shell mongodb-org-tools
Use ‘apt-get autoremove’ to remove them.
The following NEW packages will be installed:
mongodb-org-server
0 upgraded, 1 newly installed, 0 to remove and 632 not upgraded.
Need to get 9541 kB of archives.
After this operation, 24.0 MB of additional disk space will be used.
Get:1 http://downloads-distro.mongodb.org/repo/ubuntu-upstart/ dist/10gen mongodb-org-server amd64 2.6.12 [9541 kB]
Fetched 9541 kB in 1s (7425 kB/s)
Selecting previously unselected package mongodb-org-server.
(Reading database … 108037 files and directories currently installed.)
Preparing to unpack …/mongodb-org-server_2.6.12_amd64.deb …
Unpacking mongodb-org-server (2.6.12) …
Processing triggers for man-db (2.6.7.1-1) …
Processing triggers for ureadahead (0.100.0-16) …
Setting up mongodb-org-server (2.6.12) …
Processing triggers for ureadahead (0.100.0-16) …

so, it seems that MongoDB is still at version 2-6-12 and i still get the same error:
2016-10-20T21:18:36.759+0000 Error: 18 { ok: 0.0, errmsg: “auth failed”, code: 18 } at src/mongo/shell/db.js:1210
exception: login failed


#4

Hi NhaTrang,

Have you found a solution yet?
Thank you.