Connecting to Linux with terminal emulators
Connecting to Linux over the network from a Windows host using a terminal
emulator often results in annoying keyboard and/screen issues. You'll have some
tips & tricks about how to solve some of them.
If all else fails, or you'd really rather use Windows-based editors, an alternative
to terminal emulators is accessing files either through SSH (WinSCP)
or SMB/CIFS (Samba).
- European diacritic characters
- Black & white output with Midnight Commander
- wrong $TERM
- wrong data in termcap, terminfo
- terminal emulator not 100% compatible with remote server
- OS sending UTF8 while emulator expects other character encoding
- server-side application
stty erase '^H' (add to .profile)
^H represent BS whereas ^? represents DEL
(Ubuntu) # locale
Font used in terminal emulator
Only supports xterm
Putty Connection Manager
By default, hotkeys such as CTRL-U to duplicate the current window, are disabled:
Tools > Options > Hotkeys
Drawback: Keys used by PCM may conflict with applications (eg. F3 is also
used by Midnight Commander).
Options > Session Options > Terminal > Appearance: Character Encoding
= Default -> UTF-8
Once a connection is open in one tab, File > Clone to open more without
being prompted with login/password.
Tools > Keymap Editor: If you want to map eg. CTRL+Home to CTRL+k,u (to
jump to the first line of the document in Joe), map "Ctrl-Extended-VK_HOME"
to "013\u" (\013 is octal for CTRL+k). See ASCII
Why am I
seeing strange characters on the screen when I log onto RedHat, particularly
when I look at man pages?
How do get
my color scheme settings to work?
"KiTTY is a fork from version
0.60 of PuTTY [...]. KiTTY has all the features from the original software,
and adds many others".
To tell Kitty to send ^ku and ^kv when you type CTRL+Home and CTRL-End, edit
To use MidnightCommander's F7 to Search, add this to Kitty's ini file:
In addition, you should add the following lines to kitti.ini, so that Kitty
can update the Putty section in the Registry:
"Meta key" = Either ALT or ESC. For instance, in Nano, on a French
- Go to the first line of the file: "M-\ or M-|" means ESC,
followed by AltGr+\ or AltGr+|
- Go to the last line of the file: "M-/ or M-?" means
ESC, followed by SHIFT+/ or SHIFT+?
Alternatively, you can customize your terminal emulator to send those keys
when typing CTRL-Home/End instead.
If you get the familar ABCD's when using the arrow keys, try this:
- readlink -f $(which vi), to check whether Ubuntu is actually pointing
to vim.tiny, which "uses the /etc/vim/vimrc.tiny file instead of the
/etc/vim/vimrc file. The vimrc file sets nocompatible mode, while vimrc.tiny
- apt-get install vim
If funny characters and F10 doesn't work, try ESC 0 (zero) to close.
If connected with vt100, disconnect, use xterm, and try again.
Also check what character set the Linux server uses (eg. UTF-8), and make
sure the terminal emulator expects the same
by David S. Lawyer
- Linux Backspace/Delete
mini-HOWTO by Sebastiano Vigna ("there is a bottleneck between
the keyboard and console applications, that is, the fact that they can only
communicate by ASCII sequences. So special keys must be first translated
from keysyms to sequences, and then from sequences to key capabilities.
Since different consoles have different ideas about what this translation
can look like, we need a terminal database.
The system would work flawlessly,
except for a small problem: it is not always set up correctly, and not everyone
uses it. Applications must have a way to know which database entry to use:
this is accomplished by suitably setting the TERM environment variable.
some cases, there is a mismatch between the terminal emulator and the content
of the database entry suggested by TERM. Moreover, many applications do
not use the terminal database (or at least not all of it)"
Linux keyboard and console HOWTO by Andries Brouwer
Thoughts about Terminal Emulation
- Terminal emulator
& terminfo by Linda Mui, Tim O'Reilly, John Strang (Termcap
= BSD, terminfo = System
- (Putty FAQ) A.7.15
One or more function keys don't do what I expected in a server-side application
Guide to NCurses by Dan Gookin
- Scan Codes Demystified
scancodes by Andries Brouwer