Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need to change layout of keyboard while working in console in Linux. I need to setup English layout as default for console. How to do it?

share|improve this question
    
What distro are you using? – emzero Mar 24 '12 at 23:31
    
Ubuntu, logged under root – RCola Mar 24 '12 at 23:37
1  
"loadkeys us" worked! How to make it default layout? – RCola Mar 24 '12 at 23:42
up vote 14 down vote accepted

To change the system-wide keyboard layout, run

sudo dpkg-reconfigure keyboard-configuration

or edit the XKBLAYOUT line in /etc/default/keyboard.

share|improve this answer

To change your keyboard layout fast, just install setxkbmap with:

sudo apt-get install x11-xkb-utils

After this you can always change the keyboard layout with:

setxkbmap us

To do this automatically every time, extend your .bashrc with:

echo "setxkbmap us" >> ~/.bashrc

Now, open a new console and the US keyboard layout is activated. Don't worry if the small keyboard layout icon in the Ubuntu panel does not change.

share|improve this answer

another way, but I understand it wont last for next boot:

sudo loadkeys /usr/share/keymaps/i386/qwerty/us.kmap.gz

check /usr/share/keymaps/i386/ for you keyboard layout and keymaps to what suits you better

share|improve this answer
    
Put it in /etc/profile.d/bashrc – Bhaskar Karambelkar Mar 25 '12 at 1:01

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.