Reducing data size of Postgres volume (N8N w/Workers)

jaime741HOBBY

4 months ago

Hi everyone.

I have an issue with my N8N w/workers deployment. Essentialy, Postgres volume data size grows after running a simple email classification workflow and I cannot get it to decrease. It already happened once that the postgres volume got full, crashed the whole deployment, and had to redo everything.

I do not want to upgrade my railway plan under any circumpstance, and I am not a technical profile, I am just learning the basics.

I have set the data pruning variable in my primary container, and disabled the executions data storage, but data size at postgres volume remains at around 3Gbs, being the maximum 5 Gbs.

Can anybody tell me what options do I have (or how often does Postgres execute vacuuming) before the data size gets back to its baseline value of 300 ~ish Mbs?

Thanks a lot.

N8N version: 1.73.1

Template: N8N w/Workers

Solved

4 Replies

4 months ago

Hello,

Please see the Postgres docs for vacuuming -

https://www.postgresql.org/docs/current/routine-vacuuming.html

Have you tried running VACUUM on the largest tables?


Status changed to Awaiting User Response railway[bot] 4 months ago


jaime741HOBBY

4 months ago

Thanks for the reply,

As I said, I am not a technical profile. I have read the docs but I don't quite understand the application of the command. For some reason I don't have access to the tables as Railway keeps telling me that I need to set certain variables. When I set them I keep getting the message so I cannot "access" the contents of the volume.

If I just need to set VACUUM as a variable in the variables section of the container, then what would the appropriate value for such variable be?

Again, apologies about my ignorance, but this is all a big 1st time for me.

Thx


Status changed to Awaiting Railway Response railway[bot] 4 months ago


4 months ago

Hello,

VACUUM is not a variable, it is a command you run on your database tables.

Please do not modify the variables, if you cause any damage to your database we would not be able to help you restore anything.

Instead, use a database GUI tool like dbgate.

You can deploy dbgate into your project via the + Create button.

Best,
Brody


Status changed to Awaiting User Response railway[bot] 4 months ago


jaime741HOBBY

4 months ago

Ok, will try that way.

Thanks a lot


Status changed to Awaiting Railway Response railway[bot] 4 months ago


Status changed to Solved brody 4 months ago


Reducing data size of Postgres volume (N8N w/Workers) - Railway Help Station