Chapter2: Connecting to Atlas Cluster via Mongo Shell

Hello peeps,

I was unable to connect to the class Atlas cluster and I am also unable to connect to my own Atlas cluster with basically the same messages. I’m following the connection instructions provided by Atlas and using the following command (Keep in mind that my cluster name is Cluster0 and not Sandbox):

" mongo “mongodb+srv://” --username m001-student "

After this I’m prompted for the password which I input and I get the following message regarding the shell being unable to locate the primary or any nodes in the cluster:

connecting to: mongodb://,,
2019-01-15T13:54:49.119-0800 I NETWORK [js] Starting new replica set monitor for Cluster0-shard-0/,,
2019-01-15T13:54:59.849-0800 W NETWORK [ReplicaSetMonitor-TaskExecutor] Unable to reach primary for set Cluster0-shard-0
2019-01-15T13:54:59.849-0800 I NETWORK [ReplicaSetMonitor-TaskExecutor] Cannot reach any nodes for set Cluster0-shard-0. Please check network connectivity and the status of the set. This has happened for 1 checks in a row.

After attempting to contact the other nodes (which it fails) I get the final message:

exception: connect failed

Any ideas?

Hi Hernan_67132,

I am able to connect to your cluster as well. Please check your network connectivity and let me know.
Here is the command I used:

mongo "mongodb+srv://" --username m001-student --password m001-mongodb-basics