a year ago
When trying to connect to MongoDB externally using MongoDB Compass I receive ECONNRESET error. This used to work just fine.
In Mongo Data UI section the Database connection doesn't work either. Just a spinning icon.
Redeployment does not fix it.
Thanks for any pointers!
9 Replies
Status changed to Awaiting User Response Railway • 12 months ago
angelo-railway
Did the DB become inaccessible when your database moved?
a year ago
I do not recall moving the database. I only occasionally access the db to backup data so I cannot pinpoint the point of failure in time.
The strange thing is the application which depends on the db can access it just fine through the same external/public access link.
Both staging and production environments same situation
Status changed to Awaiting Railway Response Railway • 12 months ago
a year ago
through the same external/public access link.
Are you sure, is it not communicating via the private network?
Status changed to Awaiting User Response Railway • 12 months ago
angelo-railway
> through the same external/public access link. Are you sure, is it not communicating via the private network?
a year ago
I just checked the code/variables and indeed the application goes via the private network. My apologies for the confusion.
Still I have no idea what has changed that even the Railway dashboard cannot access the data.
Thanks!
Status changed to Awaiting Railway Response Railway • 12 months ago
a year ago
Hello,
You have your database's TCP proxy pointing to the incorrect target port.
Best,
Brody
Status changed to Awaiting User Response Railway • 12 months ago
a year ago
Hi,
Thanks for the reply. I did not change anything to port settings. I would like some guidance as to how to resolve this, please. The Railway database dashboard still does not show a working database connection.
The 'Database Connection' bullet as shown below only shows a spinner. Here I used to be able to view the data.
Regards
Mongo Data UI
A custom interface into your database
- Deployment Online This service has an active deployment
- Required Variables This service has all the necessary variables that this UI uses to connect to the database.
- Database Connection ---- Show spinner; no other text or data ----
Status changed to Awaiting Railway Response Railway • 12 months ago
a year ago
You are still using the wrong port.
https://docs.railway.com/guides/build-a-database-service#connecting
Status changed to Awaiting User Response Railway • 12 months ago
Status changed to Solved parmstar • 12 months ago
parmstar
You are still using the wrong port. <https://docs.railway.com/guides/build-a-database-service#connecting>
a year ago
Hi, read the docs and whatever I try to set up it does not resolve the problem. I find the setup proces unclear and do not understand why it worked just fine and now doesn't anymore.
In my staging environment I removed all external database access for testing purposes.
Stil unable to access (as test) the data from the - Railway dashboard -. Still a spinner; waiting for database connection.
This also used to work just fine. How can that be resolved to start with, please?
I would appreciate an answer a bit more elaborate than 'You are doing something wrong' +
Regards
Status changed to Awaiting Railway Response Railway • 12 months ago
a year ago
Figured it out by myself by creating a test database.
Status changed to Solved jerry360-bit • 12 months ago