2

I have a problem to generate the Locales on my server (Debian 7.5 stable (Wheezy) (64bits)). When I run, as a root:

dpkg-reconfigure locales

And select en_US.UTF-8, I get the following logs:

perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
    LANGUAGE = "en_GB:en",
    LC_ALL = (unset),
    LC_CTYPE = "UTF-8",
    LANG = "en_US.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_ALL to default locale: No such file or directory
/usr/bin/locale: Cannot set LC_CTYPE to default locale: No such file or directory
/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 = "en_GB:en",
    LC_ALL = (unset),
    LC_CTYPE = "UTF-8",
    LANG = "C"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
    LANGUAGE = "en_GB:en",
    LC_ALL = (unset),
    LC_CTYPE = "UTF-8",
    LANG = "C"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
sh: warning: setlocale: LC_CTYPE: cannot change locale (UTF-8)

Any idea why?

Thank you!

Cohars
  • 123

1 Answers1

2

Apparently you have LANGUAGE=en_GB:en in your environment, but you have not selected en_GB or other en variations to be generated (the first part of the dpkg-reconfigure locales).

You probably had en_GB as your old default but have now removed those from the list of locales to generate. However your environment still has the old setting, so perl is complaining that it can't find the (old) locale. That's not a problem per se for English-speaking people, the fallback locale is perfectly readable, so not really a problem.

Logging out and logging in again will pick up the new settings, alternatively you could do

source /etc/default/locale

from your shell.

Certain applications may not always have localization for your particular locale available; in such cases starting such an application as follows may help, as the C locale should always be available:

env LC_ALL=C applicationname
wurtel
  • 1,575