openclaw - 💡(How to fix) Fix [SRE] Gateway SIGABRT (134) on macOS launchd (mini-lobby) [1 comments, 1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#71848Fetched 2026-04-26 05:07:32
View on GitHub
Comments
1
Participants
1
Timeline
1
Reactions
0
Author
Participants
Timeline (top)
commented ×1

On the mini-lobby machine (macOS Darwin), the OpenClaw Gateway fails to start when managed by launchctl, returning exit code 134 (SIGABRT).

Root Cause

On the mini-lobby machine (macOS Darwin), the OpenClaw Gateway fails to start when managed by launchctl, returning exit code 134 (SIGABRT).

Fix Action

Fix / Workaround

Workaround Applied

  • Reverted to 4GB limit for stability.
  • Bypassed launchd by using a manual background start script (~/.openclaw/bin/openclaw-start.sh) which uses nohup and explicit exports.
RAW_BUFFERClick to expand / collapse

Description

On the mini-lobby machine (macOS Darwin), the OpenClaw Gateway fails to start when managed by launchctl, returning exit code 134 (SIGABRT).

Investigation Findings

  • Foreground Success: Running the exact same command in an interactive terminal works perfectly.
  • launchd Failure: The LaunchAgent (ai.openclaw.gateway.plist) consistently crashes.
  • Suspicious Config: The original .plist had a hardcoded TMPDIR (/var/folders/zp/...) which is session-specific on macOS and likely became stale/invalid.
  • Memory Pressure: The process was previously consuming ~3.5GB of RAM. Attempting to increase --max-old-space-size to 8192 (8GB) caused background starts to fail even more reliably, possibly hitting a per-process limit for non-interactive tasks.
  • Port Binding: Even when the process appeared 'alive' in ps, it often failed to bind to port 18789 when backgrounded via launchd.

Workaround Applied

  • Reverted to 4GB limit for stability.
  • Bypassed launchd by using a manual background start script (~/.openclaw/bin/openclaw-start.sh) which uses nohup and explicit exports.

Environment

  • OS: Darwin (macOS)
  • Node: v25.9.0
  • OpenClaw: 2026.4.23 (a979721)
  • Hardware: 16GB RAM

extent analysis

TL;DR

The OpenClaw Gateway failure to start via launchctl on macOS may be resolved by adjusting the TMPDIR environment variable and ensuring the process doesn't exceed system limits for non-interactive tasks.

Guidance

  • Review and adjust the TMPDIR setting in the ai.openclaw.gateway.plist file to use a non-session-specific directory.
  • Verify that the --max-old-space-size limit is set to a reasonable value that doesn't exceed system limits for background processes.
  • Consider implementing a more robust startup script that handles environment variables and resource limits explicitly.
  • Investigate system logs and launchd configuration to ensure that the LaunchAgent is properly configured and that there are no other system-level limitations preventing the process from starting.

Example

No specific code example is provided due to the lack of direct code references in the issue, but adjusting the TMPDIR in the .plist file might look something like setting an environment variable in the launch agent configuration.

Notes

The exact solution may depend on specific system configurations and version details not fully provided in the issue. The provided workaround using a manual start script suggests that environment and resource management are key factors.

Recommendation

Apply workaround: The current workaround using ~/.openclaw/bin/openclaw-start.sh seems to stabilize the service, but a more permanent solution should involve fixing the launchd configuration and ensuring environment variables are correctly set for non-interactive sessions.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix [SRE] Gateway SIGABRT (134) on macOS launchd (mini-lobby) [1 comments, 1 participants]