URGENT!! Postgres crash-looping — volume resize not propagating after deployment outage
cooldev765
PROOP

2 months ago

My Postgres is crash-looping with "No space left on device" on pg_wal.

Disk filled up during an index build. I resized the volume from 10GB to 20GB but the filesystem never picked it up — Postgres kept crashing. I then restored from backup which created a new volume, but Postgres still mounts the old full volume on every restart.

Tried: live resize, redeploy, restore from backup — none worked. Postgres always boots from the old full volume. Also attempted: multiple restores from the 9.77GB backup — each restore appears to complete but Postgres still boots from the old volume.

Note: the Railway deployment outage (incident QVJT4QJO) occurred at the same time. Could this have caused the volume resize to not propagate correctly?

How do I force Postgres to use the new restored volume?

Error in logs every restart:

FATAL: could not write to file "pg_wal/xlogtemp.30": No space left on device

Volume being mounted: vol_yd54ofxtc5w2gy6d (old, full)

New restored volume: postgres-2026-04-06 15:46 UTC (has space, not being used)

Solved

2 Replies

Status changed to Awaiting Railway Response Railway about 2 months ago


cooldev765
PROOP

2 months ago

Need HELP: Logs confirm WAL recovery completes successfully every restart (redo done at 16/F6FD4BA8) but Postgres immediately crashes with No space left on device when writing pg_wal/xlogtemp.30.

The volume was live-resized from 10GB to 20GB but the ext4 filesystem was never expanded inside the container — the block device is 20GB but the filesystem is still 10GB.

Running resize2fs on the block device inside the Postgres container will fix this immediately. Data is intact and uncorrupted — WAL replay completes successfully every time.


2 months ago

We identified that your volume resize didn't fully apply, which is what was causing the "No space left on device" errors. We've corrected this on our end and redeployed your Postgres service. You should now have the full 20 GB of disk space available.


Status changed to Awaiting User Response Railway about 2 months ago


Status changed to Solved cooldev765 about 2 months ago


Welcome!

Sign in to your Railway account to join the conversation.

Loading...