Workflow timeout after 2h when set to 4h

Describe the problem/error/question

I have an n8n workflow that is taking a long time to run, as it has to Loop and call a sub-workflow 80 times, and I have many “waits” so that Google Sheets doesn’t complain.

I have the workflow set with a timeout of 4 hours.

I got a VPS in which i got portainer and n8n installed via portainer. The config file has several variables that define timeouts, which are these (in all services: worker, editor, and webhook):

  • Maximum default execution time (In seconds)

    • EXECUTIONS_TIMEOUT=3600 (1 hour)
  • Maximum execution time to set in an individual workflow (In seconds)

    • EXECUTIONS_TIMEOUT_MAX=86400 (24 hours)

So, by default, workflows would timeout after 1 hour of execution, provided you haven’t defined another timeout in the workflow itself. And the maximum a workflow can run is 24 hours.

The problem: My workflow, which is set to timeout after 4 hours, gives a timeout when it reaches 2 hours of execution.

Just a bit more information: the subworkflow, when executed, will always return only one item.

I have tried several things:

  • Modifying and saving the timeout again.

  • Creating a new workflow and moving the content to it, setting the timeout, and running it.

  • Restarting the n8n service.

None of this has worked, the workflow stops at 2 hours.

Has this happened to anyone else? Any idea how I can solve this?

Thank you very much for your help, best regards,

Javi

What is the error message (if any)?

Just the timeout

Please share your workflow

Share the output returned by the last node

Information on your n8n setup

  • n8n version: 1.119.1
  • Database (default: SQLite): postgress
  • n8n EXECUTIONS_PROCESS setting (default: own, main): default
  • Running n8n via (Docker, npm, n8n cloud, desktop app): docker
  • Operating system: ubuntu server