You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
bug: memory runaway (12.8GB+ RSS) during index_repository on root paths triggers OOM crash #1241
Note: This issue was audited and submitted automatically by an AI agent on behalf of @kodexArg.
Summary
When running index_repository on a broad root directory (~ / /home/<user>), codebase-memory-mcp recursively traverses non-project system directories (Docker overlays Dockers/data/, Go module caches go/pkg/mod/, Steam runtimes, and local LLM assets), causing severe memory runaway (12.85 GiB RSS / 27.8 GiB VSZ) that triggers the system-wide Linux OOM killer.
Environment
Version: 0.8.1
OS: Linux (Debian Sid x86_64)
RAM: 14 GB Total
Empirical Evidence (Kernel OOM Log)
kernel: oom-kill:constraint=CONSTRAINT_NONE,global_oom,task=codebase-memory,pid=595953
kernel: Out of memory: Killed process 595953 (codebase-memory) total-vm:27850072kB, anon-rss:12855988kB
Root Cause
Unbounded Traversal: index_repository parsed over 237,000 files without default exclusions for Docker overlay volumes, package caches, or system headers.
Uncapped Heap Expansion: Multithreaded parsing outpaced memory cleanup, breaching the auto-calculated budget (budget_mb=7678) and consuming ~13 GB RAM until kernel termination.
Thanks. This report is from v0.8.1, while 0.9.0 changed worker supervision and memory accounting, so we need one current measurement before attributing the same failure. Please retest 0.9.0 against one explicit project root rather than the whole home/root tree, with CBM_DIAGNOSTICS=1, and share the discovered-file count plus the final error and peak RSS. Current main already excludes common caches such as .cache, node_modules, and vendor; a remaining runaway on an explicit project is actionable under #593 and 0.9.1-rc.
Thanks for the 0.9.0 retest on an explicit Laravel project. This materially broadens the issue beyond indexing a home/root directory.
The process reached about 23.1 GB RSS while mem.init reported an 11.1 GB budget. On current main that budget drives pressure signals and selected pipeline sizing/cleanup decisions; it is not a process-wide allocator ceiling, so this evidence shows those controls are not containing the affected path. The kernel OOM record also removes client-timeout ambiguity.
This remains priority/high in 0.9.1-rc, now as a general explicit-project memory runaway rather than only an unsafe-root traversal case. Thank you for providing the exact kernel evidence.
Thank you @EvilBeaver. This is fresh evidence that the memory runaway persists on v0.10.2 for a large monorepo, after the earlier Laravel reporter saw success on v0.10.0.
As already established in this thread, the current memory budget drives pressure signals and selected sizing/cleanup decisions; it is not a process-wide RSS ceiling. The OOM-killer result is therefore sufficient to keep this priority/high and active under #593. If readily available, a CBM_DIAGNOSTICS=1 trajectory plus approximate file count and language mix would help isolate the growing phase, but the issue is not waiting on that information.
Thank you, @kodexArg, @azizramdan and @EvilBeaver! The kernel OOM records and the per-version retests showed us this is a general memory problem, not just a home-directory one.
In v0.11.0, indexing allocates through a central memory core. Extraction slows down, spills to disk under the budget and stops cleanly instead of overshooting (PR #2202). The worker budget is also split across active jobs. On our benchmarks that cut peak memory by roughly 55–80% compared with v0.10.8. One remaining gap, in the phases after extraction, is being handled in a follow-up tracked in #2184.
@EvilBeaver, could you retry your monorepo on v0.11.0 with CBM_DIAGNOSTICS=1? We'd like to know whether it now finishes, or stops with a budget message instead of being OOM-killed.
Thank you again for the per-version and kernel OOM evidence. The last update requested the large-monorepo result on v0.11.0 and separated the remaining post-extraction work in #2184. I have no newer result from that workload to add; the earlier Laravel success is not proof for all large repositories.
@EvilBeaver, could you retry your monorepo on v0.11.0 with CBM_DIAGNOSTICS=1? We'd like to know whether it now finishes, or stops with a budget message instead of being OOM-killed.
Thank you for the 0.12.1 retest: completing the full monorepo without OOM is the result we needed. The earlier Laravel success and this workload confirmation are now both recorded.
Activity
DeusData commentedon Jul 24, 2026
Thanks. This report is from
v0.8.1, while0.9.0changed worker supervision and memory accounting, so we need one current measurement before attributing the same failure. Please retest0.9.0against one explicit project root rather than the whole home/root tree, withCBM_DIAGNOSTICS=1, and share the discovered-file count plus the final error and peak RSS. Current main already excludes common caches such as.cache,node_modules, andvendor; a remaining runaway on an explicit project is actionable under #593 and0.9.1-rc.azizramdan commentedon Jul 28, 2026
I also experienced this problem even though it was not in the root path
DeusData commentedon Jul 28, 2026
Thanks for the 0.9.0 retest on an explicit Laravel project. This materially broadens the issue beyond indexing a home/root directory.
The process reached about 23.1 GB RSS while mem.init reported an 11.1 GB budget. On current main that budget drives pressure signals and selected pipeline sizing/cleanup decisions; it is not a process-wide allocator ceiling, so this evidence shows those controls are not containing the affected path. The kernel OOM record also removes client-timeout ambiguity.
This remains priority/high in 0.9.1-rc, now as a general explicit-project memory runaway rather than only an unsafe-root traversal case. Thank you for providing the exact kernel evidence.
docs(hqm): the approved v0.2.0 cycle plan, and the rulings it rests on
azizramdan commentedon Aug 11, 2026
Just updated to version 0.10.0, and it's working now for the same Laravel project repo
EvilBeaver commentedon Aug 12, 2026
large monorepo (approx. 5Gb of source code) version 0.10.2, same issue, OOM Killer on 15Gb of RAM used
DeusData commentedon Aug 12, 2026
Thank you @EvilBeaver. This is fresh evidence that the memory runaway persists on v0.10.2 for a large monorepo, after the earlier Laravel reporter saw success on v0.10.0.
As already established in this thread, the current memory budget drives pressure signals and selected sizing/cleanup decisions; it is not a process-wide RSS ceiling. The OOM-killer result is therefore sufficient to keep this priority/high and active under #593. If readily available, a
CBM_DIAGNOSTICS=1trajectory plus approximate file count and language mix would help isolate the growing phase, but the issue is not waiting on that information.feat: A3b — ignore rules as two controls, machine-writing .cbmignore
fix: the whole-workspace stress test's two findings — B15 and B16
docs(hqm): the 2026-08-02 build-out gets its record; the registers ca…
DeusData commentedon Sep 26, 2026
Thank you, @kodexArg, @azizramdan and @EvilBeaver! The kernel OOM records and the per-version retests showed us this is a general memory problem, not just a home-directory one.
In v0.11.0, indexing allocates through a central memory core. Extraction slows down, spills to disk under the budget and stops cleanly instead of overshooting (PR #2202). The worker budget is also split across active jobs. On our benchmarks that cut peak memory by roughly 55–80% compared with v0.10.8. One remaining gap, in the phases after extraction, is being handled in a follow-up tracked in #2184.
@EvilBeaver, could you retry your monorepo on v0.11.0 with
CBM_DIAGNOSTICS=1? We'd like to know whether it now finishes, or stops with a budget message instead of being OOM-killed.DeusData commentedon Oct 19, 2026
Thank you again for the per-version and kernel OOM evidence. The last update requested the large-monorepo result on v0.11.0 and separated the remaining post-extraction work in #2184. I have no newer result from that workload to add; the earlier Laravel success is not proof for all large repositories.
EvilBeaver commentedon Oct 23, 2026
@DeusData ok, I'll try it.
EvilBeaver commentedon Oct 23, 2026
@DeusData version 0.12.1 - full monorepo indexed without OOM.
DeusData commentedon Oct 25, 2026
Thank you for the 0.12.1 retest: completing the full monorepo without OOM is the result we needed. The earlier Laravel success and this workload confirmation are now both recorded.