You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug][Linux]: dashboard updater is killed when stopping its own systemd service #5750
A dashboard update stopped opencodex-proxy.service and killed its own update worker, leaving the proxy offline and the old package installed. The worker uses detached: true, but remains in the service's systemd cgroup. The generated unit's default KillMode=control-group terminates it when the updater stops the service.
Expected: the updater survives proxy shutdown, completes installation, and restarts the service.
Reproduction
Install via npm and run OpenCodex through its generated systemd user service.
Start a dashboard update with restart enabled.
The service stops, the update worker disappears, and update-job.json remains running with a dead PID. The dashboard origin refuses connections.
Version
2.63.0-preview.20260923, updating to 2.64.0. The affected spawn path is also present in the published 2.64.0 package.
Operating system
Ubuntu 24.04.4 LTS, systemd 255.
Provider and model
Not provider-specific.
Cause and tested workaround
src/update/job.ts, spawnGuiUpdateWorker(): the non-Windows branch spawns the worker detached without isolating it from the service cgroup.
Locally wrapping the Linux service-managed worker with systemd-run --user --scope --quiet --collect -- <runtime> <worker args> fixed the failure while retaining KillMode=control-group. We verified the worker moved to its own scope and survived the service stop. Retrying through /api/update/run then installed 2.64.0, restarted the service automatically, and reported succeeded after its health stability check.
Related: #587 covers stale job recovery; #4173 covers broader update orchestration. This report concerns the worker being killed during service shutdown.
Checks
I searched existing issues and documentation.
I removed secrets, tokens, account details, request credentials, and personal data.
Triage: priority: P1 — Linux dashboard updater is killed by its own systemd service stop, leaving the proxy offline.
Criteria (P1): High: reproducible failure in a core path (routing, failover, account pool, streaming, usage, auth, install) with no clean workaround; or a small (<300 LOC) bug-fix PR for such a failure.
Fixed on dev by #5908 (merge 45ffcdc): when the proxy runs under systemd (INVOCATION_ID set) and a no-op systemd-run --user --scope probe succeeds, the dashboard update worker is launched through systemd-run --user --scope --quiet --collect, your verified workaround, so it survives the service stop. Every other case keeps the old spawn. Thanks for the precise diagnosis.
Activity
github-actions commentedon Sep 24, 2026
Issue reopened
The report now contains the information required by the automated check. Thanks for updating it.
devin-ai-integration commentedon Sep 25, 2026
Triage:
priority: P1— Linux dashboard updater is killed by its own systemd service stop, leaving the proxy offline.Criteria (P1): High: reproducible failure in a core path (routing, failover, account pool, streaming, usage, auth, install) with no clean workaround; or a small (<300 LOC) bug-fix PR for such a failure.
Related issues:
No open pull request addresses this yet.
Merge PR #5908: bug-PR merge train batch 4 (#5824, #5750)
lidge-jun commentedon Sep 26, 2026
Fixed on
devby #5908 (merge 45ffcdc): when the proxy runs under systemd (INVOCATION_IDset) and a no-opsystemd-run --user --scopeprobe succeeds, the dashboard update worker is launched throughsystemd-run --user --scope --quiet --collect, your verified workaround, so it survives the service stop. Every other case keeps the old spawn. Thanks for the precise diagnosis.fix(update): launch the Linux dashboard update worker outside the ser…