Course M103 - Create user assignment

I am working on Lab exercise of creating user, there are 4 steps
1- run on port 27000
2-authentication is enabled
3-When your config file is complete, launch mongod with the --config command line option:
4-Once mongod is running, open a new Terminal window and use the following command to create an admin user. You will need to create this user in order to validate your work.
I have launch the IDE.
For step 1 I have run mongod – port 27000 command
step 2 mongod --auth
then I copied the create user command and run it, getting below message.

Please help me with correct steps and procedure.

Hi @Nitin_Hase from what I can see, based on your notes above, is you’re trying to start mongod twice. Once with the --port 27000 option and then the second time with --auth. If that’s true, then --auth is never enabled. This would explain why your test is failing.

What the lab wants you to do is to create a config file that sets the port and enables auth. In addition to the lecture material, you can fine more information about the configuration file options in the documentation. Once you get both of those options set and run mongod -f mognod.conf things should work better for you.

2 Likes

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.