How to fix warning: setlocale: LC_CTYPE: cannot change locale (UTF-8)
来源:互联网 发布:开淘宝怎样找货源 编辑:程序博客网 时间:2024/05/01 23:18
I recently encountered a problem when logging through SSH in to certain servers that I use for work when using my new Macbook Pro (running Lion 10.9.2).
So right after the login was completed I was getting the following message:
warning: setlocale: LC_CTYPE: cannot change locale (UTF-8)
It only happened on certain servers, for others everything would work just fine.
This caused a few problems when running some perl scripts that would complain about the locale variables not being set, even though my Terminal app was setup correctly.
To fix this I simply added the following to my ~/.bash_profile:
export LC_CTYPE="en_US.UTF-8"
Let me know if that helped you by leaving a comment below!
0 0
- How to fix warning: setlocale: LC_CTYPE: cannot change locale (UTF-8)
- -bash: warning: setlocale: LC_CTYPE: cannot change locale (EN_US.UTF-8)
- -bash: warning: setlocale: LC_CTYPE: cannot change locale (UTF-8)
- warning: setlocale: LC_CTYPE: cannot change locale (zh_CN.UTF-8)
- -bash: warning: setlocale: LC_CTYPE: cannot change locale (zh_CN.UTF-8)
- -bash: warning: setlocale: LC_CTYPE: cannot change locale (zh_CN.UTF-8)
- -bash: warning: setlocale: LC_CTYPE: cannot change locale (EN_US.UTF-8)
- bash: warning: setlocale: LC_CTYPE: cannot change locale
- warning: setlocale: LC_CTYPE: cannot change locale
- Centos7 -bash: warning: setlocale: LC_CTYPE: cannot change locale (UTF-8): No such file or directory
- Linux之——bash: warning: setlocale: LC_CTYPE: cannot change locale (EN_US.UTF-8)
- warning: setlocale: LC_CTYPE: cannot change locale (en_US.utf8)
- LC_CTYPE: cannot change locale (UTF-8) error
- warning: setlocale: LC_CTYPE: cannot change locale (en_US): No such file or directory
- bash自动补全时出现“-bash: warning: setlocale: LC_CTYPE: cannot change locale”的解决方法
- warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8): No such file or directory
- bug宝典linux篇 LC_CTYPE: cannot change locale (en_US.UTF-8): No such file or directory
- svn: warning: cannot set LC_CTYPE locale 解决方法
- JSTL中fn表达式的使用说明
- 在eclipse里全项目替换关键词及内容的技巧
- IT界最难以替代的9个角色
- 如何在.NET中使用PB12.5的datawindow
- 原子STM32学习笔记--system文件夹
- How to fix warning: setlocale: LC_CTYPE: cannot change locale (UTF-8)
- opacity浏览器兼容问题解决
- 404
- 焦刚:云数据中心发展趋势及应用实践
- 向自由的人生前行
- POJ 1141 Brackets Sequence 动态规划
- C# 二进制字节流查找函数IndexOf
- Android JNI和NDK学习(4)--编译与预编译
- TCP/IP模型与OSI模型