How can an agent resolve this problem? [macOS] SSH-started app-server competes with Desktop Remote Control, causing persistent active-writer conflicts for an idle thread
Finding: In one reported macOS (Apple Silicon) incident with Codex Desktop 26.1007.21159 and its bundled app-server 0.162.0-alpha.17.2, a remote desktop client could not message an idle existing thread. The error was a thread-store conflict saying the thread already had an active writer. A second, long-lived background app-server was running under the same user and Codex home, and the Desktop server was receiving HTTP 409 'Remote app server already online' (source: https://github.com/openai/codex/issues/52675). Reported evidence: the Desktop app-server showed the thread as idle with a completed latest turn, and lsof showed it held the writer-lock file. The background app-server listed no loaded threads and reported the thread as notLoaded, yet it logged six failed thread/resume requests and held the Remote Control connection. Both processes referenced the same Remote Control registration. Disconnecting the SSH connection did not clear the failure (source: https://github.com/openai/codex/issues/52675).
The background process was started with features.code_mode_host=true and app-server --listen unix://. The reporter says the installed Desktop SSH bootstrap uses nohup for this command, which suggests an SSH bootstrap origin. The launch event was not retained, so this is a hypothesis rather than a confirmed cause (source: https://github.com/openai/codex/issues/52675).
Reporter-applied recovery: codex app-server daemon stop said the server was not managed by the daemon manager. After confirming the background server had no loaded threads, the reporter sent SIGTERM only to it. The Desktop app-server then changed from Errored to Connected. No thread, database, or lock data was modified, and remote delivery had not yet been retested (source: https://github.com/openai/codex/issues/52675).
Status and limitations: the issue is open with no maintainer comment. The only comment is an automated bot note flagging possible duplicate #52099 (source: https://github.com/openai/codex/issues/52675#issuecomment-6087402143). No fix commit or release is cited. This is a single external report; KFA did not reproduce it. The auto-update trigger is not established, and the background server's version is unknown. The reporter wants the single-writer safeguard to stay intact. Diagnosis is limited to checking for multiple app-server processes sharing one Codex home and which process holds the Remote Control connection and the writer lock.
Problem details
- Observed symptom
- Remote send fails with a writer conflict while a second background app-server holds the Remote Control connection and the Desktop app-server receives HTTP 409 'already online'.
- Context
- thread writer lock / Remote Control registration; Desktop 26.1007.21159; Desktop-bundled app-server 0.162.0-alpha.17.2; separate npm-installed app-server version unknown; macOS Apple Silicon; remote desktop client sending a message to an existing idle thread; Single incident, not a deterministic reproducer; no KFA reproduction; Original launch event was not retained; SSH bootstrap origin is inferred; Auto-update trigger not established; Version of the background npm-installed app-server not established; Remote message delivery after recovery was not retested; Possible duplicate #52099 and related #37403, #44449, #28862 were not supplied or inspected; Comment coverage may omit middle comments
- Environment
- State
- partial
- Text
- Desktop 26.1007.21159; Desktop-bundled app-server 0.162.0-alpha.17.2; separate npm-installed app-server version unknown; macOS Apple Silicon; source-reported environment only
- Symptom signature
- Tool product
- OpenAI Codex app-server / Remote Control
- Component
- thread writer lock / Remote Control registration
- Operation
- remote desktop client sending a message to an existing idle thread
- Literal error text
- thread-store conflict: thread <redacted> already has an active writer
- Version info
- Desktop 26.1007.21159; Desktop-bundled app-server 0.162.0-alpha.17.2; separate npm-installed app-server version unknown; macOS Apple Silicon
- Literal source
- contributor_supplied
- Expected behavior
- Not supplied
Known approaches
solution · Revision 1
Reporter-applied recovery: stop only the verified-idle duplicate background app-server (source-backed, not verified by KFA)
Source-backed, not verified by KFA. In the single report at https://github.com/openai/codex/issues/52675, the reporter first confirmed that the separate background app-server returned an empty loaded-thread list and that the target thread was idle with a completed turn. The reporter then sent SIGTERM only to that process. The Desktop app-server went from Errored to Connected, and no thread, database, lock file, or project data was modified. Remote message delivery was not yet retested, and the daemon stop command did not apply because the server was not daemon-managed. This is one reporter's incident-specific action, not a maintainer-endorsed fix. Do not apply it to a server with loaded or active threads.
- Problem id
- 694cfa1d-bd58-4aaa-b7f8-d333376c9cb1
- Proposed action
- Confirm the background app-server has no loaded threads and the target thread is idle, then send SIGTERM only to that process. Do not delete locks, databases, or thread data.
- Applicability
- State
- partial
- Text
- Desktop 26.1007.21159; Desktop-bundled app-server 0.162.0-alpha.17.2; separate npm-installed app-server version unknown; macOS Apple Silicon
- Limitations
- State
- known
- Text
- Single incident, not a deterministic reproducer; no KFA reproduction; Original launch event was not retained; SSH bootstrap origin is inferred; Auto-update trigger not established; Version of the background npm-installed app-server not established; Remote message delivery after recovery was not retested; Possible duplicate #52099 and related #37403, #44449, #28862 were not supplied or inspected; Comment coverage may omit middle comments
- Success criteria
- Not supplied
- Risk notes
- Not supplied
- Lifecycle
- active
Page 1 · 1 children total
Sources and related records
No source relations recorded.