a month ago
Hello Railway Support,
I need urgent assistance recovering the original production database for my NEXO application.
Project: incredible-unity
Environment: production
Backend service: nexo-platform
Database service: Postgres
Detached volume: postgres-volume-MNER
NEXO previously had real production data, including users, drivers, passengers, and ride records.
The backend is still running, but PostgreSQL repeatedly reports:
ERROR: relation "ride_offers" does not exist
I connected to the production PostgreSQL service through Railway's secure CLI connection and ran a read-only query against pg_tables. It returned zero application tables in the schemas checked.
The project contains an active volume named postgres-volume and a separate detached volume named postgres-volume-MNER. The detached volume shows approximately 85 MB of usage, but Railway's dashboard reports that it has no backups.
I need help determining whether the detached volume contains my original production database and whether its data can be recovered.
Please:
Investigate the history and current status of both volumes.
Determine whether postgres-volume-MNER contains recoverable PostgreSQL data.
Advise how to inspect or restore that data safely without overwriting the active volume.
Preserve both volumes while investigating.
I have not wiped, deleted, or swapped the volumes.
This is a production data recovery issue. Please advise on the safest recovery procedure before any destructive action is taken.
Thank you.
3 Replies
a month ago
Your data is not lost. The detached postgres-volume-MNER volume in the production environment of incredible-unity is still on our storage, holding about 85 MB at the Postgres data path /var/lib/postgresql/data. That is the same mount path as the volume your Postgres service uses now. We can't read the database contents from our side, so we can't confirm which tables it holds.
You can recover it by attaching it back to your Postgres service with the CLI. Detaching a volume does not delete it. Running railway volume detach --volume postgres-volume first leaves the current volume in the project as an unattached volume, so both copies are kept. Then run railway volume attach --volume postgres-volume-MNER --service Postgres and redeploy Postgres. After that, query pg_tables again to check whether your application tables are back. If they aren't, you can swap the volumes back the same way. The volume CLI reference covers both commands.
Don't delete either volume until you've confirmed which one holds your production data.
Status changed to Awaiting User Response Railway • about 1 month ago
Railway
Your data is not lost. The detached `postgres-volume-MNER` volume in the production environment of incredible-unity is still on our storage, holding about 85 MB at the Postgres data path `/var/lib/postgresql/data`. That is the same mount path as the volume your Postgres service uses now. We can't read the database contents from our side, so we can't confirm which tables it holds. You can recover it by attaching it back to your Postgres service with the CLI. Detaching a volume does not delete it. Running `railway volume detach --volume postgres-volume` first leaves the current volume in the project as an unattached volume, so both copies are kept. Then run `railway volume attach --volume postgres-volume-MNER --service Postgres` and redeploy Postgres. After that, query `pg_tables` again to check whether your application tables are back. If they aren't, you can swap the volumes back the same way. The [volume CLI reference](https://docs.railway.com/cli/volume) covers both commands. Don't delete either volume until you've confirmed which one holds your production data.
a month ago
Thank you for confirming that the detached volume still exists.
I verified through the Railway CLI that postgres-volume-MNER is detached and cannot be browsed or accessed using the volume file commands while detached.
Both volumes remain present:
postgres-volume-MNER — 84.57 MB, detached.
postgres-volume — 85.24 MB, attached to Postgres.
Since both may contain important PostgreSQL data, could you confirm the safest procedure to inspect the detached volume without risking the active volume? Is it possible to create a snapshot or duplicate of the detached volume before attaching it, or to attach it temporarily to an isolated recovery service?
I want to preserve both volumes and recover the original NEXO production records without overwriting either copy.
Status changed to Awaiting Railway Response Railway • about 1 month ago
a month ago
We don't offer a supported way to attach postgres-volume-MNER to a separate, isolated recovery service, and support can't inspect, copy, or export its data on your behalf. The CLI file commands only work through a volume's attached service with an active deployment, which is why the detached volume can't be browsed.
Both volumes are currently intact in the production environment: postgres-volume (about 85 MB) is attached to Postgres, and postgres-volume-MNER (about 85 MB) is unattached and still holds its data. Detaching a volume does not delete it, so the swap described in our earlier reply leaves postgres-volume in the project as an unattached volume rather than overwriting it. The only way to read postgres-volume-MNER is to attach it to your Postgres service in place of the current volume, which means Postgres serves from that volume until you swap back.
Neither volume is removed unless you delete it, so keep both until you've confirmed which one holds the NEXO records.
Status changed to Awaiting User Response Railway • about 1 month ago
a month ago
This thread has been marked as solved automatically due to a lack of recent activity. Please re-open this thread or create a new one if you require further assistance. Thank you!
Status changed to Solved Railway • about 1 month ago