Mongodb Atlas mongodb+srv connection fails timeout

Daniel Givoni shared this idea 5 years ago
Completed

hi,

i am migrating my existion db from mLab to mongoDB Atlas

from mLab my connection is fine - type: mongodb://

when i try connection to my new Atlas db with type: mongodb+srv:// it fails by time out

connection by Node.js is fine

connection by mongodb shell is fine

mongoBooster log:

17:25:48.459 *** Starting MongoClient.connect ***

{"options":{"appname":"NoSQLBoosterV5.2.3-beta.1_213154.520","autoReconnect":true,"keepAlive":60000,"poolSize":0,"promoteLongs":false,"promoteValues":false,"reconnectTries":172800,"socketTimeoutMS":0,"ssl":true,"sslValidate":false,"useNewUrlParser":true},"uri":"mongodb+srv://*******:******@farmer-develop-wibuu.mongodb.net/farmer_develop?authSource=farmer_develop&retryWrites=true&ssl=true&w=majority"}

17:26:40.581 *** Connect Error ***


{"code":"ETIMEOUT","errno":"ETIMEOUT","hostname":"_mongodb._tcp.farmer-develop-wibuu.mongodb.net","message":"querySrv ETIMEOUT _mongodb._tcp.farmer-develop-wibuu.mongodb.net","stack":"Error: querySrv ETIMEOUT _mongodb._tcp.farmer-develop-wibuu.mongodb.net\n at QueryReqWrap.onresolve [as oncomplete] (dns.js:197:19)","syscall":"querySrv"}

Replies (5)

photo
1

this is my connection URI:

mongodb+srv://<username>:<password>@farmer-develop-wibuu.mongodb.net/farmer_develop?retryWrites=true&w=majority

This comment is in trash! Restore
photo
1

Can you confirm the permissions of your account and try to execute “show dbs” in mongo shell to see if the results are returned correctly?

This comment is in trash! Restore
photo
photo
1

I can confirm the same problem with Atlas.


@Daniel Givoni you can actually use the From URL button to import the mongodb+srv url


/e43945b000ec42512ce0fa4e1baecbe6


It should work with your database but the $external database will cause error popups on the bottom right forever.


I can never make the legacy URI work, it only shows $external and admin databases as your screenshot shows, which is not the database I told it to use. And I can use the nodejs MongoDB module to connect the database with the same URI.

This comment is in trash! Restore
photo
1

Thank you for your feedback. Version 5.2.3 is a little out of date. Please download the latest version(5.1.12) and try again. I tried my own atlas server and it works well. If the latest version cannot be successfully connected, can you give me a temporary read-only test account? in order to solve this problem, I first need to reproduce the problem locally.

/d6ba7ea000f8ffde22b3f07f3b5e67fe

This comment is in trash! Restore
photo
1

i successfully connected after restarting mongoBooster -thanx

i updated to 5.2.12 and all is good.

you can close issue

This comment is in trash! Restore
Leave a Comment
 
Attach a file