Can't connect to MongoDB atlas serverless instance
Hi, i have a MongoDB serverless instance but i can't connect to that.
I am using the connection string that mongo atlas gives me
but i get the following error:
"A TXT record is only permitted to contain the keys [authsource, replicaset], but the TXT record for 'quiz-serverless-instanc.iw9hz.mongodb.net' contains the keys [loadbalanced, authsource]."
I don't know what could be happening, it's a serverless instance
Please sign in to leave a comment.
Just found similar issue here https://www.mongodb.com/community/forums/t/atlas-serverless-and-dns-txt-record/117967
Looks like your server returns TXT record which contains 'loadbalanced' value, so I guess you need to contact support on server side to change DNS records.
Hello Guys,
Last Monday I have Facing same problem Please any one can Help me. Thanks in Advance.
’m trying to connect to an Atlas Serverless database from Nodejs. It just won’t work. Tried and triple checked everything I found. mongosh connect works, so user/passwd must be right, and ip whitelisting must work too.
OneCognizant.Cognizant.com Portal
I followed MongoDB Atlas Serverless Instances: Quick Start to the letter, yet the insertOne fails with “MongoDriverError: MongoClient must be connected to perform this operation”.
Help please!
Hello!, Nicomorales297
I have same type problem
So I'm currently wirting a web application and I need database so I decided to go with mongodb and mongoose. Until now I tested everything on localhost and it worked but I wanted to move the data to a server. I had heard of Atlas and registered myself and "uploaded" the data.
Now I want to connect to the cluster via a node.js app.
I got the string of the mongodb Atlas site at the point Connect Your Application
Then I swapped my password.
This didn't work either.
Thats the error message:
message: 'failed to connect to server [insight-shard-00-02-quhku.mongodb.net:27017] on first connect [MongoNetworkError: connect ECONNREFUSED 18.194.163.64:27017]' } (node:4920) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): MongoNetworkError: failed to connect to server [insight-shard-00-02-quhku.mongodb.net:27017] on first connect [MongoNetworkError: connect ECONNREFUSED 18.194.163.64:27017] (node:4920) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. KohlsFeedback Survey
any one can help me
Thanks
I have had the same issue since I updated to the latest IntelliJ version 2022.2.
I have installed the previous version 2022.1.4 and there it works. That should indicate the problem does not come from the DNS.
I have had success also connecting from mongosh and a python script from the same machine.
update mongodb lib to 4.1.0 +
Thanks for the updates.
We have an issue reported similar to yours:
https://youtrack.jetbrains.com/issue/DBE-14987/Connect-to-MongoDB-Atlas-Serverless
Please try to update the Mongo DB driver to version 4.1.0 or higher:
https://www.mongodb.com/community/forums/t/mongodb-java-driver-4-1-0-released/7363
Retry to connect, and let us know your results.
If the issue will remain, please find the idea log in Help - Show Log in FIles and upload it to:
https://uploads.jetbrains.com/
I have had this same problem when trying to connect to Mongo Atlas with the currently latest version of DataGrip (2023.1.2)
When downgrading to 2022.1.5 I can connect without changing any settings. The problem thus seems to lie with DataGrip or possibly the JVM version it uses.