#Why does the gateway do this?

1 messages · Page 1 of 1 (latest)

left bronze
#

openclaw : File C:\Users\BK\AppData\Roaming\npm\openclaw.ps1 cannot be loaded because running scripts is disabled on
this system. For more information, see about_Execution_Policies at https:/go.microsoft.com/fwlink/?LinkID=135170.
At line:1 char:1

  • openclaw
  •   + CategoryInfo          : SecurityError: (:) [], PSSecurityException
      + FullyQualifiedErrorId : UnauthorizedAccess
    
    

What does this mean and how do I fix it?

Windows 11
OpenClaw 2026.
WSL 2
Ollama4.24

Also, is there a correct order to start these programs?

solar gardenBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> ✅ Mark Solution

noble currentBOT
#

That error is PowerShell blocking npm’s openclaw.ps1 shim, not an OpenClaw crash.

Quick fixes:

openclaw.cmd --version

If that works, you can use openclaw.cmd from PowerShell, or run openclaw from Command Prompt.

Permanent PowerShell fix:

Set-ExecutionPolicy -Scope CurrentUser -ExecutionPolicy RemoteSigned

Then close/reopen PowerShell and try:

#
openclaw --version

If you’re using WSL2, I’d recommend keeping OpenClaw inside Ubuntu/WSL rather than mixing Windows PowerShell + WSL installs. Open the Ubuntu terminal and run OpenClaw there.

Suggested start order:

  1. Start WSL / Ubuntu.
  2. Start Ollama first, if OpenClaw uses local Ollama:
    ollama serve
    
    or make sure the Ollama Windows app/service is already running.
  3. Start/check OpenClaw:
#
   openclaw gateway status
   openclaw gateway start
  1. Verify:
    openclaw status --all
    openclaw models list --provider ollama
    

Important Ollama note: use the native Ollama URL, not /v1:

http://127.0.0.1:11434

not:

left bronze
#

OpenClaw 2026.4.24 (cbcfd6)

noble currentBOT
#

Thanks — that version is fine for this specific error.

openclaw.ps1 cannot be loaded happens before OpenClaw actually runs. PowerShell is blocking npm’s script shim.

If you want to keep using PowerShell, run:

Set-ExecutionPolicy -Scope CurrentUser -ExecutionPolicy RemoteSigned

Then reopen PowerShell and try:

openclaw --version

Or skip the policy change and use:

#
openclaw.cmd

Since you’re on WSL2, the cleaner path is: run OpenClaw from the Ubuntu/WSL terminal, not Windows PowerShell, so you don’t accidentally mix a Windows install and a WSL install.

Startup order:

1. Start WSL / Ubuntu
2. Start Ollama / confirm Ollama is running
3. Start OpenClaw gateway
4. Check status

In WSL: