How to Fix locale Problems on Raspberry PI

How to fix messages about locale settings:

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").

Do you keep seeing these warnings? Do they bug you like they were bugging me? They’re really pretty easy to fix. It’s just the local settings. They make output on your screen look better. They control the way that searches work and programs compile. The problem is that the default Raspbian install doesn’t give enough information to locale, so it complains on occasion. To fix locale, edit the configuration in the file:

/etc/default/locale

The original file looks like this:

File generated by update-locale
LANG=en_US.UTF-8

add a couple of lines at the end, so it looks like this:

File generated by update-locale
LANG=en_US.UTF-8
LC_CTYPE=en_US.UTF-8
LC_MESSAGES=en_US.UTF-8
LC_ALL=en_US.UTF-8

Save and reboot. Problem solved!

Author: John

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.