Linux Terminal garbled solution

Source: Internet
Author: User
Tags i18n

SSH connection to Linux often encounter garbled situation, painful for a long time, find a solution on the Internet, edit the ~/.bash_profile file, add the following two lines:

Lang= "ZH_CN. GB18030 "
Language= "ZH_CN. GB18030 "

After a period of time to find that this change in the VI is normal display in Chinese, but other places are garbled, such as restart services. In order for all interfaces to display Chinese correctly, you need to edit the/etc/sysconfig/i18n, the original lang= "ZH_CN. UTF-8 "comment out, add the following four lines:

Lang= "ZH_CN. GB18030 "
Language= "Zh_CN.GB18030:zh_CN.GB2312:zh_CN"
Supported= "ZH_CN. GB18030:zh_CH:zh:en_US. Utf-8:en_us:en "
Sysfont= "Lat0-sun16"

This will display the Chinese as normal in all interfaces.

BTW: After I test, in Rhel5u3 and CentOS5.2, only need to/etc/sysconfig/i18n lang= "ZH_CN. UTF-8 "Change to lang=" zh_cn.gb18030 "can all normal display Chinese , other systems temporarily unclear, and so on when you meet

Below is the red flag system under the i18n settings, paste it here, after the spare.

Lang= "ZH_CN. GB18030 "
Language= "Zh_CN.GB18030:zh_CN.GB2312:zh_CN"
Supported= "en_US. Utf-8:en_us:en:zh_cn. GB18030:zh_CN:zh:zh_TW.big5:zh_TW:zh:ja_JP. Utf-8:ja_jp:ja:ko_kr.euckr:ko_kr:ko "
Sysfont= "Lat0-sun16"
Sysfontacm= "8859-15"

Linux Terminal garbled solution

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.