Score:1

debian installer - automated keyboard layout selection for hostname configuration page

us flag

I'm trying to automatically install debian using a preseed file. However, there is one piece of information, that should be entered manually, which is the hostname.

To ensure that the hostname can be entered without problems, the correct keyboard layout should be loaded by the installer.

Setting the keymap in the preseed config with d-i keyboard-configuration/xkb-keymap select de generally works fine. Unfortunately, the preseed file is only loaded after the hostname question. Therefore configuring this in the preseed config has no effect. The keyboard layout somehow needs be set via a kernel cmdline paramter.

Unfortunately, simply using keyboard-configuration/xkb-keymap=de did not work.

Which kernel cmdline paramater can I use to automatically set the keyboard layout, so that it is set correctly during the hostname question (before loading the preseed file)?

dexter avatar
ru flag
You are providing the preseed file through the network, I assume. It looks like debian-installer is loading kernel boot parameters at the same step as loading the preseed file. So no matter what kernel boot parameter you provide, it won't reflect during the hostname prompt, because networking is done before loading pressed parameters. If possible, try to provide the pressed file in another way, eg as a file. In that case, the keyboard configuration will be loaded before the hostname prompt.
us flag
@dexter Correct, the preseed file is loaded via network. Could you provide a source for the assumption that loading kernel parameters is postponed until the preseed file has been fetched?
dexter avatar
ru flag
_It looks like debian-installer is loading kernel boot parameters at the same step as loading the preseed file_ is **wrong**, now I see. It actually executes the parameters in order, so providing parameters during boot will not have an effect on their order of execution. When fetching a preseed file from the network, the hostname needs to be set before the network is configured, and the next step is setting the keyboard layout,... That is my conclusion from the installation log file, which is not necessarily correct.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.