Linux终端显示中文

1、安装中文支持包

locale  #查看当前系统语言环境

locale -a  #查看系统支持的所有语言

yum groupinstall "Chinese Support"

或者

yum groupinstall "fonts"

2、修改当前系统支持中文

以下是CentOS 7.x和CentOS 6.x的路径:

vim /etc/locale.conf  #CentOS 7.x

vim /etc/sysconfig/i18n  #CentOS 6.x

把其中的 LANG="en_US.UTF-8" 改为 LANG="zh_CN.UTF-8",然后保存。

source /etc/sysconfig/i18n #重新加载该文件使区域语言设置立即生效。

转:https://ywnz.com/linuxjc/2382.html

原文地址:https://www.cnblogs.com/yzg-14/p/13563878.html