1. First, check the default character set commands used by the system: locale or echo $ LANG. if the Chinese language pack has been selected during installation, the default is the UTF-8 character set [root @ localhost ~] # LocaleLANG = zh_CN.UTF-8LC_CTYPE = & quot; zh_CN.UTF-8 & quot; LC_NUMERIC = & quot; zh_CN.UTF-8
First, check the current system default character set command: locale or echo $ LANG, if the original installation has selected a Chinese language pack, then the default is the UTF-8 character set
[Root @ localhost ~] # Locale
LANG = zh_CN.UTF-8
LC_CTYPE = "zh_CN.UTF-8"
LC_NUMERIC = "zh_CN.UTF-8"
LC_TIME = "zh_CN.UTF-8"
LC_COLLATE = "zh_CN.UTF-8"
LC_MONETARY = "zh_CN.UTF-8"
LC_MESSAGES = "zh_CN.UTF-8"
LC_PAPER = "zh_CN.UTF-8"
LC_NAME = "zh_CN.UTF-8"
LC_ADDRESS = "zh_CN.UTF-8"
LC_TELEPHONE = "zh_CN.UTF-8"
LC_MEASUREMENT = "zh_CN.UTF-8"
LC_IDENTIFICATION = "zh_CN.UTF-8"
LC_ALL =
[Root @ localhost ~] # Echo $ LANG
Zh_CN.UTF-8
2, SecureCRT modification, Options → session options, the appearance of the character set to the UTF-8, the other terminal program is the same
3. if the character set in step 1 is displayed as other characters, install the chinese character package and run the command: yum-y groupinstall chinese-support.
After installation, modify the character encoding configuration. Command: vim/etc/locale. conf change LANG = "XXXX" to LANG = "zh_CN.UTF-8", note that the character set configuration file for Centos7 is/etc/locale. conf. if it is a version earlier than 7, modify/etc/sysconfig/i18n. after modification, remember reboot.