Skip to content
Latchkey

GitHub Actions Runner Out of Memory (Exit 137 / Killed)

A step was killed because it exceeded the runner memory. Exit code 137 is 128 + 9 (SIGKILL), and on a memory-bounded runner that is almost always the kernel OOM killer.

What this error means

A build or test step ends with the word Killed and exit code 137, usually with no stack trace because SIGKILL cannot be caught. Standard GitHub-hosted Linux runners cap out around 7 GB of RAM.

Actions log
<--- Last few GCs --->
FATAL ERROR: Reached heap limit Allocation failed
Killed
Error: Process completed with exit code 137.

Common causes

Work exceeds the runner RAM

Bundlers, compilers, and large test runs can spike past the standard hosted runner memory ceiling, triggering an OOM kill.

Too much parallelism

Running many workers or processes at once multiplies peak memory and pushes the job over the limit.

How to fix it

Use a larger runner

Move the memory-heavy job to a larger GitHub-hosted runner or a self-hosted host with more RAM.

.github/workflows/ci.yml
jobs:
  build:
    runs-on: ubuntu-latest-4-cores   # larger runner label
    steps:
      - run: npm run build

Reduce peak memory

  1. Cap heap usage, for example NODE_OPTIONS=--max-old-space-size=4096 for Node.
  2. Lower parallelism (Jest --maxWorkers=2, make -j2).
  3. Split a monolithic build or test step into smaller steps.

How to prevent it

  • Right-size runners for memory-heavy builds.
  • Set language heap limits below the runner memory ceiling.
  • Watch peak memory in CI so you catch growth before it OOMs.

Frequently asked questions

What causes "Runner OOM (137)"?
Bundlers, compilers, and large test runs can spike past the standard hosted runner memory ceiling, triggering an OOM kill.
How do I fix Runner OOM (137)?
Move the memory-heavy job to a larger GitHub-hosted runner or a self-hosted host with more RAM.
Can Latchkey fix this automatically?
Yes. Latchkey runs your GitHub Actions on managed runners that detect this failure, apply the fix, and retry the job automatically - self-healing is on by default.

Related guides

References

Latchkey auto-heals failures like this one - detected, fixed, and retried without you. Start free → 30-day trial · No credit card