关于-bash: warning: setlocale: LC_CTYPE: cannot change locale 问题

在普通用户跟root登陆时都出现了一下错误:
  -bash: warning: setlocale: LC_CTYPE: cannot change locale (zh_US.UTF-8): No such file or directory
-bash: warning: setlocale: LC_COLLATE: cannot change locale (zh_US.UTF-8): No such file or directory
-bash: warning: setlocale: LC_MESSAGES: cannot change locale (zh_US.UTF-8): No such file or directory
-bash: warning: setlocale: LC_NUMERIC: cannot change locale (zh_US.UTF-8): No such file or directory
-bash: warning: setlocale: LC_TIME: cannot change locale (zh_US.UTF-8): No such file or directory
查看[root@localhost ~]# locale
LANG=zh_US.UTF-8
LC_CTYPE="zh_US.UTF-8"
LC_NUMERIC="zh_US.UTF-8"
LC_TIME="zh_US.UTF-8"
LC_COLLATE="zh_US.UTF-8"
LC_MONETARY="zh_US.UTF-8"
LC_MESSAGES="zh_US.UTF-8"
LC_PAPER="zh_US.UTF-8"
LC_NAME="zh_US.UTF-8"
LC_ADDRESS="zh_US.UTF-8"
LC_TELEPHONE="zh_US.UTF-8"
LC_MEASUREMENT="zh_US.UTF-8"
LC_IDENTIFICATION="zh_US.UTF-8"
LC_ALL=

再在 /etc/sysconfig/i18n下设置:

LANG="zh_US.UTF-8"


之后把LANG="zh_US.UTF-8"改为LANG="en_US.UTF-8"在重新登陆就正常了。

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/28874898/viewspace-767730/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/28874898/viewspace-767730/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值