openclaw - 💡(How to fix) Fix Gateway crashes ~18s after startup due to bonjour name conflict with other local services [1 comments, 2 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#73922Fetched 2026-04-29 06:13:13
View on GitHub
Comments
1
Participants
2
Timeline
2
Reactions
0
Timeline (top)
closed ×1commented ×1

Root Cause

Three local LaunchAgent plists with RunAtLoad=true register bonjour services that collide with the gateways bonjour name:

  1. com.zj.cloudflared-zjaios-ai
  2. com.zj.real-estate-os-server
  3. com.zjaios.frontend5173

The bonjour name conflict causes the gateway to crash rather than gracefully adopting a different name.

Code Example

# Boot out conflicting services
launchctl bootout gui/$UID/com.zj.cloudflared-zjaios-ai
launchctl bootout gui/$UID/com.zj.real-estate-os-server
launchctl bootout gui/$UID/com.zjaios.frontend5173

# Reinstall gateway
openclaw gateway install --force
RAW_BUFFERClick to expand / collapse

Bug Description

Gateway starts successfully but crashes after ~18 seconds with unhandled_rejection, entering crashloop. The root cause is a bonjour/mDNS name conflict between the OpenClaw gateway and other local services registered as LaunchAgents on the same machine.

Environment

  • Hardware: Mac mini (Apple Silicon arm64)
  • OS: Darwin 24.14.0
  • OpenClaw version: 2026.4.24 (cbcfdf6)

Symptoms

  • Gateway probe reports: timeout / ECONNRESET / gateway closed (1006)
  • stability bundle shows events=[] count=0 — crash stack trace is not captured by the stability bundle
  • Crashloop: gateway restarts, runs ~18s, crashes again

Root Cause

Three local LaunchAgent plists with RunAtLoad=true register bonjour services that collide with the gateways bonjour name:

  1. com.zj.cloudflared-zjaios-ai
  2. com.zj.real-estate-os-server
  3. com.zjaios.frontend5173

The bonjour name conflict causes the gateway to crash rather than gracefully adopting a different name.

Temporary Fix

# Boot out conflicting services
launchctl bootout gui/$UID/com.zj.cloudflared-zjaios-ai
launchctl bootout gui/$UID/com.zj.real-estate-os-server
launchctl bootout gui/$UID/com.zjaios.frontend5173

# Reinstall gateway
openclaw gateway install --force

After this, probe: ok is restored. However, the conflicting plists have RunAtLoad=true, so the crash will recur after reboot.

Suggested Fixes (from the field)

  1. Bonjour auto-rename on conflict: When gateway detects a bonjour name collision, it should auto-append a suffix or fall back to a unique name (Apple DNSSD supports this pattern natively).

  2. Stability bundle should capture unhandled_rejection stack traces: Currently events=[] count=0 even when the crash is an unhandled promise rejection. The full stack needs to be written before exit.

  3. Bonjour pre-flight check on gateway startup: Before registering its bonjour service, the gateway should check for existing registrations with the same name and emit a clear, friendly warning explaining the conflict — rather than crashing silently 18 seconds later.

extent analysis

TL;DR

Boot out conflicting LaunchAgent services and reinstall the gateway to temporarily resolve the crashloop caused by the bonjour/mDNS name conflict.

Guidance

  • Identify and boot out conflicting LaunchAgent services using launchctl bootout to prevent immediate crashes.
  • Reinstall the gateway using openclaw gateway install --force to ensure a clean setup.
  • Consider implementing a bonjour pre-flight check on gateway startup to detect and warn about name conflicts before registration.
  • To prevent recurrences after reboot, modify the conflicting plists to set RunAtLoad=false or implement a permanent fix like bonjour auto-rename on conflict.

Example

launchctl bootout gui/$UID/com.zj.cloudflared-zjaios-ai
launchctl bootout gui/$UID/com.zj.real-estate-os-server
launchctl bootout gui/$UID/com.zjaios.frontend5173
openclaw gateway install --force

Notes

The provided temporary fix only addresses the immediate issue and does not prevent the crash from recurring after a reboot. A more permanent solution, such as implementing bonjour auto-rename on conflict or modifying the conflicting services, is necessary for long-term stability.

Recommendation

Apply the workaround by booting out conflicting services and reinstalling the gateway, as this provides a temporary solution to restore functionality while a more permanent fix is developed and implemented.

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 Gateway crashes ~18s after startup due to bonjour name conflict with other local services [1 comments, 2 participants]