Creating First Application User, ISSUE: 1)solved, 2) no switch admin, 3) waiting prompt

  1. I run this cmd, because does it give error 48?
    mongod -f mongod.conf
    this solved: deleted fork


  1. how can i switch to the admin user?

solved run
mongo -u m103-admin -p m103-pass --port 27000
use admin

  1. I run this cmd, because are you waiting for it?
    mongo --port 27000 -u m103-admin -p m103-pass --authenticationDatabase admin


<103-admin -p m103-pass --authenticationDatabase admin
MongoDB shell version v4.0.5
connecting to: mongodb://
Implicit session: session { “id” : UUID(“e0e4f122-db44-4247-8a91-9fc7ffdd40e2”) }
MongoDB server version: 4.0.5
Welcome to the MongoDB shell.
For interactive help, type “help”.
For more comprehensive documentation, see
Questions? Try the support group
Server has startup warnings:
2020-09-30T08:26:56.740+0000 I CONTROL [initandlisten] ** WARNING: You are running this process as the root user, which is not recommended.
2020-09-30T08:26:56.740+0000 I CONTROL [initandlisten]
2020-09-30T08:26:56.740+0000 I CONTROL [initandlisten] ** WARNING: This server is bound to localhost.
2020-09-30T08:26:56.740+0000 I CONTROL [initandlisten] ** Remote systems will be unable to connect to this server.
2020-09-30T08:26:56.741+0000 I CONTROL [initandlisten] ** Start the server with --bind_ip to specify which IP
2020-09-30T08:26:56.741+0000 I CONTROL [initandlisten] ** addresses it should serve responses from, or with --bind_ip_all to
2020-09-30T08:26:56.741+0000 I CONTROL [initandlisten] ** bind to all interfaces. If this behavior is desired, start the
2020-09-30T08:26:56.741+0000 I CONTROL [initandlisten] ** server with --bind_ip to disable this warning.
2020-09-30T08:26:56.741+0000 I CONTROL [initandlisten]

Enable MongoDB’s free cloud-based monitoring service, which will then receive and display
metrics about your deployment (disk utilization, CPU, operation statistics, etc).

The monitoring data will be available on a MongoDB website with a unique URL accessible to you
and anyone you share the URL with. MongoDB may use this information to make product
improvements and to suggest MongoDB products and deployment options to you.

To enable free monitoring, run the following command: db.enableFreeMonitoring()
To permanently disable this reminder, run the following command: db.disableFreeMonitoring()

solved : insert create user

this course is bad they ask you to do things that have not been explained previously .
questo corso è pessimo chiedono di fare cose che non sono state spiegate precedentemente.

Thanks, renato

Wrong step and wrong solution for the following.

First part of the lab instructions is

Connect to a mongod instance that has already been started in the background on port 27000

So mongod is already started, no need to start a new one. That’s why you got error 48.

The use of the use command is well explained in M001 which is a prerequisite for this course.

You should now by now that the > sign is an indication that the mongo shell is ready to accept commands. This is well explained in M001 which is a prerequisite for this course.

The lecture Chapter 1: The Mongod - Basic Security: Part 2 well explain how to use createUser().

I am sorry to say but your negative outlook on the course is not founded.

1 Like