mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #5411] [Engine] Repeated start/stop leaves ~178 GiB on anonymous LRU and eventually freezes the host #3231
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#3231
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @hualiyexi on GitHub (Nov 6, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/5411
Area: Engine
Problem
After several Strata engine start/stop cycles, large amounts of anonymous memory remain on the kernel LRU lists after all Strata processes have exited. The memory does not return to baseline, eventually exhausting swap and freezing the host.
Environment
--kv-resident 32768; KV formats used during the affected test session includedint8,k8v4, andq4_0One affected two-GPU preset resolved to:
The three-GPU configuration used
gpus=0,1,2,context=262144,kv=k8v4, andparallel=8.Reproduce
Start the engine using one of the affected presets:
Wait for the model to become ready and issue several generation requests.
Stop the engine:
Confirm that the Strata processes have exited and that
nvidia-smireports no compute applications.Record the anonymous-memory counters:
Also record
memory.currentandmemory.statfor the cgroup from which Strata was launched.Repeat the start/stop cycle several times and compare the counters with the pre-launch baseline.
On this host, the launching cgroup was:
The cgroup path will differ on other systems.
Expected
When the engine exits, all host pages allocated or pinned for KV streaming and expert arenas should be released.
Active(anon),Inactive(anon), and the launching cgroup'smemory.currentshould return approximately to their pre-launch values without requiring a reboot.Actual
The anonymous LRU counters remain elevated after the engine and its CUDA contexts disappear. Repeating start/stop cycles accumulates more retained memory.
During the eventual memory-exhaustion event, the kernel reported order-7 and order-9 page-allocation failures in the
strataprocess. Available swap fell to 56 kB, followed by multipleCannot map memorymessages. The host subsequently froze and required a hard reboot.Evidence
Memory accounting after engine exit
On 2026-11-07, with no Strata process running:
The launching cgroup contained:
Thus, only about 478 MiB remained as mapped anonymous memory in that cgroup, while approximately 166.8 GiB remained on its active/inactive anonymous LRU lists.
cgroup.procscontained only the desktop/ZCode tooling used to launch the tests, with no Strata process.These counters do not by themselves prove generic “kernel-space memory usage.” The significant observation is that the pages no longer have corresponding userspace mappings but remain allocated on the anonymous LRU lists and charged to the launching cgroup.
Kernel stack from the memory-exhaustion event
journalctl -k -bcaptured the following path during the order-7/order-9 allocation failures:This directly connects the affected host-memory allocations to NVIDIA's long-term page-pinning path.
The remaining ownership question is whether Strata is missing a pinned-host-allocation release on some normal/error/exit paths, or whether the NVIDIA driver is failing to release all page pins during final client cleanup. The current evidence does not conclusively assign the defect to only one of those layers.
Other checks
/dev/shmwas empty andShmemwas only about 0.2 GiB.nvidia-smi --query-compute-appsshowed no compute processes after engine exit.drop_cachesandcompact_memorydid not release the retained anonymous pages.memory.reclaimprobe reclaimed file cache but did not reduce the total active/inactive anonymous memory. Approximately 35.8 GiB merely moved betweeninactive_anonandactive_anon.Full sanitized
meminfo, cgroup statistics, and kernel allocation-failure logs can be provided if needed.Reproduction status
Reproduced locally through repeated Strata start/stop cycles on the host described above. This is an observed runtime issue, not a code-only or scanner-derived finding.
@github-actions[bot] commented on GitHub (Nov 6, 2026):
Thanks for the issue. To keep the tracker readable, every item needs an area prefix in the title and the parts of the issue form filled in. This one is missing:
Edit the issue (title and description) and this note goes away on its own. If it is still missing parts in 5 days it will be closed, which is not a rejection: fix it and comment
/reopen.Details: CONTRIBUTING.md
@github-actions[bot] commented on GitHub (Nov 7, 2026):
Thanks, this follows the format now.