Linux perl: warning: Setting locale failed.perl: warning: Please check that your locale settings:
使用 apt-get 安装软件时,总是出现下面的错误。
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = "en_US:",
LC_ALL = (unset),
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
安装软件时,都会去执行 update-locale 命令,用来更新 locale。这个命令是 perl 脚本(可以用 whereis update-locale 查到)
root@ubuntu:/# whereis update-locale
update-locale: /usr/sbin/update-locale /usr/share/man/man8/update-locale..gz
使用指令测试 perl,并不是因为 update-locale 命令错了,而是因为 perl 的配置出了问题。
root@ubuntu:/# perl -e exit
perl 使用系统提供的默认 local 的 en_US.UTF-8,但这个值是 ssh 从客户端传递来的,系统其实不知道 en_US.UTF-8 该如何处理。
安装语言包即可,但是不知道语言包名称,此时可以通过官网来查询语言包名称
ubuntu 查询包名网站:https://packages.ubuntu.com/

点击搜索后就会出现匹配的包名,其实 language-pack-en 依赖于 language-pack-en-base,安装 language-pack-en 的同时会默认安装 language-pack-en-base
如果想确认的话可以点击 language-pack-en 下面的 xenial(16.04 LTS),里面可以看到其所有依赖包、推荐包、建议包等。

root@ubuntu:/# apt-get install language-pack-en
安装成功后再使用指令测试 perl,再不会报错。
参考网站:https://www.jianshu.com/p/7cb39acb2513
Linux perl: warning: Setting locale failed.perl: warning: Please check that your locale settings:的更多相关文章
- perl: warning: Setting locale failed.
本篇文章由:http://xinpure.com/perl-warning-setting-locale-failed/ 将 mac 系统切换成英文后,使用 git 命令出现如下错误: perl: w ...
- 解决perl: warning: Setting locale failed.
在Ubuntu Server 12.04上执行apt-get install命令时,报如下warning 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 ...
- perl: warning: Setting locale failed. 解决
perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LANGUAG ...
- 解决:perl: warning: Please check that your locale settings
问题: perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: LAN ...
- Please check that your locale settings问题
问题描述: perl: warning: Setting locale failed. perl: warning: Please check that your locale settings: L ...
- 1- Mac和Linux远程连接服务器异常修复(WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED!)
p.p1 { margin: 0; font: 11px Menlo; color: rgba(0, 0, 0, 1) } span.s1 { font-variant-ligatures: no-c ...
- Linux系统非root用户安装perl模块
非root权限安装perl 在使用Linux或是unix时,perl是一个非常有用的脚本的语言. 关于perl的模块安装,网上也有很多介绍,一方面可以通过不同套件自带的软件安装工具安装,一方面可以通过 ...
- Warning: preg_replace(): Compilation failed: missing terminating ] for character class at offset 10 in
Warning: preg_replace(): Compilation failed: missing terminating ] for character class at offset 10 ...
- Installing perl and writing your first perl program in Ubuntu
Installing perl and writing your first perl program in Ubuntu Installing perl and writing your f ...
随机推荐
- table固定宽度与自动宽度
table-layout:auto(创建的table默认是此布局模式): 对table和td.th指定的宽度无效,浏览器会计算所有单元格的内容宽度才能得出一列宽度 如果想对单元格的内容自动折行需使用w ...
- 部署Java项目到阿里云服务器(Ubuntu16.04 64位)
生成Jar包 1.进入到项目所在的路径下,打开cmd命令控制台,使用如下命令打包项目. mvn package --前提将项目中使用的maven配置到系统的环境变量中 2.打包完成的jar包在项目目录 ...
- RuntimeWarning: DateTimeField AppToken.expire_date received a naive datetime (2019-05-16 16:54:01.144582) while time zone support is active. RuntimeWarning)
数据库存储当前时间操作: datetime.datetime.now() 更改为: from django.utils import timezone timezone.now()
- AD19新功能之跟随走线
跟随走线 AD19新增跟随走线,比如需要按照特定的轨迹进行走线,比如要绕着一个圆进行走线,或者靠着边框走线,普通模式下的效果如下图所示,线会跟着指针跑: 在走线模式下,按住 shift + f ,然后 ...
- 9.1: 请每个小组在 cnblogs.com 上面创建团队博客,第一个博客把小组成员都介绍一下 #团队博客作业1------------------答题者:徐潇瑞
大家好,我们这个团队的名字叫14组之家,之所以这么叫,因为我们是在章亦葵老师的现代软件工程课上成立为14组,而且我们每个组员在这个小家庭中都感受到温暖,我们互相协作,互相配合,来完成我们的任务. 首先 ...
- de4dot FAQ
How to deobfuscate but make sure metadata tokens stay the same? --preserve-tokens will preserve all ...
- el-input maxlength 不限制长度
背景: 小鱼最近使用 input输入框时想限制输入的长度, type = "number" 时,限制的长度无效,代码如下 <el-input v-model="fo ...
- Postgresql Useful SQL/Commands
Update records ' and a.subscriber_id=b.subscriber_id; Connections select count(*) from pg_stat_activ ...
- vue 使用element ui报错解决方案
安装: npm i element-theme-default -S main.js增加 import ElementUI from 'element-ui' import 'element-ui/l ...
- for循环中使用async/await
async function printFiles () { const files = await getFilePaths(); await Promise.all(files.map(async ...