Repository navigation
Regression: macOS migration clones installation identity and Remote Control fails with 409 #36295
Description
What version of the Codex App are you using?
ChatGPT desktop app with bundled Codex:
- App version:
26.727.40816 - Bundle build:
6067
What subscription do you have?
Not relevant to the failure; the same ChatGPT account was used on both Macs.
What platform is your computer?
- Destination: Mac mini (
Mac16,10), Apple Silicon (arm64) - macOS
26.6(25G72) - Source: MacBook Pro
- The destination Mac was migrated from the source Mac using macOS Migration Assistant / copied user data.
Real hostnames and all account, installation, environment, server, request, and key identifiers are intentionally redacted.
What issue are you seeing?
After migrating from a MacBook Pro to a Mac mini, enabling Settings > Connections > Control this Mac > Allow connections failed. The toggle returned to the off state and the desktop app showed:
Couldn't update remote control availability
The app server repeatedly attempted to connect to:
wss://chatgpt.com/backend-api/wham/remote/control/server
and received:
HTTP error: 409 Conflict
body: {"detail":"Remote app server already online"}
Only one ChatGPT desktop process and one bundled Codex app-server process were running locally when checked, so this was not caused by two active local app-server processes.
The source and destination Macs had inherited the same machine-scoped identity from:
~/.codex/installation_id
Historical local logs showed the same installation identity being used first by the source Mac and later by the destination Mac, despite different hostnames. The backend therefore treated the two physical Macs as the same Remote host.
Signing out was not a recovery mechanism: signing out affected both devices, and signing back in did not regenerate the local installation identity. A normal app reinstall would also be expected to preserve ~/.codex, so it does not provide an obvious fresh-device path. Existing projects still appeared after sign-in because the local project/thread state was preserved; this is expected but makes it less clear to a user that the machine identity was also preserved.
This appears to be a regression or still-unhandled case of #22950 on a substantially newer app build. It is also related to the stale-enrollment 409 Conflict behavior in #24024, but the trigger here was machine migration and a cloned installation_id, not idle time or a network transition.
What steps can reproduce the bug?
- Install and use ChatGPT/Codex on a source Mac with Remote Control enrolled.
- Migrate the source Mac's user account/data to a second Mac using macOS Migration Assistant or another mechanism that copies
~/.codex. - Keep or later run ChatGPT/Codex on both physical Macs under the same ChatGPT account.
- On the migrated destination Mac, open Settings > Connections > Control this Mac.
- Enable Allow connections.
- Observe the generic
Couldn't update remote control availabilitytoast. - Inspect
~/.codex/logs_2.sqliteand observe repeated409 Conflictresponses with{"detail":"Remote app server already online"}. - Compare
~/.codex/installation_idon both physical Macs and observe that Migration Assistant cloned the machine-scoped identity.
Workaround that resolved the issue
The recovery was performed only on the migrated destination Mac.
- Fully quit ChatGPT/Codex and related Remote/app-server processes on both Macs.
- Back up the relevant local files:
~/.codex/installation_id
~/.codex/.codex-global-state.json
~/.codex/state_5.sqlite
- Move aside the migrated identity:
mv ~/.codex/installation_id <backup-location>/installation_id.migrated- Clear only the persisted Remote Control enrollment rows, preserving the rest of the thread/project database:
sqlite3 ~/.codex/state_5.sqlite "DELETE FROM remote_control_enrollments;"- Remove the mirrored local Remote host identity keys from
~/.codex/.codex-global-state.json:
electron-local-remote-control-installation-id
electron-local-remote-control-environment-id
The client/controller enrollment keys were not intentionally removed.
- Restart ChatGPT/Codex on the destination Mac.
- The app generated a different
~/.codex/installation_id, created one fresh Remote enrollment row, and the global-state installation ID matched the new file. - Enable Allow connections again.
- The next observed Remote websocket result was
connected; the repeated409loop stopped.
The workaround preserved local projects, chats/threads, plugins, and general Codex configuration.
What is the expected behavior?
- A machine-scoped installation identity should not be silently cloned onto different physical hardware during Migration Assistant restore.
- On startup, Codex should detect that a persisted installation identity is running on materially different hardware and either regenerate it or prompt the user.
- Receiving
409 Conflict: Remote app server already onlinefor a migrated/cloned identity should trigger a safe re-enrollment flow instead of indefinite retries and a generic availability toast. - Settings should provide a supported Repair Remote Control or Reset this device identity action.
- Signing out or reinstalling should clearly explain whether local device enrollment is preserved.
- Recovery should not require manually editing JSON or SQLite.
- The error shown in Settings should distinguish duplicate device identity from network, authentication, workspace-policy, or permission failures.
Related issues
- Codex mobile Remote Control shows only one macOS host and overwrites it with the last active desktop host #22950 — same Migration Assistant / duplicated
~/.codex/installation_idroot cause; closed as completed on an older build - Remote control can get stuck after idle or network changes with 409 Conflict until re-enrollment #24024 — related persistent
409 Conflict/ stale enrollment family; different trigger
Additional confirmation after recovery
- The destination Mac's regenerated installation identity differs from the migrated identity.
- The global-state mirror matches the new identity.
- Exactly one fresh Remote enrollment row exists.
- The latest Remote Control websocket event is a successful connection.
This report intentionally omits raw identifiers and credentials. Sanitized logs with timestamps or request IDs can be provided privately if maintainers need them.
Activity
github-actions commentedon Jul 31, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
jsegeren commentedon Sep 10, 2026
This is exactly why Codex Migrate deliberately excludes the source Mac’s
auth.jsonandinstallation_id. The destination Mac is opened and signed into first, then the tool transfers the portable Codex state and selected workspaces while verifying that the destination identity remains unchanged.It won’t repair an identity already cloned by Migration Assistant; it prevents that identity from being copied during a clean Mac-to-Mac move. The migration stages over SSH, verifies a destination backup before replacement, and supports pause/resume and recovery.
CLI and source: https://github.com/jsegeren/codex-migrate
Signed/notarized Apple-silicon beta: https://migrate.segeren.com
Disclosure: I maintain Codex Migrate independently; it is not affiliated with OpenAI.
swopec commentedon Sep 23, 2026
Reproducing this on desktop app 26.917.62051, on Darwin 25.6.0 arm64 arm, after copying/migrating an office MacBook to a new Mac.
On the new Mac, Settings > Connections > Control this Mac > Allow connections briefly shows the paired phone, then switches itself off with:
Local remote-control logs repeatedly report:
Fully quitting the app on the original Mac and retrying did not resolve it. A local process check showed one bundled Codex server on the new Mac. A copied/stale registration is suspected; identities have not been compared directly on both Macs. No manual identity or database reset has been performed.
In-app feedback ID:
01a0d006-f81c-7831-888b-2b2ede9014c7Please advise on a supported way to re-enroll only the new Mac while preserving chats, projects, plugins, and the original Mac’s registration.
sdkearney-GPT commentedon Oct 12, 2026
Confirmed reproduction and successful recovery on October 12, 2026, on ChatGPT desktop app 26.1007.30912 (build 20156; updater reported up to date).
After Apple Migration Assistant copied a MacBook setup to a new Mac, both physical Macs had identical SHA-256 fingerprints of ~/.codex/installation_id. Native desktop-to-desktop pairing consistently showed “Failed to update connection” on the MacBook while the new Mac reported connected. The new Mac also showed “Couldn't update remote control availability” and reverted Allow connections. Recent local logs contained repeated 409 Conflict / “Remote app server already online” messages.
Matching account/workspace, restarting/signing in again, revoking the old pairing, and attempting fresh pairing did not resolve it. An iPhone could reach the new Mac even while desktop-to-desktop pairing failed, so mobile success alone did not rule out the cloned identity.
Recovery on the migrated destination Mac only, with both apps fully quit: backed up installation_id, global-state JSON, and a consistent SQLite snapshot; removed the installation identity and the two mirrored local host identity keys; cleared remote_control_enrollments while preserving unrelated database state. On relaunch the destination generated a distinct identity; JSON and database integrity checks passed, one fresh enrollment existed, and no duplicate-server conflicts appeared during the short verification window. Re-pairing then succeeded, the MacBook listed the new Mac, and the user sent a test message into the destination-hosted chat.
Please provide a supported migration-aware identity repair flow that preserves local chats/projects and distinguishes identity conflicts from network/authentication errors. The transient generic toast and contradictory host/controller success states made this take substantial manual troubleshooting. No raw device identifiers, credentials, or private logs are included. The earlier Android authentication issue has not been established as the same cause.