When I try to set the locale using raspi-config I it doesn't seem to work and messes up my keyboard mapping. Here's what a session looks like:
pi@raspberrypi ~ $ more locale.txt
pi@raspberrypi ~ $ sudo raspi-config
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = "en_GB.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
/usr/bin/locale: Cannot set LC_CTYPE to default locale: No such file or director
y
/usr/bin/locale: Cannot set LC_MESSAGES to default locale: No such file or direc
tory
/usr/bin/locale: Cannot set LC_ALL to default locale: No such file or directory
Generating locales (this might take a while)...
en_US.UTF-8... done
Generation complete.
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = "en_GB.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
/usr/bin/locale: Cannot set LC_CTYPE to default locale: No such file or director
y
/usr/bin/locale: Cannot set LC_MESSAGES to default locale: No such file or direc
tory
/usr/bin/locale: Cannot set LC_ALL to default locale: No such file or directory
Current default time zone: 'America/Denver'
Local time is now: Fri Oct 5 09:25:57 MDT 2012.
Universal Time is now: Fri Oct 5 15:25:57 UTC 2012.
raspi-config doesn't set locale
A computer may beat me at chess, but I always win at kick boxing.
Re: raspi-config doesn't set locale
I've connected using putty from a Win7 computer and the keymapping looks fine. Had no problem connecting using SSH.
A computer may beat me at chess, but I always win at kick boxing.
Re: raspi-config doesn't set locale
I see the same problem. I am using arch linix
Re: raspi-config doesn't set locale
My fix was simple, after if figured it out
I put
export LC_ALL=C
in my .bashrc
I put
export LC_ALL=C
in my .bashrc
Re: raspi-config doesn't set locale
Why thanks. That does sound simple. I'll try it tomorrow morning and let you know if it works to fix my keyboard mapping problem. How did you figure this one out?
Thanks
Joe
Thanks
Joe
A computer may beat me at chess, but I always win at kick boxing.
Re: raspi-config doesn't set locale
The locale is normally set in the system for system wide use in
/etc/default/locale
You can also manually set the keyboard via the file
/etc/default/keyboard
/etc/default/locale
Code: Select all
# File generated by update-locale
LANG=en_US.UTF-8
/etc/default/keyboard
Code: Select all
# Check /usr/share/doc/keyboard-configuration/README.Debian for
# documentation on what to do after having modified this file.
# The following variables describe your keyboard and can have the same
# values as the XkbModel, XkbLayout, XkbVariant and XkbOptions options
# in /etc/X11/xorg.conf.
XKBMODEL="pc105"
XKBLAYOUT="us"
XKBVARIANT=""
XKBOPTIONS=""
# If you don't want to use the XKB layout on the console, you can
# specify an alternative keymap. Make sure it will be accessible
# before /usr is mounted.
# KMAP=/etc/console-setup/defkeymap.kmap.gz
Dweeber A.K.A. Kevin...
My RPI Info Pages including Current Setup - http://rpi.tnet.com
My RPI Info Pages including Current Setup - http://rpi.tnet.com
Re: raspi-config doesn't set locale
I tried the "export LC_ALL=C" in my .bashrc and it seems to work. The keyboard mapping seems to make sense now. Here's what I get from the locale command:
/etc/default/locale:
Everything seems to be working, so I'm now a happy camper!
Thanks for the post responses and the help they provided.
Joe
- LANG=en_US.UTF-8
LANGUAGE=
LC_CTYPE="C"
LC_NUMERIC="C"
LC_TIME="C"
LC_COLLATE="C"
LC_MONETARY="C"
LC_MESSAGES="C"
LC_PAPER="C"
LC_NAME="C"
LC_ADDRESS="C"
LC_TELEPHONE="C"
LC_MEASUREMENT="C"
LC_IDENTIFICATION="C"
LC_ALL=C
/etc/default/locale:
- # File generated by update-locale
LANG=en_US.UTF-8
- # KEYBOARD CONFIGURATION FILE
# Consult the keyboard(5) manual page.
XKBMODEL="logitech_base"
XKBLAYOUT="us"
XKBVARIANT=""
XKBOPTIONS="lv3:ralt_alt"
BACKSPACE="guess"
Everything seems to be working, so I'm now a happy camper!

Thanks for the post responses and the help they provided.
Joe
A computer may beat me at chess, but I always win at kick boxing.
Re: raspi-config doesn't set locale
That worked for me. Thank you!JimDod wrote:My fix was simple, after if figured it out
I put
export LC_ALL=C
in my .bashrc
Re: raspi-config doesn't set locale
I just found that if you don't set your locale properly in raspi-config (or original setup), you get those warnings. After you set your locale, it then asks for your Default Locale and gives you two options: None (selected by default), or the option you selected above. You need to select your option, then you won't get those warnings.
Cheers
Cheers
-
- Posts: 3
- Joined: Tue Aug 27, 2013 9:21 pm
Re: raspi-config doesn't set locale
ok how do you select the said option? because even if i select the none it still says the same thing on the bottom of the screen.daved wrote:I just found that if you don't set your locale properly in raspi-config (or original setup), you get those warnings. After you set your locale, it then asks for your Default Locale and gives you two options: None (selected by default), or the option you selected above. You need to select your option, then you won't get those warnings.
Cheers
when you highlight either of the options then hit ok. It gives the same result.
Generating locals (this might take a while)...
en_US.UTF-8
Generation complete
How do i select the right option?
Re: raspi-config doesn't set locale
I solved that with this:
And following the process
Code: Select all
sudo dpkg-reconfigure locales
Re: raspi-config doesn't set locale
In the long list of locales use space bar to select/un-select. Be sure to browse the entire list and un-select any unwanted locales. In the next menu you will see all of the locales that you selected in the first step. (Most should have only selected one locale). Use the arrow keys to move down the llst and highlight the one locale that you want then arrow to [OK] (Do not select NONE else you will get none).Jaroden [RasuOsu] wrote:ok how do you select the said option? because even if i select the none it still says the same thing on the bottom of the screen.daved wrote:I just found that if you don't set your locale properly in raspi-config (or original setup), you get those warnings. After you set your locale, it then asks for your Default Locale and gives you two options: None (selected by default), or the option you selected above. You need to select your option, then you won't get those warnings.
Cheers
when you highlight either of the options then hit ok. It gives the same result.
Generating locals (this might take a while)...
en_US.UTF-8
Generation complete
How do i select the right option?
Unless specified otherwise my response is based on the latest and fully updated RPi OS Bullseye w/ Desktop OS.
Re: raspi-config doesn't set locale
interesting, my ssh is in propper language and console is abra-cadabra.
Used raspi-config for configuration.
Used raspi-config for configuration.

Re: raspi-config doesn't set locale
I was having this same issue today. Try adding the following
export LANGUAGE=en_US.UTF-8
export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8
export LC_TYPE=en_US.UTF-8
export LANGUAGE=en_US.UTF-8
export LC_ALL=en_US.UTF-8
export LANG=en_US.UTF-8
export LC_TYPE=en_US.UTF-8