关于ubuntu上执行错误命令报错
Sorry, command-not-found has crashed!
新安装了一台ubuntu server
安装时用中文安装的,之后命令行下各种乱码,最后也不知道是修改哪里造成的
每次执行一次错误的命令就会报错:(报错信息如下)
Sorry, command-not-found has crashed! Please file a bug report at:
https://bugs.launchpad.net/command-not-found/+filebug
Please include the following information with the report:
command-not-found version: 0.3
Python version: 3.3.1 final 0
Distributor ID: Ubuntu
Description: Ubuntu 13.04
Release: 13.04
Codename: raring
Exception information:
unsupported locale setting
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/CommandNotFound/util.py", line 24, in crash_guard
callback()
File "/usr/lib/command-not-found", line 69, in main
enable_i18n()
File "/usr/lib/command-not-found", line 40, in enable_i18n
locale.setlocale(locale.LC_ALL, '')
File "/usr/lib/python3.3/locale.py", line 541, in setlocale
return _setlocale(category, locale)
locale.Error: unsupported locale setting
当然后来安装了zsh后解决了,但是vi里面中文还是显示乱码
google了下,说是编码有问题
解决方法
bash下执行命令:
export
LANGUAGE=en_US.UTF-8
export
LANG=en_US.UTF-8
export
LC_ALL=en_US.UTF-8
sudo locale-gen en_US.UTF-8
sudo
dpkg-reconfigure locales
最新文章
- cross_domain
- iOS6_自动约束 Constraints
- js中函数的一些理论知识
- 不从SD卡启动树莓派2
- 练习3:修改withdraw 方法 练习目标-使用有返回值的方法:在本练习里,将修改withdraw方法以返回一个布尔值来指示交易是否成功。
- 使用office制作图章公章
- 创建链接服务器(dblink)
- android AsyncTask 只能在线程池里单个运行的问题
- vs vim 插件
- 创建一个web Test Plan
- Fence Repair
- 『重构--改善既有代码的设计』读书笔记----Introduce Local Extension
- HashMap之Hash碰撞冲突解决方案及未来改进
- 前端工程之node基础
- Ubuntu初始化MySQL碰到的坑
- Android 异步框架 RxJava2
- Mysql----修改MySQL5.7的root的密码
- python 读取配置文件方法
- PAT 乙级 1036 跟奥巴马一起编程(15) C++版
- ehlib使用内存表的方法
热门文章
- codis集群和redis cluster的优劣对比
- bzoj3926: [Zjoi2015]诸神眷顾的幻想乡 对[广义后缀自动机]的一些理解
- SGU107——987654321 problem
- Unicode和字符集小结
- 在SCVMM2012R2中删除失去联系的VM GateWay
- linux ssh 中在window 传文件 下载文件 工具
- 【剑指offer】包括min函数的栈
- Android AlertDialog 设置setSingleChoiceItems不显示列表的原因【setMessage和setSingleChoiceItems不能同时使用】
- [转] Understanding JavaScript’s async await
- Java synchronized 总结