We are unable to connect to the database via SSH.
barapla
HOBBYOP

5 months ago

Hey there I have problems with my db, but now says the db doesn't exists

"psql: error: connection to server at "localhost" (::1), port 5432 failed: FATAL: database "railway" does not exist"

$10 Bounty

3 Replies

ilyassbreth
FREE

5 months ago

i need more info to help properly:

  1. what exact command are you running that gives this error?
  2. can you share a screenshot of your postgres service variables tab? (hidepassword values)
  3. are you running commands from your local machine or from inside a container?

the official way to connect is railway connect <service-name> from your local terminal (needs psql installed), but without knowing your setup i can't say why it's failing


Have you tried connecting to the database via public URL from a db client such as Datagrip?


Also, if you’re trying to connect to the db via psql , you’ll need to specify host, port, user, password, and database. Otherwise, it’ll assume you’re trying to access the database railway locally.


Welcome!

Sign in to your Railway account to join the conversation.

Loading...