Database snapshot restore needed - n8n admin user corrupted after Postgres patch
Anonymous
PROOP

2 months ago

I need a database snapshot restore or direct user password reset.

Issue: My n8n admin account (aparrales05@hotmail.com) is corrupted and locked out after the Postgres-elng security patch on August 3rd.

What happened:

  • Postgres security patch broke my app's connection pool
  • Primary service (n8n) lost database connectivity for 8+ days
  • This corrupted my admin user record in the database
  • I can now access the n8n UI but get "you need contact your admin" and 401 on login attempts
  • Environment variable reset (N8N_INIT_USER_PASSWORD) does not work for existing users
  • No SMTP configured, so password reset email is unavailable

What I need:

  1. Restore Postgres-elng volume from the snapshot taken August 3rd at ~14:51 UTC (before the patch), OR
  2. Direct password reset in the user table for aparrales05@hotmail.com

Proof the service is running:

  • n8n is responding on primary-production-e990.up.railway.app
  • Two workflows are active in the database
  • /rest/login returns 401 (not 503)
  • Postgres-elng is healthy and connected

Project: trustworthy-simplicity (7b42560b-6575-4079-9ac9-e5c07f8a7d67)

Environment: production

Solved$20 Bounty

Pinned Solution

rjbathgate
PRO

2 months ago

FYI, I’m pretty sure nobody here is going to be able to make an application-level database change for you like:

“Direct password reset in the user table for aparrales05@hotmail.com”

That’s your n8n application data, rather than something Railway would normally go in and modify for you. And to be honest, you probably wouldn’t want your infrastructure provider casually editing data inside your application database anyway!


Also... if you don't want to restore the db...

n8n has a CLI command specifically for resetting the user-management state when you're locked out. Have a look at:

https://docs.n8n.io/deploy/host-n8n/configure-n8n/use-the-command-line#user-management

6 Replies

Railway
BOT

2 months ago

A pre-patch volume snapshot was taken automatically before the August 3rd security patch and is available in the Postgres-elng service's Backups tab, retained for 30 days. Since you're on Pro, you can restore it yourself directly from that tab to roll the volume back to its state immediately before the patch.


Status changed to Awaiting User Response Railway • about 2 months ago


Railway

A pre-patch volume snapshot was taken automatically before the August 3rd security patch and is available in the Postgres-elng service's Backups tab, retained for 30 days. Since you're on Pro, you can restore it yourself directly from that tab to roll the volume back to its state immediately before the patch.

Anonymous
PROOP

2 months ago

I need help. I can't access my n8n, It says I need to contact my admin


Status changed to Awaiting Railway Response Railway • about 2 months ago


Railway
BOT

2 months ago

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

Status changed to Open Railway • about 2 months ago


I need help. I can't access my n8n, It says I need to contact my admin

rjbathgate
PRO

2 months ago

If I understand this correctly, the Bots suggestion about the pre-patch volume snapshot is at Railway dashbaord level, not something you restore to inside your n8n login.

So, you don't need to login / access n8n instead you need to rollback within your Railway canvas.

This is likely the docs you need:

https://docs.railway.com/guides/postgres-backups-restores

and

https://docs.railway.com/volumes/backups

But these might be helpful:

https://docs.railway.com/deployments/deployment-actions

https://docs.railway.com/guides/roll-back-bad-deploy

or, I have totally got the wrong end of the stick...


rjbathgate
PRO

2 months ago

FYI, I’m pretty sure nobody here is going to be able to make an application-level database change for you like:

“Direct password reset in the user table for aparrales05@hotmail.com”

That’s your n8n application data, rather than something Railway would normally go in and modify for you. And to be honest, you probably wouldn’t want your infrastructure provider casually editing data inside your application database anyway!


Also... if you don't want to restore the db...

n8n has a CLI command specifically for resetting the user-management state when you're locked out. Have a look at:

https://docs.n8n.io/deploy/host-n8n/configure-n8n/use-the-command-line#user-management


Anonymous
PROOP

2 months ago

Thanks so much for your help. I restored my n8n.


Thanks so much for your help. I restored my n8n.

rjbathgate
PRO

2 months ago

you're welcome. Can you mark my post as the solution (if you haven't already) (then I get the bounty!)


Status changed to Solved brody • about 2 months ago


Welcome!

Sign in to your Railway account to join the conversation.

Loading...