Linux Chinese display settings tutorial, linux display settings tutorial

Source: Internet
Author: User
Tags echo command i18n

Linux Chinese display settings tutorial, linux display settings tutorial

Sometimes garbled characters may occur, which is caused by inconsistent character sets. in Linux, you can adjust the character set to unify the character symbols and encoding:

View the text encoding format used by the current server:

[Root @ cs1 ~] # Cat/etc/sysconfig/i18n

LANG = "en_US.UTF-8"

SYSFONT = "latarcyrheb-sun16"

[Root @ cs1 ~] #

A good O & M should back up the configuration file before modifying the configuration file [root @ cs1 ~] # Cp/etc/sysconfig/i18n/etc/sysconfig/i18n. fzb20170711bak ----------------------------------------------------- backup

Modify the configuration file to display Chinese characters.

[Root @ cs1 ~] # Sed-I's # LANG = "en_US.UTF-8" # LANG = "zh_CN.UTF-8" # G'/etc/sysconfig/i18n --------------------------------- replace

Check whether the configuration file has been modified successfully: [root @ cs1 ~] # Cat/etc/sysconfig/i18n --------------------------------- View

LANG = "zh_CN.UTF-8"

SYSFONT = "latarcyrheb-sun16"

Use the source command to apply the configuration file: [root @ cs1 ~] # Source/etc/sysconfig/i18n ---------------------------- takes effect

Run the echo command to check whether the configuration file has taken effect:

[Root @ cs1 ~] # Echo $ LANG ----------------------------- check whether the configuration file has taken effect. The following results indicate that the configuration file has taken effect.

Zh_CN.UTF-8

[Root @ cs1 ~] #

O & M personnel usually remotely manage the server. Therefore, we need to set the encoding format of the client software to UTF-8:

The remote software uses the setup command to view the Chinese display interface:

 

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.