Severe Input Lag / Freezing in WSL2 #8182

Closed
opened 2026-02-16 18:09:22 -05:00 by yindo · 3 comments
Owner

Originally created by @gabrielsoda on GitHub (Jan 31, 2026).

Originally assigned to: @rekram1-node on GitHub.

Description

OpenCode becomes completely unresponsive when running in WSL2. The freezing starts immediately on launch and follows a consistent pattern: 5-10 seconds frozen, then 5-10 seconds responsive, repeating indefinitely. This affects all operations including typing (characters freeze then appear all at once), LLM streaming output, scrolling, and even idle state.
Both Claude Code and Gemini CLI work flawlessly in the exact same WSL2 environment,
Switching terminals from Windows Terminal to WezTerm made no difference.
The issue persists regardless of shell choice or project complexity.

Plugins

opencode-anthropic-auth

OpenCode version

1.1.48

Steps to reproduce

No response

Screenshot and/or share link

Image

Operating System

Ubuntu 24.04.3 LTS (WSL2)

Terminal

Windows Terminal / WezTerm

Originally created by @gabrielsoda on GitHub (Jan 31, 2026). Originally assigned to: @rekram1-node on GitHub. ### Description OpenCode becomes completely unresponsive when running in WSL2. The freezing starts immediately on launch and follows a consistent pattern: 5-10 seconds frozen, then 5-10 seconds responsive, repeating indefinitely. This affects all operations including typing (characters freeze then appear all at once), LLM streaming output, scrolling, and even idle state. Both Claude Code and Gemini CLI work flawlessly in the exact same WSL2 environment, Switching terminals from Windows Terminal to WezTerm made no difference. The issue persists regardless of shell choice or project complexity. ### Plugins opencode-anthropic-auth ### OpenCode version 1.1.48 ### Steps to reproduce _No response_ ### Screenshot and/or share link ![Image](https://github.com/user-attachments/assets/b7e6bb94-1dc7-454f-af76-b14368c775ee) ### Operating System Ubuntu 24.04.3 LTS (WSL2) ### Terminal Windows Terminal / WezTerm
yindo added the windowsbugperf labels 2026-02-16 18:09:22 -05:00
yindo closed this issue 2026-02-16 18:09:22 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Jan 31, 2026):

This issue might be a duplicate of existing issues. Please check:

  • #5361: TUI freezes for ~10 seconds periodically on WSL2 (regression in v1.0.129) - describes the exact same periodic 5-10 second freeze pattern
  • #8484: Screen lag/freezing when typing text (WSL2, TMUX, Alacritty) - similar typing lag/freeze on WSL2
  • #7893: Severe scroll lag in VSCode/Cursor integrated terminal on WSL2 after large output - WSL2 freezing issues in integrated terminals

All three issues describe periodic freezing/lag on WSL2 with similar symptoms (buffered input appearing after freeze, consistent 5-10 second intervals). These are known WSL2-specific issues.

Feel free to ignore if your specific case differs from these.

@github-actions[bot] commented on GitHub (Jan 31, 2026): This issue might be a duplicate of existing issues. Please check: - #5361: TUI freezes for ~10 seconds periodically on WSL2 (regression in v1.0.129) - describes the exact same periodic 5-10 second freeze pattern - #8484: Screen lag/freezing when typing text (WSL2, TMUX, Alacritty) - similar typing lag/freeze on WSL2 - #7893: Severe scroll lag in VSCode/Cursor integrated terminal on WSL2 after large output - WSL2 freezing issues in integrated terminals All three issues describe periodic freezing/lag on WSL2 with similar symptoms (buffered input appearing after freeze, consistent 5-10 second intervals). These are known WSL2-specific issues. Feel free to ignore if your specific case differs from these.
Author
Owner

@Nsomnia commented on GitHub (Jan 31, 2026):

There's apparently some memory not being released issue I've read about and while it might be the potato I'm running on right now running, whether via a Ralph harness or in TUI it will often hang especially with tool calls like doing a bash run cmake compile script.

@Nsomnia commented on GitHub (Jan 31, 2026): There's apparently some memory not being released issue I've read about and while it might be the potato I'm running on right now running, whether via a Ralph harness or in TUI it will often hang especially with tool calls like doing a bash run cmake compile script.
Author
Owner

@gabrielsoda commented on GitHub (Feb 1, 2026):

Resolved! Found the solution in #8484 thanks to @pschiel's comment:
https://github.com/anomalyco/opencode/issues/8484#issuecomment-3770986748
Cause: systemd-timesyncd in WSL2 causes time sync conflicts with Windows/Hyper-V, resulting in corrupted timestamps that freeze JavaScript timeouts.
Solution:

sudo systemctl disable systemd-timesyncd && sudo systemctl stop systemd-timesyncd

This completely fixed the input lag and freezing for me. Closing as resolved.

@gabrielsoda commented on GitHub (Feb 1, 2026): Resolved! Found the solution in #8484 thanks to @pschiel's comment: https://github.com/anomalyco/opencode/issues/8484#issuecomment-3770986748 **Cause:** `systemd-timesyncd` in WSL2 causes time sync conflicts with Windows/Hyper-V, resulting in corrupted timestamps that freeze JavaScript timeouts. **Solution:** ```bash sudo systemctl disable systemd-timesyncd && sudo systemctl stop systemd-timesyncd ``` This completely fixed the input lag and freezing for me. Closing as resolved.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#8182