centos7 设置中文
2015-12-29 20:32
537 查看
查看系统版本
[root@webtest76 ~]# cat /etc/redhat-release
CentOS Linux release 7.0.1406 (Core)
[root@localhost ~]# cat /etc/locale.conf
LANG=en_US.UTF-8
[root@localhost ~]# cp /etc/locale.conf /etc/locale.conf_bak
[root@localhost ~]# vim /etc/locale.conf # 修改后原英文错误信息会变成中文信息
LANG="zh_CN.GB18030"
LANGUAGE="zh_CN.GB18030:zh_CN.GB2312:zh_CN"
SUPPORTED="zh_CN.UTF-8:zh_CN:zh:en_US.UTF-8:en_US:en"
SYSFONT="lat0-sun16"
or [root@localhost ~] localectl set-locale LANG=zh_CN.UTF-8
[root@localhost ~]# reboot # 重新系统
[root@webtest76 ~]# vi /etc/sysconfig/i18n # 如果默认安装的是中文的系统,i18n的内容如下:
LANG="zh_CN.UTF-8"
SYSFONT="latarcyrheb-sun16"
SUPPORTED="zh_CN.UTF-8:zh_CN:zh"
[root@webtest76 ~]# echo $LANG # 查看当前使用的系统语言
zh_CN.UTF8
[root@localhost ~]# export LANG=zh_CN.UTF8 # 将系统语言临时设置为中文,export方式不需要重新登录
[root@webtest76 ~]# ll
总用量 712504
# yum install kde-l10n-Chinese # centos 7以下版本使用以下命令安装 yum groupinstall chinese-support
# yum install bitmap-fonts bitmap-fonts-cjk
[root@webtest76 ~]# cat /etc/redhat-release
CentOS Linux release 7.0.1406 (Core)
[root@localhost ~]# cat /etc/locale.conf
LANG=en_US.UTF-8
[root@localhost ~]# cp /etc/locale.conf /etc/locale.conf_bak
[root@localhost ~]# vim /etc/locale.conf # 修改后原英文错误信息会变成中文信息
LANG="zh_CN.GB18030"
LANGUAGE="zh_CN.GB18030:zh_CN.GB2312:zh_CN"
SUPPORTED="zh_CN.UTF-8:zh_CN:zh:en_US.UTF-8:en_US:en"
SYSFONT="lat0-sun16"
or [root@localhost ~] localectl set-locale LANG=zh_CN.UTF-8
[root@localhost ~]# reboot # 重新系统
[root@webtest76 ~]# vi /etc/sysconfig/i18n # 如果默认安装的是中文的系统,i18n的内容如下:
LANG="zh_CN.UTF-8"
SYSFONT="latarcyrheb-sun16"
SUPPORTED="zh_CN.UTF-8:zh_CN:zh"
[root@webtest76 ~]# echo $LANG # 查看当前使用的系统语言
zh_CN.UTF8
[root@localhost ~]# export LANG=zh_CN.UTF8 # 将系统语言临时设置为中文,export方式不需要重新登录
[root@webtest76 ~]# ll
总用量 712504
# yum install kde-l10n-Chinese # centos 7以下版本使用以下命令安装 yum groupinstall chinese-support
# yum install bitmap-fonts bitmap-fonts-cjk
相关文章推荐
- linux系统下怎么输入EOF退出输入循环while(getline(cin, temp)){.....}
- 大战C100K之-Linux内核调优篇--转载
- linux时间同步
- Linux——用户及文件权限
- linux系统的7种运行级别
- [转载]linux下编译php中configure参数具体含义
- 浅谈Linux的硬盘分区和目录结构——新手向
- 为什么linux下要configure然后make make install?
- linux系统简单搭建iSCSI
- CentOS下LVM的使用:逻辑卷的压缩、创建
- centos之rpm详解
- Linux编程之一:创建第一个C/C++程序
- Linux管道通信
- linux编译64bitHadoop (eg: ubuntu14.04 and hadoop 2.3.0)
- linux信号处理时机
- Linux学习——环境变量设置
- Linux下mount命令解析
- Linux C 算法——查找
- LINUX 文件I/O
- 虚拟机CentOS6.3环境下配置ip地址(慕课学习笔记)