Mongod runs fine without auth=true, won't start with it?

24 views
Skip to first unread message

Patrick Coleman

unread,
Apr 23, 2016, 8:56:30 AM4/23/16
to mongodb-user
Hi,

Just started with Mongoldb and I'm having a problem with auth. 

I'm using Mongoldb 3.2.5(same problem with 3.2.4) on Ubuntu 14.04.3

After installing Mongoldb everything seems to work fine. I can connect, create
users, read/write, stop/start mongod, the mongo log file has entries saying it
started ok.

As soon as I uncomment "auth=true" in /etc/mongod.conf and try and start
again I get 
mongod start/running, process 5986

but it dies immediately. No entry in the mongod log file or any other log file?

Anyone have an idea what I'm doing wrong?

Thanks.

Pat.



Kevin Adistambha

unread,
May 3, 2016, 1:37:04 AM5/3/16
to mongodb-user

Hi Pat,

After installing Mongoldb everything seems to work fine. I can connect, create
users, read/write, stop/start mongod, the mongo log file has entries saying it
started ok.

How did you install MongoDB?

As soon as I uncomment “auth=true” in /etc/mongod.conf and try and start
again I get
mongod start/running, process 5986
but it dies immediately. No entry in the mongod log file or any other log file?

To enable authentication in MongoDB, please follow the steps outlined in the Enable Client Access Control page.

By default, the startup log for MongoDB should be located in /var/log/upstart/mongod.log and the MongoDB server log should be located in /var/log/mongodb/mongod.log. Do you see any error in any of those two log files?

Could you provide:

  • the contents of the /etc/mongod.conf file
  • the output of db.serverCmdLineOpts().parsed when starting MongoDB without auth

Also, I would recommend you to update to the latest MongoDB version in the 3.2.x series, which is currently 3.2.6 for bugfixes and improvements. Installation instructions are provided in the Install MongoDB Community Edition on Ubuntu page.

Best regards,
Kevin

Reply all
Reply to author
Forward
0 new messages