the problems encountered:
1.-bash:warning:setlocale:lc_all:cannot change locale (En_us.utf8)
Locale-gen en_US. UTF-8
Update-local en_US. UTF-8
2.en_us. UTF-8. Cannot open Locale definition file ' translit_neutral ': No such file or directory
Copying files from another machine
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_collate to default locale:no such file or directory
But/usr/lib/locales does have a number of character sets.
(1) rm-rf/usr/lib/locale/* (2) dpkg-reconfigure locales (3) Locale-gen (4) update-local wait, No.
Finally copy the/usr/share/i18n directory from another machine, the Execution (1) (3) problem disappears. Another point: Which locale determine whether the locale program in use is expected. Summary: 1. The new character library encoded information is located under the/usr/share/i18n directory, where supported contains the available character sets, which are in the following format:
zh_sg. UTF-8 UTF-8
Zh_sg. GBK GBK
zh_tw. EUC-TW euc-tw
zh_tw. UTF-8 UTF-8 ...
The mapping information for each character set stored in the charmaps can be called the original file (there may be a term, however many). Use Localedef to generate character sets, which are the locales inside. But these are not the characters that can be used in the system. The files in these/usr/share/i18n just described are only available in the set, locale-m can see the list. Since there are dozens of characters in the Linux character set, and most users can use more than one, there is no need to integrate all the character sets into the system. Only part of the character set is used inside the system. In addition, in order to allow the system to use, the original/usr/share/i18n documents to be processed (complile), can be used in the character encoding under/usr/lib/locale/, become the complied character set. 2. Using Locale-gen, you can complie the files in the original/usr/share/i18n into the/usr/lib/locale/character set that the system can use. The Locale-gen parameter is a list of character sets to use, which can be developed under the terminal. Otherwise it will be automatically searched under the./var/lib/locales/supported.d/. Compilation-generated character sets can exist in two ways: a.archive file:/usr/lib/locale/locale-archive B. Sub-directory storage. Refer to Man Locale-gen 3. /USR/SHARE/I18N inside the operating system is irrelevant, different architectures, different systems can be common, if there is a lack of replication from other places can be.
Error:locale-gen en_US. UTF-8:
en_US. UTF-8. Cannot open Locale definition file ' translit_neutral ': No such file or directory failed
en_US. UTF-8. Cannot open Locale definition file ' translit_combining ': No such file or directory
: Copy/usr/share/i18n/locales/transx from another machine to the local/usr/share/i18n/locales directory.