a month ago
I am trying to connect to my MongoDB service externally but every time I run
npx prisma db pushi get this error:
Error: MongoDB error
Kind: Server selection timeout: No available servers. Topology: { Type: Unknown, Servers: [ { Address: yamanote.proxy.rlwy.net:41075, Type: Unknown, Error: Kind: I/O error: Connection reset by peer (os error 54), labels: {}, source: None } ] }, labels: {}, source: Noneis there a guide/tutorial on getting MongoDB setup on railway? i want to move my instance over from digital ocean, but this is too confusing. if i cant figure it out, i'll just leave it on DO.
14 Replies
a month ago
Can you screenshot the public networking part of your mongoDB service?
joselvelez
Below
a month ago
Please create a TCP proxy that points to port 27017, and use the information that it gives you for that.
a month ago
i have this now
When I use the copy button, i get this: caboose.proxy.rlwy.net:11514
When I try this on my local machine, it fails still:
MONGODB_URL=mongodb://mongo:<password_removed>@caboose.proxy.rlwy.net:11514/gridlv1?tls=true&authSource=adminAttachments
joselvelez
i have this nowWhen I use the copy button, i get this: caboose.proxy.rlwy.net:11514When I try this on my local machine, it fails still:MONGODB_URL=mongodb://mongo:<password_removed>@caboose.proxy.rlwy.net:11514/gridlv1?tls=true&authSource=admin
a month ago
Can you please remove ?tls=true&authSource=admin from the end.
a month ago
I did that and got this error:
Error: MongoDB error
Kind: SCRAM failure: Authentication failed., labels: {}, source: Some(Error { kind: Command(CommandError { code: 18, code_name: "AuthenticationFailed", message: "Authentication failed.", topology_version: None }), labels: {}, wire_version: None, source: None })
joselvelez
I did that and got this error:Error: MongoDB errorKind: SCRAM failure: Authentication failed., labels: {}, source: Some(Error { kind: Command(CommandError { code: 18, code_name: "AuthenticationFailed", message: "Authentication failed.", topology_version: None }), labels: {}, wire_version: None, source: None })
a month ago
Did you change the password variable in the variables tab?
a month ago
no, im using the default
joselvelez
no, im using the default
a month ago
Are you sure you properly copy pasted the MONGOPASSWORD variable?
a month ago
yes, i just copy + pasted it again to be sure. still not working.
joselvelez
yes, i just copy + pasted it again to be sure. still not working.
a month ago
Do you have data in this database?
a month ago
no, it is a fresh db.
joselvelez
no, it is a fresh db.
a month ago
Can you please try wiping the volume, redeploying, and then connecting again?
a month ago
i gave up. i'll stay on digital ocean. this was too confusing and taking too long to get working. you can close this. thx.
Status changed to Solved samgordon • 27 days ago
