Chapter 1 connecting to shell issue

Hey the solutions have failed to work for me where am i going wrong this is what i pasted in the text part not the terminal “mongodb+srv://” --username m001-student.

The whole thing makes no sense honestly because on the question, they tell you to enter the details on the terminal but it doesnt work and some answers here say enter on the text part and then they say put admin on the database name, of a database which does’nt exist yet so I do not know anymore please help

Please post a screenshot of what you are doing that shows the issue you are having.

This is wrong. You have to enter the command in the terminal, not in the text part.

I had similar problem connecting in IDE back in february 2021.
Got me left the course. Feeling awful.
Tried again this october and using mongo shell PC install instead.
It would be maddening if the problem was caused by " double quote copied from the lecture / atlas connection tab.
Chapter 4 now and I hope I can finish this week.

And then i press the run test button because when i press enter it just goes to the next line and then when i paste in the terminal it says command not found

Hi @Vuyisile_Van_Dave, welcome to the community.
You’re pasting the command in the code editor which is not the right place.

You’ve to paste the command in the terminal(which is below the code editor in black background: terminal 0).

In case you have any doubts, please feel free to reach out to us.

Thanks and Regards.
Sourabh Bagrecha,
Curriculum Services Engineer

Thanks for the response bro but it is still refusing look
Screenshot (78)
When I press enter on the terminal it says command not found and when i click run test, it then logs out the fails on the right of the screen

Hello @Vuyisile_Van_Dave ,

Welcome to the MongoDB community Forums.

Kindly read the error carefully.

mongosh: command not found

Use mongo instead of mongosh, and replace myFirstDatabase with the name of the database i.e. m001. Thanks

Hey the solutions have failed to work for me where am i going wrong…

Please read Chapter 1 IDE Lab won't recognize m001-student as correct - #7 by steevej for a solution.

1 Like

Hi. I am trying to connect from the terminal to the database and I am getting the following error.

"user@M001# mongo “mongodb+srv://” --username m001-estudiante
MongoDB shell version v4.4.3
Enter password:
connecting to: mongodb://,,

*** You have failed to connect to a MongoDB Atlas cluster. Please ensure that your IP whitelist allows connections from your network.
I have the IP configured in the white list to allow them all.

I’m stuck in this part of the course, I appreciate the help

Are you using correct userid/password?

1 Like

Hi, @SriMadhanSP and @Andres_Cano,

Welcome to the MongoDB community forums :sparkles:

Can you please try connecting to your atlas cluster using mongo instead of mongosh ? It will work as expected.

For example:
mongo "mongodb+srv://" --username <username> .

We are working to update the test case to support mongosh . We regret the inconvenience caused to you.

Kushagra Kesav,
CS Engineer

I am new to MongoDB & very little technical background. I am receiving the following & unsure what I’m doing wrong or what Code 1 means.

You are missing – before username and also replace xxxx with your unique sandbox cluster id