#I use openclaw in powershell and when I do "openclaw gateway restart" it says scheduled task restart
1 messages · Page 1 of 1 (latest)
That message means you’re on the native Windows Scheduled Task restart path. If it says it scheduled the restart but nothing changes, I’d first check whether the task actually exists/runs, or whether you’re running a manual foreground gateway instead of the managed service.
Can you paste these outputs?
openclaw --version
openclaw gateway status
openclaw status --all
schtasks /Query /TN "OpenClaw Gateway" /V /FO LIST
If schtasks says the task doesn’t exist, reinstall the gateway service:
openclaw gateway install
openclaw gateway restart
openclaw gateway status
If you’re using WSL2 instead, run the restart inside WSL, not plain PowerShell:
wsl
openclaw gateway status
openclaw gateway restart
Native Windows is still the bumpier path; WSL2 is the recommended one if you want the least weirdness. Docs: https://docs.openclaw.ai/platforms/windows and https://docs.openclaw.ai/help/faq
Restarted Scheduled Task: OpenClaw Gateway
Gateway restart failed after 93s: service stayed stopped and port 18789 stayed free.
Service runtime: status=stopped, state=Queued
Gateway port 18789 status: free.
Gateway restart failed after 93s: service stayed stopped and health checks never came up.
Tip: openclaw gateway status --deep
Tip: openclaw doctor
PS C:\Windows\system32>
Yep — that narrows it down. OpenClaw successfully asked Windows Task Scheduler to run OpenClaw Gateway, but Windows left the task in Queued, so the gateway process never started. Since the port stayed free, this is not a port conflict; it’s Task Scheduler not launching the task.
Next checks:
openclaw --version
openclaw gateway status --deep
openclaw doctor
schtasks /Query /TN "OpenClaw Gateway" /V /FO LIST
Get-ScheduledTask -TaskName "OpenClaw Gateway" | Format-List *
Get-ScheduledTaskInfo -TaskName "OpenClaw Gateway" | Format-List *
Also try reinstalling the native Windows service task, because the task action may be stale/broken:
openclaw gateway uninstall
openclaw gateway install
openclaw gateway restart
openclaw gateway status --deep
If it still stays Queued, the practical fix is to use WSL2 instead of native PowerShell — native Windows support exists, but WSL2 is the recommended/stabler path right now: https://docs.openclaw.ai/platforms/windows
If you paste the schtasks output, especially Task To Run, Last Run Result, and conditions/settings, we can tell what Windows is blocking.
if it uninstall will it reset all my data
No — openclaw gateway uninstall should only remove the background service / Scheduled Task and its launcher script. It should not wipe your OpenClaw config, sessions, memory, auth, workspace, etc.
Your data is normally under something like:
%USERPROFILE%\.openclaw
So this flow is meant to be safe:
openclaw gateway uninstall
openclaw gateway install
If you want extra peace of mind before doing it, make a copy of %USERPROFILE%\.openclaw first. But don’t delete that folder unless you intentionally want a reset.
Install the latest PowerShell for new features and improvements! https://aka.ms/PSWindows
PS C:\Windows\system32> openclaw gateway status --deep
🦞 OpenClaw 2026.5.7 (eeef486) — Greetings, Professor Falken
|
o
Service: Scheduled Task (registered)
File logs: ~\AppData\Local\Temp\openclaw\openclaw-2026-05-11.log
Command: C:\Program Files\nodejs\node.exe C:\Users\jabuc\AppData\Roaming\npm\node_modules\openclaw\dist\index.js gateway --port 18789
Service file: ~.openclaw\gateway.cmd
Service env: OPENCLAW_GATEWAY_PORT=18789
Config (cli): ~.openclaw\openclaw.json
Config (service): ~.openclaw\openclaw.json
Gateway: bind=loopback (127.0.0.1), port=18789 (service args)
Probe target: ws://127.0.0.1:18789
Dashboard: http://127.0.0.1:18789/
Probe note: Loopback-only gateway; only local clients can connect.
Runtime: stopped (state Queued, last run 0, last run time 5/11/2026 9:02:10 AM, Task Last Run Result=0; treating as not running.)
Connectivity probe: failed
Probe target: ws://127.0.0.1:18789
connect ECONNREFUSED 127.0.0.1:18789
Capability: unknown
Service is loaded but not running (likely exited immediately).
File logs: C:\Users\jabuc\AppData\Local\Temp\openclaw\openclaw-2026-05-11.log
Logs: schtasks /Query /TN "OpenClaw Gateway" /V /FO LIST
Restart attempts: C:\Users\jabuc.openclaw\logs\gateway-restart.log
Other gateway-like services detected (best effort):
- \OpenClaw Gateway (system, task: \OpenClaw Gateway, run: C:\Users\jabuc.openclaw\gateway.cmd)
Cleanup hint: schtasks /Delete /TN "OpenClaw Gateway" /F
Recommendation: run a single gateway per machine for most setups. One gateway supports multiple agents (see docs: /gateway#multiple-gateways-same-host).
If you need multiple gateways (e.g., a rescue bot on the same host), isolate ports + config/state (see docs: /gateway#multiple-gateways-same-host).
Troubles: run openclaw status
Troubleshooting: https://docs.openclaw.ai/troubleshooting
PS C:\Windows\system32>
This is useful: it’s not crashing after startup — Windows is never actually launching it. state Queued + port free means Task Scheduler accepted the run request but kept the task queued.
Two things I’d try next:
- Open a normal non-admin PowerShell window, not
C:\Windows\system32/ admin, then run:
openclaw gateway uninstall
openclaw gateway install
openclaw gateway restart
openclaw gateway status --deep
That won’t reset your OpenClaw data; it only recreates the Scheduled Task / ~\.openclaw\gateway.cmd launcher.
- If it still queues, bypass Task Scheduler once to see the real gateway error:
openclaw gateway run --force
Leave that window open. If the dashboard/probe comes up, then OpenClaw itself is fine and the problem is purely Windows Task Scheduler. If it prints an error, paste that error.
Also: the “Other gateway-like services detected” line looks like it may just be the same \OpenClaw Gateway task being detected with a leading slash, not necessarily a second real gateway. I wouldn’t chase that until after the reinstall/foreground test.
PS C:\Users\jabuc> openclaw gateway install
🦞 OpenClaw 2026.5.7 (eeef486) — Half butler, half debugger, full crustacean.
Gateway service already registered.
Reinstall with: openclaw gateway install --force
PS C:\Users\jabuc>