Unable to connect to IDE for Chapter 4

Hello, I am trying to use the IDE for Chapter 4 but it keeps rejecting me.

I start by entering

mongo “mongodb+srv://sandbox.dlkwv.mongodb.net/myFirstDatabase” --username m001-student

Then I hit Return and enter my password

Then I get - exception: connect failed

Here is the whole output:

user@M001# mongo “mongodb+srv://sandbox.dlkwv.mongodb.net/myFirstDatabase” --username m001-student
MongoDB shell version v4.0.5
Enter password:
connecting to: mongodb://sandbox-shard-00-01.dlkwv.mongodb.net.:27017,sandbox-shard-00-02.dlkwv.mongodb.net.:27017,sandbox-shard-00-00.dlkwv.mongodb.net.:27017/myFirstDatabase?authSource=admin&gssapiServiceName=mongodb&replicaSet=atlas-110s4k-shard-0&ssl=true
2021-05-26T01:03:58.187+0000 I NETWORK [js] Starting new replica set monitor for atlas-110s4k-shard-0/sandbox-shard-00-01.dlkwv.mongodb.net.:27017,sandbox-shard-00-02.dlkwv.mongodb.net.:27017,sandbox-shard-00-00.dlkwv.mongodb.net.:27017
2021-05-26T01:03:58.228+0000 I NETWORK [js] Successfully connected to sandbox-shard-00-02.dlkwv.mongodb.net.:27017 (1 connections now open to sandbox-shard-00-02.dlkwv.mongodb.net.:27017 with a 5 second timeout)
2021-05-26T01:03:58.229+0000 I NETWORK [ReplicaSetMonitor-TaskExecutor] Successfully connected to sandbox-shard-00-01.dlkwv.mongodb.net.:27017 (1 connections now open to sandbox-shard-00-01.dlkwv.mongodb.net.:27017 with a 5 second timeout)
2021-05-26T01:03:58.230+0000 I NETWORK [ReplicaSetMonitor-TaskExecutor] changing hosts to atlas-110s4k-shard-0/sandbox-shard-00-00.dlkwv.mongodb.net:27017,sandbox-shard-00-01.dlkwv.mongodb.net:27017,sandbox-shard-00-02.dlkwv.mongodb.net:27017 from atlas-110s4k-shard-0/sandbox-shard-00-00.dlkwv.mongodb.net.:27017,sandbox-shard-00-01.dlkwv.mongodb.net.:27017,sandbox-shard-00-02.dlkwv.mongodb.net.:27017
2021-05-26T01:03:58.245+0000 I NETWORK [js] Successfully connected to sandbox-shard-00-01.dlkwv.mongodb.net:27017 (1 connections now open to sandbox-shard-00-01.dlkwv.mongodb.net:27017 with a 5 second timeout)
2021-05-26T01:03:58.258+0000 I NETWORK [ReplicaSetMonitor-TaskExecutor] Successfully connected to sandbox-shard-00-00.dlkwv.mongodb.net:27017 (1 connections now open to sandbox-shard-00-00.dlkwv.mongodb.net:27017 with a 5 second timeout)
2021-05-26T01:03:58.284+0000 I NETWORK [ReplicaSetMonitor-TaskExecutor] Successfully connected to sandbox-shard-00-02.dlkwv.mongodb.net:27017 (1 connections now open to sandbox-shard-00-02.dlkwv.mongodb.net:27017 with a 5 second timeout)
2021-05-26T01:03:58.311+0000 I NETWORK [js] Marking host sandbox-shard-00-01.dlkwv.mongodb.net:27017 as failed :: caused by :: Location40659: can’t connect to new replica set master [sandbox-shard-00-01.dlkwv.mongodb.net:27017], err: Location8000: bad auth : Authentication failed.
2021-05-26T01:03:58.313+0000 I NETWORK [js] Marking host sandbox-shard-00-00.dlkwv.mongodb.net:27017 as failed :: caused by :: SocketException: can’t authenticate against replica set node sandbox-shard-00-00.dlkwv.mongodb.net:27017 :: caused by :: socket exception [CONNECT_ERROR] server [sandbox-shard-00-00.dlkwv.mongodb.net:27017] connection pool error: network error while attempting to run command ‘isMaster’ on host ‘sandbox-shard-00-00.dlkwv.mongodb.net:27017
2021-05-26T01:03:58.314+0000 I NETWORK [js] Marking host sandbox-shard-00-02.dlkwv.mongodb.net:27017 as failed :: caused by :: SocketException: can’t authenticate against replica set node sandbox-shard-00-02.dlkwv.mongodb.net:27017 :: caused by :: socket exception [CONNECT_ERROR] server [sandbox-shard-00-02.dlkwv.mongodb.net:27017] connection pool error: network error while attempting to run command ‘isMaster’ on host ‘sandbox-shard-00-02.dlkwv.mongodb.net:27017
2021-05-26T01:03:58.334+0000 I NETWORK [js] Marking host sandbox-shard-00-01.dlkwv.mongodb.net:27017 as failed :: caused by :: Location40659: can’t connect to new replica set master [sandbox-shard-00-01.dlkwv.mongodb.net:27017], err: Location8000: bad auth : Authentication failed.
2021-05-26T01:03:58.334+0000 E QUERY [js] Error: can’t authenticate against replica set node sandbox-shard-00-01.dlkwv.mongodb.net:27017 :: caused by :: can’t connect to new replica set master [sandbox-shard-00-01.dlkwv.mongodb.net:27017], err: Location8000: bad auth : Authentication failed. :
connect@src/mongo/shell/mongo.js:328:13
@(connect):1:6
exception: connect failed

Any thoughts?

Thanks

This really means you have entered the wrong password.

1 Like

I have reset the password I use to login to Mongo DB training, and it still doesn’t like that password.

Is there another password I should be using?

Thanks

Hi @Lyle_Smart,

I tried connecting using your above connection string, it’s working fine for me.

Password I used: m001-mongodb-basics which is also the suggested password for the M001.

Hope it helps !!
Kindly feel free to reach out, if you encounter any further issues.

Kind Regards,
Kushagra

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