Dear Debian folks,
in my opinion it should be possible for the user to easily change the
keyboard layout for the boot loader. Especially in 2012. So I put the
severity to serious as I think this should be solved for Wheezy.
As far as my tests and my online search goes, that is currently not
possible in Debian [1]. Fedora seems to offer that possibility and GRUB
too [2].
Probably #686815 [3] needs to be resolved for that first.
Additionally an option should be added to `/etc/default/grub` like
discussed on the Talk page in the ArchWiki [2].
GRUB_TERMINAL_INPUT=at_keyboard
KEYBOARD_LAYOUT=de
Lastly `/etc/grub.d/05_keyboard_layout` needs to be created with
insmod keylayouts
keymap /boot/grub/$KEYBOARD_LAYOUT.gkb
where the last line should ideally be also read from `/etc/default/grub`
and `update-grub` should take care of generating the keymap file using
`grub-kbdcomp`.
If that is not possible a big section should be added to the release
notes.
Currently Debian Wheezy does not support to easily change the
keyboard layout for its default boot loader GRUB 2 (grub-pc).
Please read the page <should be created> in the Debian Wiki on
how to do that manually.
Please note that when Debian GNU/Linux starts, it uses an
initial RAM file system which can set the used keyboard layout
for entering for example the LUKS password for encrypted
devices. You need to install the package `console-setup` to
configure that.
Thanks,
Paul
[1] http://debianforum.de/forum/viewtopic.php?f=12&t=116672
[2] https://wiki.archlinux.org/index.php/Talk:GRUB2#Custom_keyboard_layout
[3] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=686815
severity 686817 important thanks While I would like to get this fixed, I don't consider it RC. Please note that the "unsuitable for release" case for "serious" is "in the package maintainer's or release manager's opinion" - feel free to appeal to the release team. In particular, this is not a regression from any previous version of Debian, and there are so many other things to do in GRUB that actually stop people booting, which is clearly worse than having the wrong keyboard layout. We're far enough along that advanced users can at least set this up themselves, which is better than the previous situation. Could you support your comment about Fedora with a reference to some code or documentation? While Fedora installs the grub-kbdcomp tool (as grub2-kbdcomp), I don't see anything in their spec file that actually makes use of it; so unless there's some configuration in a separate package, they appear to be no further along than Debian. I don't see why; GRUB could reasonably offer keyboard layout configuration only if console-setup is installed.
Hi This has become more important with disk encryption. - Put grub on an encrypted disk - Add GRUB_ENABLE_CRYPTODISK=y to /etc/default/grub (update-grub says "1", but that's a bug, it must be "y". Another bug: the above parameter is not even documented). - wonder why your encrypted disk cannot be found, because grub mangled your password with the wrong keyboard-layout. Since it's not that a huge task, please fix it.
In principle, GRUB2 allows you to change the keyboard layout through its
'at_keyboard' input terminal.
You can use the 'grub-mklayout' utility to create a GRUB keyboard
layout, e.g., for dvorak:
ckbcomp dvorak | grub-mklayout -o dvorak.gkb
Create a 'layouts' subdirectory under your 'grub' directory, and copy
the GRUB keyboard layout to it, e.g.:
mkdir /boot/grub/layouts
cp dvorak.gkb /boot/grub/layouts
The 'keymap' command under GRUB (e.g., in your 'grub.cfg') will then
load the keymap:
keymap dvorak
To actually use the keymap, you will have to switch the the
'at_keyboard' input terminal:
terminal_input at_keyboard
Trouble is, under a PC BIOS system, the 'at_keyboard' input terminal is
broken.
It is unclear to me how (or even, whether) it can be fixed.
Since I, too, got frustrated that I couldn't change the keyboard layout,
I decided to try and create my own 'ext_kbd' input terminal, for
personal use.
The 'ext_kbd' input terminal implements something akin to the 'setkey'
command that was available under what is now known as GRUB Legacy.
It won't go into upstream, since it deviates from the infrastructure
that GRUB already provides for changing the keyboard layout.
In any case, I'll attach a patch that will add support for my 'ext_kbd'
module to GRUB, in case anyone is interested enough to try it.
If you decide to apply the patch, then you will subsequently have to run
'./autogen.sh' before you run './configure'. Otherwise, the build
process will not pick up the definition of the 'ext_kbd' module that the
patch adds to the 'grub-core/Makefile.core.def' file.
I'm afraid that this is the best that I can do for now.
This bug is assigned to grub-pc (legacy BIOS). grub-efi (and probably others) are however equally affected. Should this bug therefore be re-assigned to grub? I haven't found any bug report for grub-efi. Is this bug report the reason why non-US keyboard layouts result in broken password prompts for installations using calamares which sets up encrypted /boot? Discussed upstream at calamares: https://github.com/calamares/calamares/issues/1203