mongodb+srv via SSH, ports not accepted

Sándor Vasas shared this problem 6 years ago
Solved

I'm trying to login to a cloudatlas replset of ours with SSH tunelling and receiving this:


Ports not accepted with mongodb+srv URIs.


I'm not setting any port besides the SSH 22 port. Can connect without SSH tunneling.

Replies (3)

photo
1

Thank you for your bug report. We will fix the issue in the next release.

photo
1

Resolved in V4.7.2

photo
1

Hi,

I tried to connect to mongodb (azure cluster) through node.js backend (deployed the node.js application on heroku), however getting following error.

Mongodb Uri : mongodb+srv://myuser:mypassword@cluster0-shard-00-00.ttlf6.azure.mongodb.net:27017/mydb?ssl=true&replicaSet=cluster0-shard-0&authSource=admin

Also tried with different combinations:

mongodb+srv://myuser:mypassword@cluster0-shard-00-00.ttlf6.azure.mongodb.net:27017/mydb

mongodb+srv://myuser:mypassword@cluster0-shard-00-00.ttlf6.azure.mongodb.net:27017/mydb?authSource=admin


However, If using below mongodb uri

mongodb://vidlyuser:1234@ds012538.mlab.com:12538/vidly

able to connect successfully.


Please help.


/2ca9f13c9492d0deefacba0430cbb73d


Thanks & Regards,

Amit

Leave a Comment
 
Attach a file