4

Every-time I have to install a new Debian Linux system I encounter the same troubles with locales -- I do precisely want English system language with standards set to the country where I live, i.e. Germany.

The debian installer, and probably others, is asking at installation time for your "preferred" language. And every time I choose English. But then, I cannot add the standard locales of my country, because only English speaking countries are shown for the previously chosen language.

It's clear. After installation with enough manual fiddling it's achievable. And there is also a workaround (at least for European-ish users) by using en_IE.UTF-8 or en_DK.UTF-8 described here. However, this doesn't answer the question: Why it is so difficult to combine the preferred English system language with specific locales? I want to understand the reason/s and if there are any risks.

(Why do I want this? Because I can't see any advantage in (partially) traduced messages and software. Even more, it is much harder to find help when researching with English-foreign errors and messages got for the encountered issues.)

My actual configuration, AFAIK it works fine:

$ locale
LANG=en_US.UTF-8
LANGUAGE=
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY=de_DE.UTF-8
LC_MESSAGES="en_US.UTF-8"
LC_PAPER=de_DE.UTF-8
LC_NAME=de_DE.UTF-8
LC_ADDRESS=de_DE.UTF-8
LC_TELEPHONE=de_DE.UTF-8
LC_MEASUREMENT=de_DE.UTF-8
LC_IDENTIFICATION=de_DE.UTF-8
LC_ALL=
Rui F Ribeiro
  • 56,709
  • 26
  • 150
  • 232
alex
  • 983
  • sudo locale-gen de_DE.UTF-8 and then logout and login again and try export LC_ALL=de_DE.UTF-8. Does it work? – user996142 Jul 21 '17 at 21:07
  • @user996142 Thank you. According to Debian locales documentation LC_ALL=... will "override all other locale variables". This is precisely what I do NOT want. I do want to keep the system language to English (US or UK). – alex Jul 21 '17 at 21:29
  • LC_ALL overwrites all LC_ but not LANGUAGE nor LANG. And you can always set it explicitly. I mean you can do export LANG="en_GB.UTF-8" – user996142 Jul 21 '17 at 21:35
  • @user996142 LC_ALL overwrites everything except some aspects of LANGUAGE. In particular, if LC_ALL is set, LANG is ignored. – Gilles 'SO- stop being evil' Jul 21 '17 at 23:13
  • The problem is not due to your selection of locale settings. You'd have the same problem with LANG=de_DE.UTF8. It's due to missing system files which need to be generated with locale-gen. – Gilles 'SO- stop being evil' Jul 21 '17 at 23:15
  • @Gilles: Thank you. Raspbian has an configuration tool raspi-config where after the installation you can generate and set the required locales. $ locale -a results in: C C.UTF-8 de_DE.utf8 en_GB.utf8 POSIX. – alex Jul 22 '17 at 09:02
  • @Gilles: Please remove the duplicate flag. The solution proposed in the suggested "duplicate" is not working for me! Like told before raspi-config triggers sudo dpkg-reconfigure locales, I've done that, without errors, and there the generate step is successful -- see FYI attachment after the question. – alex Jul 22 '17 at 09:26
  • @alex please [edit] your question and show what solution(s) from the duplicate you found and how they failed. We need to see that to understand why you say it isn't a duplicate. – terdon Jul 22 '17 at 15:39
  • @terdon Thank you. Hope the edit shows clearly that the proposed solution of the supposed duplicate is not an answer for my problem. Please help/tell me how to unflag the duplicate-status. – alex Jul 23 '17 at 17:35
  • I don't understand what your edit changes. What you are describing isn't actually difficult, it is very easy to combine these things by setting the different variables. If your question is about why it's complicated, it might be better to post a new one and focus on that. Explain what it is you find difficult and ask why it works that way. As it stands, I honestly don't understand what you're asking about so the duplicate which explains how to do it seems correct. You might want to come into /dev/chat to discuss this. – terdon Jul 27 '17 at 09:31
  • terdon@ Sorry I don't get your point. You asked me to change and clarify the question: I've changed it. The question was suspended because of a supposed "duplicate": it is clear the question is now very specific and clearly distinct from the supposed "duplicate" -- otherwise the answer of the "duplicate" would be valid also for my question; which it isn't. Please help me to restore the status of the question in order to be again eligible. Thank you. – alex Jul 30 '17 at 18:04

0 Answers0