11

How can I set English as a default language in Debian ? I've installed Debian in a different language.

$ sudo update-locale LANG=en_US.UTF-8 LANGUAGE=en_US  
update-locale: Error: invalid locale settings:  LANGUAGE=en_US LANG=en_US.UTF-8

4 Answers 4

14

Using sudo dpkg-reconfigure locales should work.

2
  • 1
    By that, English has become a default language.
    – user121832
    Commented Aug 21, 2015 at 2:48
  • thnks, that worked! for information, the answer in serverfault.com/questions/301896/… is similar + gives more details if needed.
    – meduz
    Commented Feb 18, 2021 at 8:27
3

Edit file:

# vim /etc/default/locale

and write the following uncommented line:

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

and then comment the current uncommented lines and uncomment the line with en_US.UTF-8 (in the same file):

# en_US.ISO-8859-15 ISO-8859-15
en_US.UTF-8 UTF-8
# en_ZA ISO-8859-1

Save file and run:

# locale-gen

and restart the terminal.

For me, these steps work. I hope it helps you too.

3
  • 1
    I think the first and second file path are the same Commented Sep 25, 2020 at 9:30
  • Yes, you're right @MailoSvětel! I fixed it just now. Thank you! Commented Sep 25, 2020 at 15:26
  • I get Generating locales (this might take a while)... en_US.UTF-8...Killed on Debian 11 trying to run locale-gen!
    – appas
    Commented Apr 15, 2022 at 17:52
1

Can you start with the output of env | grep LANG? Make sure those all point to the proper lang/country, then do the dpkg command as mentioned by @vlp

0

Check the language environment variable: LC_LANG.

An easier way is to set the LC_ALL or LC_* variable to the value en_GB.UTF-8.

You must log in to answer this question.