Reputation: 607
I just install mongodb 3.2 on my Windows 8.1 64bit and run the server with below command:
mongod --dbpath "d:\mongodb\data"'
and run mongo
, when I try to create a new user for root access with below command, I get error,
db.createUser(
... {
... user: "admin",
... pwd: "1",
... roles: [ "root" ]
... }
... )
Upvotes: 1
Views: 2600
Reputation: 607
I can find my fault , I have Bitnami server in my Windows and when I run mongo
command, in fact I connected to Bitnami mongodb instance.
I stop the Bitanmi and my problem solved.
Thanks
Upvotes: 1