Failed conecting to db

Cannot connect to the MongoDB at localhost:27017.


Network is unreachable. Reason: couldn’t connect to server localhost:27017, connection attempt failed: SocketException: Error connecting to localhost:27017 ( :: caused by :: Nenhuma liga��o p�de ser feita porque o computador de destino

as recusou ativamente.

I get this error when I try to connect through robot3T

In M001 your are supposed to connect to an Atlas cluster.

You have to specify the URI of your cluster.

Your error means that there is no server running on localhost at the given port. If it is really what you want to do, you have to start a server using the mongo command. But that’s outside the scope of M001.

Hi @Marco_Alexandre, as Steeve rightly said, you need to provide an Atlas cluster connection string along with the mongo command in the following manner:
mongo <----atlas cluster connection string---->
You can learn more about getting started with Atlas here.
Also, you can learn more about connecting your mongo shell to your Atlas cluster here.

I hope it helps, in case you have any doubts, please feel free to reach out to us.

Thanks. Regards.
Sourabh Bagrecha,
Curriculum Services Engineer.

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