n8n Service crashed after PostgreSQL automatic update - Collation version mismatch
tobleronex
PROOP

2 months ago

Issue: My n8n Primary service keeps crashing after Railway automatically updated PostgreSQL.

Timeline:

- Railway showed PostgreSQL update notification and I applied it

- n8n workflows stopped executing (were getting canceled with ExecutionCancelledError)

- PostgreSQL logs show repeated "collation version mismatch" warnings:

"database "railway" has a collation version mismatch - created using version 2.36, but OS provides version 2.41"

- Primary service now crashes on startup even after rollback to 6h ago deployment

Current status:

- Primary service: Crashed/failing to start

- PostgreSQL: Running but with collation mismatch warnings

- Worker service: Running but can't process jobs due to database issues

Error messages:

- "Application failed to respond"

- PostgreSQL: "ALTER DATABASE railway REFRESH COLLATION VERSION" suggested

- Worker logs show "database system is not yet accepting connections"

Template: Using Railway's n8n template (not custom Docker images)

Request: Please help fix PostgreSQL collation mismatch or advise on migration path.

Solved$10 Bounty

2 Replies

Railway
BOT

2 months ago

Hey there! We've found the following might help you get unblocked faster:

If you find the answer from one of these, please let us know by solving the thread!


uxuz
MODERATOR

2 months ago

Hey, according to the Postgres docs, you would want to reindex and update the collation version of your Postgres database. This can be done by running REINDEX DATABASE railway; and ALTER DATABASE railway REFRESH COLLATION VERSION;. Make sure to backup your database before executing these queries, in case they fail and somehow corrupt the database. Having a backup also allows you to just deploy a new Postgres database and restore the backup to it.


Status changed to Solved uxuz 2 months ago


Loading...