How the Linux system changes the character set support, resolves the Linux Chinese display garbled so that the CentOS display Chinese

Source: Internet
Author: User
Tags locale

How Linux systems change the character set support


How to set Linux system Chinese Language, this is a lot of small partners in the beginning of the use of Linux, will encounter a problem, is the terminal input command echo when the Chinese display garbled. This situation typically occurs because the Chinese Language pack is not installed, or the default language that is set is causing the problem. Nithya this experience with CentOS as an example, how to operate Linux how to view the language, set the language of modification

The main change is the/etc/locale.conf file. The configuration file for the previous version of CENTOS7 is:/etc/sysconfig/i18n

View current system language

After logging on to the Linux system, enter the echo $LANG to view the system language currently in use. As

650) this.width=650; "src=" Https://s1.51cto.com/wyfs02/M01/9B/81/wKioL1lkCufCFBG2AAAugNhcU0I628.jpg "title=" 2017-07-11_071119.jpg "alt=" Wkiol1lkcufcfbg2aaaugnhcu0i628.jpg "/>

To view installed language packs

See if a Chinese language pack can be entered in the terminal locale command, if en cn indicates that the Chinese language is already installed

650) this.width=650; "src=" Https://s5.51cto.com/wyfs02/M00/9B/81/wKiom1lkCxGDy9AbAABN_Rr4b9M672.jpg "title=" 2017-07-11_071248.jpg "alt=" Wkiom1lkcxgdy9abaabn_rr4b9m672.jpg "/>

What if there is no Chinese language?

You can download and install the Chinese Language Pack online . Yum Groupinstall chinese-support (can not be networked to download through other computers, upload it up)

650) this.width=650; "src=" Https://s5.51cto.com/wyfs02/M00/9B/81/wKiom1lkCxGDy9AbAABN_Rr4b9M672.jpg "title=" 2017-07-11_071248.jpg "alt=" Wkiom1lkcxgdy9abaabn_rr4b9m672.jpg "/>

How to modify the system language to Chinese

1 Temporary language change

If you are only temporarily changing the language environment of the Linux system, you can set the lang= language name by typing, such as Chinese

Zn_cn. UTF-8(Note that I am here originally in Chinese, I temporarily set to English

650) this.width=650; "src=" Https://s3.51cto.com/wyfs02/M02/9B/81/wKioL1lkC0eBuGEoAABqKPKy12E551.jpg "title=" 2017-07-11_071339.jpg "alt=" Wkiol1lkc0ebugeoaabqkpky12e551.jpg "/>

Modifying the system default language

Span style= "font-family: ' Times New Roman '; font-weight:bold;" >vi  /etc/ (note : Execute /etc/ locale.conf or

650) this.width=650; "src=" Https://s3.51cto.com/wyfs02/M00/9B/81/wKioL1lkC1vg6TZaAABUBiiqbcU943.jpg "title=" 2017-07-11_071552.jpg "alt=" Wkiol1lkc1vg6tzaaabubiiqbcu943.jpg "/>

Other precautions

If you follow the above methods to set the Chinese language or not, pay attention to the encoding of your link terminal selection.

as An example of Xshell, the encoding of the terminal is selected in Chinese, or UTF8 can be

650) this.width=650; "src=" Https://s2.51cto.com/wyfs02/M01/9B/81/wKioL1lkC4Wy528oAADJnkbI0ik323.jpg "title=" 2017-07-11_071618.jpg "alt=" Wkiol1lkc4wy528oaadjnkbi0ik323.jpg "/>


This article is from the "Beloved Linux" blog, so be sure to keep this source http://mpflinux.blog.51cto.com/12173924/1946157

How the Linux system changes the character set support, resolves the Linux Chinese display garbled so that the CentOS display Chinese

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.