bug宝典linux篇 LC_CTYPE: cannot change locale (en_US.UTF-8): No such file or directory(转)
升级glibc库后,使用xShell登录linux,提示:
Connecting to 192.168.1.76:...
Connection established.
To escape to local shell, press Ctrl+Alt+]. WARNING! The remote SSH server rejected X11 forwarding request.
Last login: Mon Mar :: from 192.168.1.216
-bash: warning: setlocale: LC_CTYPE: cannot change locale (en_US.UTF-): No such file or directory
-bash: warning: setlocale: LC_COLLATE: cannot change locale (en_US.UTF-): No such file or directory
-bash: warning: setlocale: LC_MESSAGES: cannot change locale (en_US.UTF-): No such file or directory
-bash: warning: setlocale: LC_NUMERIC: cannot change locale (en_US.UTF-): No such file or directory
-bash: warning: setlocale: LC_TIME: cannot change locale (en_US.UTF-): No such file or directory
执行more /etc/sysconfig/i18n
命令检查系统字符集
[root@localhost ~]# more /etc/sysconfig/i18n
LANG="en_US.UTF-8"
SYSFONT="latarcyrheb-sun16"
执行locale
命令,提示如下异常,说明说明没安装en_US的local
[root@dashuju172 ~]# locale
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=en_US.UTF-
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=
解决方案,修改如下:
vim /etc/sysconfig/i18n
// 添加下面的
LC_ALL=C
export LC_ALL
// 再执行下面的语句,使之生效
source /etc/sysconfig/i18n
原文:https://blog.csdn.net/warrah/article/details/56008990
bug宝典linux篇 LC_CTYPE: cannot change locale (en_US.UTF-8): No such file or directory(转)的更多相关文章
- -bash: warning: setlocale: LC_CTYPE: cannot change locale (EN_US.UTF-8): No such file or directory
出问题原因: 通过 su - 切换用户时候,LANG设置为en或者设置错误,切换角色会出现这个错误 如何解决? echo $LANG # 查看 LANG 参数 sed 's#LANG=en#LANG= ...
- -bash: warning: setlocale: LC_CTYPE: cannot change locale (zh_US.UTF-8): No such file or directory -bash: warning: setlocale: LC_COLLATE:
前几天登录服务器发现出现了这些个警告,一直没时间去处理他,今天难得有空,处理一下并记录下来,希望可以帮助到有需要的朋友. 警告信息如下: Last :: from 10.0.0.1 -bash: wa ...
- -bash: warning: setlocale: LC_CTYPE: cannot change locale (zh_CN.UTF-8mb4): No such file or directory
前几天登录服务器发现出现了这些个警告,一直没时间去处理他,今天难得有空,处理一下并记录下来,希望可以帮助到有需要的朋友. 警告信息如下: Last login: Tue May :: from 192 ...
- MacOs -bash: warning: setlocale: LC_CTYPE: cannot change locale (UTF-8): No such file or directory
1解决iterm远程登录主机报错 -bash: warning: setlocale: LC_CTYPE: cannot change locale (UTF-8): No such file or ...
- -bash: warning: setlocale: LC_CTYPE: cannot change locale (UTF-8): No such file or directory
本人使用mac系统,命令行工具使用的iterm2,登录自己的云主机的时候 每次都要提示如下错误 -bash: warning: setlocale: LC_CTYPE: cannot change l ...
- bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8) Q: hubery@roaster:~$ locale loc ...
- 【云计算】Docker 镜像如何设置语言环境?bash: warning: setlocale: LC_ALL: cannot change locale (en_US)
解决方案: # set default language environment RUN locale-gen en_US.UTF- \ && dpkg-reconfigure loc ...
- docker本地化异常:/bin/sh: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
docker中经常设置不了 环境变量$LC_ALL, 导致报很多奇怪的编码错误: /bin/sh: warning: setlocale: LC_ALL: cannot change locale ...
- linux java jdk环境变量设置之后,依旧提示 No such file or directory
今天又默默的在linux下安装java 明明是很简单的事情,在~/.bashrc中添加如下内容: export JAVA_HOME=/home/ubuntu/jdkexport CLASSPATH=. ...
随机推荐
- Codeforces 1295B - Infinite Prefixes
题目大意: 给定一个长度为n的字符串s,由字符0和1组成 你可以让这个字符串s无限延长 就令字符串t=sssssss...... 求字符串t有多少个前缀字符串中,0的个数减去1的个数等于x 解题思路: ...
- 量化交易alpha、beta、shape等基本概念梳理
1.期货型基金(CTA)的 Alpha 和 Beta 是指什么? https://zhuanlan.zhihu.com/p/20700337 1980S ...
- TextView和Button的学习
常用属性,界面跳转,按钮学习,按压颜色的变换,图片的插入学习等 工程目录: MainActivity.java: package com.example.revrse; import androidx ...
- [Java-基础] 什么是ORM
ORM简介 ORM:对象关系映射:Object Relational Mapping 用于实现面向对象编程语言里不同类型系统的数据之间的转换 一般的,数据库绝大部分是面向关系的数据库,但是写代码的 ...
- LA 3882 经典约瑟夫环问题的数学递推解法
就是经典约瑟夫环问题的裸题 我一开始一直没理解这个递推是怎么来的,后来终于理解了 假设问题是从n个人编号分别为0...n-1,取第k个, 则第k个人编号为k-1的淘汰,剩下的编号为 0,1,2,3. ...
- 67)vector的begin() end() 和 front() back()的区别 rbegin() rend()
1) ·············· 2)`````````v1.begin() 和v1.end() 是作为迭代器v1的 第一个位置 和 最后一个元素的下一个位置. `````````````v1. ...
- 一个理解基本RCNN的简单例子
对于一个最简单的RNN网络https://github.com/Teaonly/beginlearning/ """Minimal character-level Van ...
- Java进行http请求时,放置会话信息到header里面
public class CreateHttpTest { public static void main(String[] args) { createHttp(); } public static ...
- Vue 项目中应用
Vue使用 一.vue生命周期 # main.js import Vue from 'vue' import App from './App.vue' import router from './ro ...
- 10. 通过 Dockerfile 编写 linux 命令行工具
测试 linux 压力的工具 一. 实际操作 1. 创建一个 ubuntu 的容器 docker run -it ubuntu 2. 安装 stress 工具 apt-get update & ...