Postgres is not working
iapolinario
HOBBYOP

15 days ago

Our production system is currently down. This is a critical business application used during working hours, and this level of downtime is unacceptable for our operation.

Project/environment: TJRadar / production

Affected services: Backend and Postgres

Backend public URL: https://tjradar-backend.up.railway.app

The backend is failing to respond and returns:

502 Application failed to respond

In the backend logs, we are repeatedly seeing Postgres connection timeouts through Railway private networking

Solved$10 Bounty

2 Replies

Railway
BOT

15 days ago

This thread has been opened as a bounty so the community can help solve it.

Status changed to Open Railway 15 days ago


Anonymous
FREE

15 days ago

This smells like the app is booting, trying to connect to Postgres over the private network, timing out, and then Railway reports it as a 502.

I’d check the exact DATABASE_URL the backend is using first. Make sure it points to the Postgres service in the same Railway environment and not an old/public TCP proxy URL.

Quick test from the backend shell:

pg_isready "$DATABASE_URL"

If that fails, check whether the internal host resolves at all:

getent hosts .railway.internal

If it eventually connects but your app exits first, add DB retry/backoff during startup. Then redeploy Postgres, wait until it’s healthy, and redeploy the backend.


iapolinario
HOBBYOP

15 days ago

Issue was solved, but the problem was a hardware Railway had will failure for a couple of hours.


Status changed to Solved iapolinario 15 days ago


Welcome!

Sign in to your Railway account to join the conversation.

Loading...