perl: warning: Setting locale failed.

perl: warning: Please check that your locale settings:
        LANGUAGE = (unset),
        LC_ALL = (unset),
        LANG = "zh_CN.GB2312;zh_CN.UTF-8;en_US;en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
        LANGUAGE = (unset),
        LC_ALL = (unset),
        LANG = "zh_CN.GB2312;zh_CN.UTF-8;en_US;en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").

在使用其它的某些命令时(如:mysqlhotcopy)也会也出现类似的提示。
搜索了好一段时间,并试了几次,找到一个解决此问题的简单方法,如下:

vi /root/.bashrc
再最底部加上
export LC_ALL=C
或者直接运行
echo "export LC_ALL=C" >> /root/.bashrc
然后执行一下:
source /root/.bashrc 

好了。

相关文章:

  • 2021-11-08
  • 2022-12-23
  • 2022-12-23
  • 2021-11-15
  • 2022-12-23
  • 2021-06-17
  • 2021-06-09
  • 2022-02-22
猜你喜欢
  • 2022-12-23
  • 2021-10-23
  • 2021-07-15
  • 2022-12-23
  • 2021-11-06
  • 2021-10-15
  • 2022-02-23
相关资源
相似解决方案