N8n Freezes and Crashes Every Few Minutes - Need Help Diagnosing

Describe the problem/error/question

n8n becomes completely unresponsive every few minutes or few hours. The instance freezes and cannot respond to any requests until the container is restarted.

What is the error message (if any)?

No error messages. n8n becomes unresponsive silently.

Workflow Details

  • Number of active workflows: 40+

  • Custom nodes in use: Yes

Information on your n8n setup

  • n8n version: 2.1.4
  • Database: PostgreSQL RDS (AWS)
  • n8n EXECUTIONS_PROCESS setting (default: own, main): main
  • Running n8n via (Docker, npm, n8n cloud, desktop app): Docker (AWS ECS Fargate)
  • Operating system: Linux (Container on AWS ECS)

Check the execution and your AWS dashboard.

If the server only using for n8n.
There should be one or more workflow using too much resource. (Most possible RAM or CPU)

Once you fix that workflow or disable it. The instance should be fine.

Sir try this,

  1. Adjust Execution Mode
    • Set so each workflow runs in its own process.
    • This isolates failures and prevents the main process from freezing.
  2. Increase ECS Task Resources
    • Allocate at least 2 vCPUs and 4–8 GB RAM for n8n containers.
    • Monitor ECS CloudWatch metrics for memory usage spikes.
  3. Optimize Database Connections
    • Ensure PostgreSQL RDS has sufficient connections and performance tuning:
    • Increase if workflows spawn many queries.
    • Enable connection pooling (e.g., PgBouncer).