8

I want to install debian automatically. I've copied the example preseed file into the initrd, and verified that it contains

d-i keymap select us

In the installation system, /var/log/syslog contains a line

successfully loaded preseed file from file:///preseed.cfg

but I still see the Configure the Keyboard dialog. How can I make the installation pick a keyboard layout without user interaction?

4 Answers 4

8

The example preseed file is wrong. You need to set the following option:

d-i keyboard-configuration/xkb-keymap select us
0
2

This was my configuration for Ubuntu xenial; what a pain. I found this here, so thanks to this GitHub user

# Keyboard selection.
d-i console-setup/ask_detect boolean false
d-i keyboard-configuration/xkb-keymap select us
d-i keyboard-configuration/layoutcode string us
d-i keyboard-configuration/variantcode string
1

Setting keyboard-configuration/xkb-keymap seems not enough for Debian 11.6.0. Using the netinstaller, I still got asked for my keyboard layout, after downloading the packages. It could be fixed by also setting keyboard-configuration/variant as workaround:

d-i console-setup/ask_detect boolean false
d-i keyboard-configuration/variant select Deutschland
d-i keyboard-configuration/xkb-keymap select de

What doesn't work

I also tried some combinations (each paragraph is one try) with different variants by setting attributes like the layoutcode or variantcode, but none of them worked:

d-i keyboard-configuration/xkb-keymap select de

d-i keyboard-configuration/xkb-keymap select German

d-i keyboard-configuration/modelcode string pc105
d-i keyboard-configuration/layoutcode string de

d-i keyboard-configuration/xkb-keymap select de
d-i keyboard-configuration/layoutcode string de
d-i keyboard-configuration/variantcode string

Additionally, the following were set for all of those combinations:

d-i console-setup/ask_detect boolean false
d-i debian-installer/locale string de_DE

It seems that console-setup/ask_detect doesn't had any effect. This is just for reference purpose, in case anyone would like to try this out. At least for Debian 11.6.0 netinstall, they didn't work.

0

I had the same issue as you had. I had everything but the keyboard preseeded so that it would not prompt for anything during the installation. Your problem is that you actually need to add in the keyboard configuration into the append line in your menus file (may be named main depending on what you are doing). Also your keymap setting is correct. In debian keymap is an alias for keyboard-configuration/xkb-keymap.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .