Repository navigation
[App/Windows] MCP/plugin subprocess groups scale linearly with active task runtimes #32694
Description
Summary
On Codex Desktop 26.707.8168.0 on Windows 11, enabled MCP/plugin subprocess groups appear to be launched separately for each active task runtime. Process count and memory usage therefore grow roughly linearly with runtime count instead of being pooled, deduplicated, or stopped when no longer needed.
Related to #20867, but this report isolates the per-runtime subprocess fan-out rather than browser MCP startup alone.
Sanitized observation
With approximately 6 active task runtimes and 5 enabled MCP/plugin services:
- 36 node.exe processes
- approximately 1.99 GB combined working set
- 12 Playwright-related processes, approximately 861 MB
- 12 server.mjs processes, approximately 564 MB
- 6 server.bundle processes, approximately 320 MB
- 6 server.cjs processes, approximately 244 MB
The repeated process groups tracked the number of active runtimes. Disabling unused plugins prevented new groups from being started, but existing groups remained until the desktop application was fully quit.
No raw command lines, local paths, account identifiers, task contents, or configuration secrets are included in this report.
Steps to reproduce
- Enable several MCP/plugin services in Codex Desktop.
- Start multiple tasks or agent runtimes in the desktop application.
- Observe node.exe child processes after each runtime becomes active.
- Close or finish tasks without fully quitting Codex.
- Compare process groups and aggregate working set with the number of active runtimes.
Actual behavior
Each runtime appears to receive its own MCP/plugin subprocess group. Multiple groups remain resident and can consume gigabytes of memory in an ordinary multi-task session.
Expected behavior
- Share or pool stateless MCP services where safe.
- Deduplicate equivalent subprocess configurations.
- Start services lazily when a tool is first used.
- Reliably terminate runtime-owned subprocesses when the runtime ends.
- Expose ownership and lifecycle information in diagnostics.
Environment
- Codex Desktop: 26.707.8168.0
- OS: Windows 11 x64
- WSL2 workspaces are used, but the observed child processes are Windows node.exe processes.
Activity
github-actions commentedon Jul 13, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
tnt2ray commentedon Jul 15, 2026
I can reproduce this on Linux, with additional evidence that the MCP subprocess fan-out is caused by eager plugin/tool initialization rather than actual tool usage.
Environment:
build-ios-appsplugin 0.1.2xcodebuildmcp2.6.2The
build-ios-appsplugin started XcodeBuildMCP even though Xcode and iOS Simulator cannot run on Linux.I scanned all active and archived rollout JSONL files:
mcp__XcodeBuildMCP__*calls: 0build-ios-appsskill reads/triggers: 0The affected runtimes were performing unrelated work such as Markdown import, SQL concurrency review, release review, and Linux SSH diagnostics.
Codex logs show the MCP being started during runtime initialization:
The server is then queried while Codex builds the global tool list:
Six concurrent process trees were observed:
Together they consumed approximately 1.2 GiB on a 1.9 GiB host. The machine entered sustained memory/swap pressure, systemd-journald repeatedly logged
Under memory pressure, flushing caches, I/O wait reached 57%, and SSH became unresponsive.There is also an uninstall lifecycle problem:
reported success and briefly removed the cache. Existing MCP processes had to be killed manually. The running App Server later recreated the plugin cache and started XcodeBuildMCP again. During later unrelated turns, new instances continued appearing.
This appears to confirm the per-runtime fan-out reported here and adds:
This also appears related to #32997, where killing duplicate MCP processes is only a temporary workaround.
clear-er commentedon Jul 15, 2026
Windows controlled A/B: Build iOS Apps configured
enabled=falsespawned seven XcodeBuildMCP trees in a new unrelated threadI can reproduce the same eager per-runtime MCP fan-out on Windows with a controlled Build iOS Apps / XcodeBuildMCP A/B. This isolates one bundled plugin on an unsupported host and does not depend on historical threads, subagents, or an iOS-related prompt.
Environment
26200.8875, x64, 16 logical processors26.707.72221OpenAI.Codex26.707.9981.0, x64build-ios-apps@openai-curated; previously observed cache version0.1.2Configuration state
The installed plugin had this user-level configuration:
The current Codex config schema recognizes plugin-level
enabledand also provides a more explicit per-plugin MCP overlay whoseenabled = falseis documented in the schema as skipping server initialization. I did not add or test the server-specific overlay, so this report distinguishes the observed plugin-level state from that untested control.Reproduction conditions
node.exe,codex.exe,ChatGPT.exe, or XcodeBuildMCP process is present.No reproduction was rerun after this controlled sequence.
Controlled A/B results
2026-07-16 00:00:132026-07-16 00:08:122026-07-16 00:20:23The dedicated XcodeBuildMCP CSV contained 14 matching Node rows: seven
npxlauncher nodes and sevenxcodebuildmcpworker nodes. Together they used approximately1,356.3 MiBprivate memory and1,320.0 MiBworking set. This is consistent with the approximately1.323 GBdrop in total Node private memory between the installed and post-uninstall snapshots.Sanitized command patterns:
Sanitized ancestry:
All 14 matching Node rows descended from the Codex app-server. The remaining 21 Node processes were classified only heuristically as other MCP-related processes and are not claimed as part of this bug.
Actual behaviour
enabled = false, yet seven launcher/worker trees appeared.Expected behaviour
enabled = falseshould not initialize its bundled MCP server.Workaround
Uninstalling Build iOS Apps through the supported plugin UI and fully restarting Codex removed all matching XcodeBuildMCP processes in this controlled test.
Scope limitation
This evidence does not claim that Codex, Build iOS Apps, or XcodeBuildMCP caused a separate Windows kernel-pool problem. It establishes only plugin lifecycle, platform-gating, configuration-enforcement, process fan-out, and user-mode memory impact. It also does not attribute a defect to the upstream XcodeBuildMCP package.
Related reports: #33343 (unsupported Linux host; closed in favour of this issue), #28443 (per-plugin false ignored), #32942 (restored-task Xcode policy bypass), #17574 (XcodeBuildMCP helper lifecycle), and #32154 (eager per-chat MCP startup on Windows/WSL2).
All paths, usernames, process IDs, account identifiers, task contents, and unrelated command lines are omitted or generalized. No raw PoolMon or full process inventory is attached.