Forum: 
Tags: 

Unable to Login in Mongodb

chinmaya singh chandel's picture

Can anyone let me know the default username and password for Logging in MongoDB which i have recently downloaded from turnkey template.

Jeremy Davis's picture

turnkey-init

Should get you going... :)

Fu's picture

same issue

Jeremy Davis's picture

Which version are your using? And where/which build? E.g. Hub, VM install from ISO, etc.

I just tested the v14.0 appliance via the Hub and I could log in fine using "admin" and the password I set on launch. It should work fine from the ISO install too (the Hub instances are built from the ISO).

asd5666's picture

Same problem here. Can't login after using template (proxmox) no matter what username/combo I try.

Jeremy Davis's picture

V14.0 definitely works. Although you'll need to install from ISO.
nut's picture

Proxmox with iso ver 14.01

Can't login!

With or whithout ubdates.

 

Jeremy Davis's picture

Hmm, I'll look into it some more.
Jeremy Davis's picture

Apologies to everyone. We will fix this and re-release a fixed build. In the meantime here is a workaround:

In a terminal set your new password:

NEW_PASS="your-new-admin-password"
then copy/paste this:
service mongodb stop
mongod --dbpath /var/lib/mongodb --noauth --fork --logpath /var/log/mongodb/mongodb.reset-admin.log --bind_ip 127.0.0.1
mongo admin --eval "db.changeUserPassword(\"admin\",\"$NEW_PASS\");" 
mongod --dbpath /var/lib/mongodb --shutdown
service mongodb start

[updated] to use the proper syntax for running mongo within a bash script (i.e. "--eval"); plus added "--bind_ip 127.0.0.1" when starting mongo with "--noauth" (so that mongo will only accept local connections while running with no authorisation required).

Post new comment