Reply to topic

language Keybord at boot

dossmannb
Registered Member
Posts
4
Karma
0

language Keybord at boot

Mon Nov 02, 2020 9:48 am
Hello,
I try to install kdeNeon with encrypt disk option.
But, when i install, my keyboard is in french(azerty) , and at boot, the keyboard is un USA mode (qwerty)
When i launch setup on a live USB, kde detect my french keyboard. But, when i finished the installation, i'am not able to unlock the disk because my password is wrong ( not the same with my french keyboard to US keyboard).
Have you any advice ?
Thanks.
Bruno
koffeinfriedhof
Registered Member
Posts
290
Karma
2
OS

Re: language Keybord at boot

Mon Nov 02, 2020 10:17 am
Hello!

Without having checked it myself, I can only provide you a possibility! So be careful and have a bootable stick if unlocking keeps failing!

One way to change a language systemwide is to use
Code: Select all
sudo localectl set-x11-keymap fr pc105 fr-legacy
That would make french the systemwide language. As you need the layout already at the boot prompt you have to change the terminal keymap with
Code: Select all
sudo dpkg-reconfigure console-setup
to allow utf8 at boot.

After changing, make sure that the «KEYMAP=Y» - option is set up in /etc/initramfs-tools/initramfs.conf and running `update-initramfs -u` if changed.
dossmannb
Registered Member
Posts
4
Karma
0

Re: language Keybord at boot

Mon Nov 02, 2020 6:58 pm
Hello,
thanks for your advice.
but this didn'k work for me.

In file /etc/initramfs-tools/initramfs.conf, i added 'KEYMAP=Y' at the end
And UTF8 was enabled by default.

I have this return for update-initramfs -u :
update-initramfs: Generating /boot/initrd.img-5.4.0-52-generic
/usr/sbin/mkinitramfs: 109: .: Can't open /etc/initramfs-tools/conf.d/calamares-safe-initramfs.conf
update-initramfs: failed for /boot/initrd.img-5.4.0-52-generic with 127.



I use Luks, and at boot, when i enter my password, the keyboard is still in US.
Do you have any other advice. (my grub is already in US)
I have check on google, but i didn't find any advice to solve problem.
If you have a other idee, il happy to hear it :)
Thanks, Bruno
koffeinfriedhof
Registered Member
Posts
290
Karma
2
OS

Re: language Keybord at boot

Mon Nov 02, 2020 9:23 pm
You have to have administration permission to update the initramfs.
dossmannb
Registered Member
Posts
4
Karma
0

Re: language Keybord at boot

Tue Nov 03, 2020 10:15 am
Hello, i have try in root.
No effect,

Code: Select all
[email protected]:/home/bruno# update-initramfs -u
update-initramfs: Generating /boot/initrd.img-5.4.0-52-generic
I: The initramfs will attempt to resume from /dev/dm-1
I: (/dev/mapper/luks-43c7859e-b9e8-4103-8a4b-e42bebc1454f)
I: Set the RESUME variable to override this.


And updated initramfs wit option 'KEYMAP=Y'





Il have try this
[email protected]:/home/bruno# gsettings get org.gnome.desktop.input-sources xkb-options
@as []
[email protected]:/home/bruno# gsettings reset org.gnome.desktop.input-sources xkb-options

And this have no effect.



Do you have anoter idee ?
At boot, my keyboard is still in US

Thanks for your help.
Bruno
koffeinfriedhof
Registered Member
Posts
290
Karma
2
OS

Re: language Keybord at boot

Tue Nov 03, 2020 11:28 am
Please show the following outputs in a codeblock:
Code: Select all
localectl
cat /etc/default/keyboard
grep KEYMAP /etc/initramfs-tools/initramfs.conf


And you can perhaps force GRUB2 to load a custom keymap, but I am not familiar with this bootloader as I am using systemd-boot on all machines.
dossmannb
Registered Member
Posts
4
Karma
0

Re: language Keybord at boot

Wed Nov 04, 2020 12:03 pm
Hello, there is my files :
Code: Select all
[email protected]:/home/bruno# localectl
   System Locale: LANG=fr_FR.UTF-8
       VC Keymap: fr
      X11 Layout: fr
       X11 Model: pc105
[email protected]:/home/bruno# cat /etc/default/keyboard
XKBMODEL="pc105"
XKBLAYOUT="fr"
XKBVARIANT=""
BACKSPACE="guess"
XKBOPTIONS=""
[email protected]:/home/bruno#
[email protected]:/home/bruno# grep KEYMAP /etc/initramfs-tools/initramfs.conf
KEYMAP=Y
[email protected]:/home/bruno#


I'm gona looking for grub keybord ( but it isnt' initramf ? )

Thanks,
Best regard. Bruno
koffeinfriedhof
Registered Member
Posts
290
Karma
2
OS

Re: language Keybord at boot

Wed Nov 04, 2020 12:37 pm
The output looks good.

I do not really know how grub works. For me, it was always a bit to complicated ;) To get an idea you can read the archlinux-wiki about how a boot process works: ArchWiki: boot process.
To keep it short: the initram-filesystem does contain the stuff you need before loading the system itself and will be loaded next to the kernel right after the boot loader.
To unlock a LUKS-device with LVM it must have drivers for both (cryptsetup and lvm2). To use another layout than the default US-Layout you must provide it too, thats why I advised to export the keymap too and regenerate the initramfs.
The main tool to change the console keyboard layout for debian based distros is dpkg-reconfigure console-setup , see DebianWiki: Keyboard.

I found some (german) forum entries how to change the keyboard layout, but there are a lot of warnings that it a very unstable thing and does not work as expected.

The easiest would be to enter a password which is the same on us and french layout. Or you set the luks-passphrase while typing on us layout and ignoring the real chars written, e.g.
Code: Select all
setxkbmap us
sudo cryptsetup luksAddKey your_luks_device
setxkmap fr…

Then you will write your password how it would be in us layout.

 
Reply to topic

Bookmarks



Who is online

Registered users: Baidu [Spider], Bing [Bot], claydoh, Google [Bot], ipwizard, robertrathbone, Sogou [Bot], Stephen Leibowitz, TheraHedwig, Yahoo [Bot]