Codex WSL error: codex-linux-sandbox “doesn’t exist” (ENOENT)

A full Codex Desktop restart rebuilt the missing helper directory for one reporter. Native Windows mode or the Ubuntu CLI are safer fallbacks by repository location.

Quick answer

Fully quit Codex Desktop—not just the window—then reopen it and start a fresh conversation. One reporter confirmed the restart created a new sandbox helper directory. If it repeats, use native mode for Windows repositories or the Linux CLI inside Ubuntu for WSL repositories.

The exact error

Unable to spawn codex-linux-sandbox because it doesn't exist on the filesystem (ENOENT)

Do not use this guide for a merely similar message. The workaround is scoped to this signature and the environments below.

Match your environment

  • Windows 11 with WSL2
  • Codex Desktop
  • New or resumed tool calls

What to do

  1. 01

    Stop retrying the same tool call

    The error occurs before the requested command starts. Repeating that command cannot recreate a missing sandbox executable.

  2. 02

    Fully exit Codex Desktop

    Close the app and confirm its background process is no longer running, then reopen it. A first-hand report found this generated a fresh helper location.

  3. 03

    Create a fresh conversation

    Test a harmless command in a new chat before resuming an old thread. This separates stale conversation runtime state from a machine-wide failure.

  4. 04

    Match the runtime to the repository

    For a repository stored on Windows, use native Windows mode. For a repository inside the WSL filesystem, open Ubuntu and run the Linux Codex CLI there.

What likely happened

Codex attempted to launch a generated Linux sandbox helper from a path that no longer existed. The confirmed restart recovery suggests stale or missing runtime material, but the reports do not prove why it disappeared.

First-hand sources

Source links support the environment and workaround claims above. An issue being closed does not by itself mean a fix shipped.