-
-
Notifications
You must be signed in to change notification settings - Fork 79.2k
openclaw logs --follow can show stale/misleading old-version file logs after side-by-side cutover #66841
Copy link
Copy link
Closed
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.ClawSweeper found a clear likely implementation shape for this issue.clawsweeper:queueable-fixClawSweeper marked this issue as an existing queue_fix_pr work candidate.ClawSweeper marked this issue as an existing queue_fix_pr work candidate.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Metadata
Metadata
Assignees
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.ClawSweeper found a clear likely implementation shape for this issue.clawsweeper:queueable-fixClawSweeper marked this issue as an existing queue_fix_pr work candidate.ClawSweeper marked this issue as an existing queue_fix_pr work candidate.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Summary
After side-by-side cutover, the live gateway service was running from the sidecar tree and reporting
2026.4.14, butopenclaw logs --followstill showed2026.3.28-beta.1and tailed repeated old warning lines from the rolling log file. This was operationally misleading during incident/debugging.Observed behavior
Live systemd gateway service:
ExecStart=/usr/bin/node /home/claw/openclaw-sidecar-2026-04-14/dist/index.js gateway --port 187892026.4.14But
openclaw logs --followoutput showed:OpenClaw 2026.3.28-beta.1 (50bc870)/tmp/openclaw/openclaw-2026-04-14.logConfig was last written by a newer OpenClaw (2026.4.12); current version is 2026.3.28-beta.1.Operational workaround during the incident was:
journalctl --user -u openclaw-gateway.service -fWhy this is a bug
The command appears to promise live OpenClaw logs. In practice it can show stale or version-mismatched file-log output. This is especially misleading during cutover, split-install, or recovery situations.
Source-backed likely root cause
Current implementation source:
src/cli/logs-cli.tsNotable details:
Tail gateway file logs via RPClogs.tailSo after side-by-side cutover it can follow configured rolling file logs from an old CLI/install context rather than the authoritative current service journal.
Repro steps
openclaw logs --followjournalctl --user -u openclaw-gateway.service -fActual behavior
openclaw logs --followcan show stale or version-mismatched old-version file-log output after side-by-side cutover.Expected behavior
openclaw logs --followshould follow the active gateway service logs on Linux when possible.Requested fix
Please do both:
On Linux, make
openclaw logs --followprefer the active systemd service journal when available.openclaw-gateway.servicejournal as the source of truthBefore following any source, print explicit provenance:
ExecStartProposed Linux/systemd behavior
In systemd environments, prefer the current
openclaw-gateway.servicejournal as the authoritative live-log source.Only use rolling file-tail fallback when service-aware log access is unavailable, and make that fallback explicit in output.