我尝试postgresql
在我的Ubuntu
服务器上运行
myname@myserver:/home$ sudo -i -u postgres
postgres@myserver:~$ psql
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = "en_US:",
LC_ALL = (unset),
LC_CTYPE = "UTF-8",
LANG = "en_US.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to a fallback locale ("en_US.UTF-8").
psql (9.5.14)
Type "help" for help.
postgres=# \q
我可以访问 postgres 但是我收到了perl
警告。
答案1
一种可行的解决方法是编辑~/.profile
文件并添加以下行:
unset LC_CTYPE
这将防止无效的UTF-8
语言环境名称出现在用户会话的环境中。