Exception Connect failed mongo shell


I can’t connect to mongo using the mongo shell.
Unable to reach primary for set Cluster0-shard-0
Here is the error message
error_connect_mongo_shell1 error_connect_mongo_shell2

Thank you for the help

Hi Hasna,

I am able to connect just fine. Please take a look at the screenshot:

I am using the following command:

mongo “mongodb://cluster0-shard-00-00-jxeqq.mongodb.net:27017,cluster0-shard-00-01-jxeqq.mongodb.net:27017,cluster0-shard-00-02-jxeqq.mongodb.net:27017/test?replicaSet=Cluster0-shard-0” --authenticationDatabase admin --ssl --username m001-student --password m001-mongodb-basics

Are you able to ping the cluster ? Try
ping cluster0-shard-00-00-jxeqq.mongodb.net:27017

If you are unable to ping, your network might be blocking the request. You need to contact your IT department to allow. OR you can try from your home network/system.

Thanks, Kanika

Ok thank you so much