If I display a terminal over an ssh tunnel (X11 forwarding) to Xming on a Windows 10 PC, the keyboard setting is wrong. On the Ubuntu machine itself, the keyboard setting is correct. What puzzles me: if I check the keyboard settings with the usual commands on that terminal displayed on Xming, it all looks ok too. Just the keys do not match the configured language.
Instead, the actual keymap seems to be "us" !!
Ubuntu 18.04.2 LTS, swiss german locale.
I am stumped. Can you give me a pointer?
ssh to Ubuntu: /etc/default/keyboard
XKBMODEL="logicd"
XKBLAYOUT="ch"
XKBVARIANT=""
XKBOPTIONS=""
BACKSPACE="guess"
localectl status
System Locale: LANG=de_CH.UTF-8
VC Keymap: ch
X11 Layout: ch
X11 Model: logicd
Then open terminator or xterm, the window is displayed on by Xming on the PC:
localectl status
System Locale: LANG=de_CH.UTF-8
VC Keymap: ch
X11 Layout: ch
X11 Model: logicd
setxkbmap -query
rules: xorg
model: pc105
layout: de_CH
setxkbmap -query | awk -F"(,|[ ]+)" '/layout:/ { print $2 }'
de_CH
gsettings get org.gnome.desktop.input-sources sources | grep -Po "'[[:alpha:]]+')" | sed -ne "s/['|)]//g;$(($current_layout+1))p"
ch
setxkbmap -print -verbose 10
Setting verbose level to 10
locale is C
Trying to load rules file ./rules/xorg...
Trying to load rules file /usr/share/X11/xkb/rules/xorg...
Success.
Applied rules from xorg:
rules: xorg
model: pc105
layout: de_CH
Trying to build keymap using the following components:
keycodes: xfree86+aliases(qwerty)
types: complete
compat: complete
symbols: pc+de_CH+inet(pc105)
geometry: pc(pc105)
xkb_keymap {
xkb_keycodes { include "xfree86+aliases(qwerty)" };
xkb_types { include "complete" };
xkb_compat { include "complete" };
xkb_symbols { include "pc+de_CH+inet(pc105)" };
xkb_geometry { include "pc(pc105)" };
.. and so on.. All commands insists that I have the ch mapping active.
But I definitively have the us mapping active.
Examples:
- on keyboard produces in xterm /
? on keyboard produces in xterm _
! on keyboard produces in xterm }
& on keyboard produces in xterm ^
Anyone has a clue how I can set up the correct keymap? As I mentioned before, the keymap is correct in any other situation.
Thanks Dan