Change Keyboard Layout When Using Ubuntu

If you want to change the keyboard layout when using ubuntu, you can use this command:

sudo dpkg-reconfigure keyboard-configuration

Now, you can select the desired layout and confirm your selection.

Im daraufhin erscheinenden Popup einfach das gewünschte Layout auswählen und bestätigen.

Alternative Way – Edit Configuration File

Another option is to change the configuration file directly. To do so, edit /etc/default/keyboard:

nano /etc/default/keyboard

And set XKBLAYOUT to ‘de’:

XKBLAYOUT= 'de'