DNSHostNotFound: Failed to look up service "_mongodb._tcp.cluster0-shard-00-01.mp4zt.mongodb.net"

I have been trying to reach me cluster from the shell but it’s failing.

Also, my ports are not blocked, as I have checked it on http://portquiz.net:27017/

curl portquiz.net:27017
Port test successful!

So I honestly don’t know what seems to be the problem here, and its very annoying as there are no warnings/notes given about this very common problem and how to bypass it. Please help.
Thanks

Just in case, this is how my cluster page looks like

Your connect string is not ok
From where you got this?
Please take it from your Atlas
You should be using cluster0.mp4zt.mongodb.net but you have given a node name

1 Like

Hello, what do you mean by “take it from the atlas”?. This is how my atlas dashboard looks like.

Follow the lab instructions:

For this exercise you will connect to your cluster from the shell.

  • Select “Connect” in the Atlas Cluster, and choose to “Connect with the mongo shell” .
1 Like