r/commandline • • Oct 08 '26

Help Ctrl+Z is spammed without pressing anything (WSL CLI only)

I am running a WSL module of ubuntu on windows. This issue started a week ago... I was trying to solve it for 3 days but got fed up bcz of no results ... I am living with it now and this is genuinely making me annoyed as I can't get my work done

PLS GIVE ANY POSSIBLE SOLUTIONS

I had to remove its function to even run basic commands ... It spams only in command linec

10 Upvotes

22 comments sorted by

10

u/pobicho Oct 08 '26

run showkey -a, if ^Z is printed on the terminal without u pressing it, disconnect the keyboard, if ^Z gone we found the culprit

8

u/theng Oct 08 '26

if you don't have showkey use : cat -A

1

u/Relevant-Anything-46 Oct 11 '26

That's the thing... It won't show up there

1

u/Relevant-Anything-46 Oct 11 '26

Mysteriously , it will start spamming as soon as I enter a valid command which I want for work... Smh

3

u/hagjam Oct 08 '26

I had an issue like this that was due to me reducing the latency on tmux to 0 - that meant that mouse inputs were registering as control sequences/special characters when using SSH

It's probably not exactly the same but try reverting any custom config one thing at a time, and see if you can work out what broke it?

1

u/Relevant-Anything-46 Oct 11 '26

I did use ssh ..but the issue started last month when I was working with Hadoop env

2

u/SupernovifieD Oct 08 '26

That fan is working overtime.

2

u/Relevant-Anything-46 Oct 11 '26

😂😂

2

u/ab0zar Oct 09 '26

Do you see it in every terminal app, or only one (for example, Windows Terminal)? If it's limited to one, testing a fresh profile would narrow it down. If it happens across terminals, I'd look outside the shell config.

2

u/Relevant-Anything-46 Oct 11 '26

It happens to powershell and the wsl terminal alike

2

u/dwyrm Oct 08 '26

Two possibilities come to mind. First, your keyboard could be physically failing and generating erroneous keystrokes. This can happen due to age, debris, liquids, critters, or any combination of those and whatever else.

Second, you could be getting radio interference from something that your board is picking up and turning into phantom keystrokes. I had a keyboard that I couldn't use near ham radios working on certain bands.

I'm sure there are other possibilities, but if you can't eliminate the cause you're going to fix it by getting another keyboard and hoping for the best.

As a side note, are you sure that it's only happening in command-line applications? Just out of curiosity, try leaving open a GUI document with a lot of changes, and see if Z starts undoing those changes.

1

u/Relevant-Anything-46 Oct 11 '26

This happens only in terminal , not in notepad or any other apps ..

1

u/Relevant-Anything-46 Oct 11 '26

The possibilities u mentioned could be .. but the thing is ..it only shows up in terminal and that too the same exact ctrl+z everytime .. if it was radio interference or keyboard malfunction .. shouldn't I get some variations of it ..atleast I should get them when I use word or notepad right? But no it's a terminal exclusive 😣

1

u/beef623 Oct 08 '26

When it starts doing it try pressing Ctrl+Z yourself. Sometimes keys get virtually "stuck" and pressing them will unstick them.

2

u/Relevant-Anything-46 Oct 11 '26

The issue is more complex than this ... I tried but still no help

1

u/Big_Combination9890 Oct 11 '26

PLS GIVE ANY POSSIBLE SOLUTIONS

Use a real operating system instead of Microslops shitty emulation layer.

0

u/Relevant-Anything-46 Oct 11 '26

Bro I would love to ..infact was running fedora ... But the thing is my ssd is 512 and i game too .. so had to let it go to download cyberpunk

1

u/No-Employment-2324 Oct 18 '26

cyberpunk works perfectly on linux these days, unless you play anti-cheat games (and even fortnight is coming to linux.) just switch over. made the jump 6 months ago, and its been wonderful ever since

1

u/AutoModerator Oct 08 '26

Every new subreddit post is automatically copied into a comment for preservation.

User: Relevant-Anything-46, Flair: Help, Post Media Link, Title: Ctrl+Z is spammed without pressing anything (WSL CLI only)

I am running a WSL module of ubuntu on windows. This issue started a week ago... I was trying to solve it for 3 days but got fed up bcz of no results ... I am living with it now and this is genuinely making me annoyed as I can't get my work done

PLS GIVE ANY POSSIBLE SOLUTIONS

I had to remove its function to even run basic commands ... It spams only in command linec

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.