What would cause strange characters to appear in terminal ? É
I have vagrant vm running inside my mac.
I accidentally redirected the output of rpm2cpio to standard out. I quickly canceled it, but now my keyboard has remapped some of the keys.
ÄvagrantÉus-devops-build02 üÅ$ ÄÅÄö\
The following keys have been remapped
[ = ä
] = Å
\ = ö
ctrl + c = ÜC
The shell name shows
ÄvagrantÉus-devops-build02
I've logged out and then logged back in with the same results
Anyone know why these keys would have been remapped?
Solution 1:
That's not a modified keyboard mapping. Your shell prompt isn't typed in. That's a modified output character set, affecting both your shell prompt and the echoes of what you type in.
Your terminal emulator is capable of multiple character sets, and it's often the case when one accidentally dumps a binary to the terminal that somewhere in the binary is the character sequence that switches the terminal between output character sets.
The simple way to reset your terminal emulator in such situations is the reset
command, sometimes followed by stty sane
if there are lingering CR-LF problems in the line discipline. (And sometimes having to use Control+J instead of Return to enter the commands in the latter case.)
If it were a GUI terminal emulator, there'd be a "reset" option on its menu that does the same thing.
There's really no need to destroy an entire virtual machine in order to reset a terminal's output character set.
Further reading
- Andries Brouwer (2002-10-12). "6. The console character sets" The Linux keyboard and console HOW-TO. The Linux Documentation Project.