CentOS Chinese Language Garbled solution method

Source: Internet
Author: User
Tags i18n locale

Some time ago I do not know why the CentOS system with Chinese garbled, looked at some online methods, summed up as follows:


1, check your system has not installed the Chinese Language pack, you can use the LOCALE-A command to list all the available locales:


See if there are the following four items:


If there is, do not install, if not, need to reinstall, use yum install Kde-l10n-chinese



2, modify the i18n and locale.conf configuration files


First, vim/etc/sysconfig/i18n, add the following two lines of code inside:

Lang= "ZH_CN. UTF-8 "

Lc_all= "ZH_CN. UTF-8 "



Then execute it to make the file that you just modified take effect: source/etc/sysconfig/i18n



Second, vim/etc/locale.conf

Add: lang= "ZH_CN. UTF-8 "


Also execute to make the file just modified to take effect source/etc/locale.conf



You can write when you are writing Chinese fonts and will not display garbled characters:






Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.