这个问题确实很奇怪,我尝试了很多方法来解决,但都没有用。我最后的输出是:
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = "pl_PL.UTF-8"
are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
Setting up mysql-server-5.5 (5.5.38-0ubuntu0.14.04.1) ...
locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
/var/lib/dpkg/info/mysql-server-5.5.postinst: line 146: logger: command not found
ATTENTION: An error has occured. More info is in the syslog!
/var/lib/dpkg/info/mysql-server-5.5.postinst: line 236: logger: command not found
dpkg: error processing package mysql-server-5.5 (--configure):
subprocess installed post-installation script returned error exit status 127
dpkg: dependency problems prevent configuration of mysql-server:
mysql-server depends on mysql-server-5.5; however:
Package mysql-server-5.5 is not configured yet.
dpkg: error processing package mysql-server (--configure):
dependency problems - leaving unconfigured
Errors were encountered while processing:
mysql-server-5.5
mysql-server
E: Sub-process /usr/bin/dpkg returned an error code (1)
我真的不知道如何解决这个问题,大家帮帮我吧:)
答案1
与 mysql-server-5.6 有同样的问题,这个解决方案对我有帮助:
launchpad:Bug #392051:[Karmic] 未找到记录器命令
基本上,这个程序logger
被搞乱了;
可以通过重新安装包来重新创建它bsdutils
:
apt-get --reinstall install bsdutils
或者
aptitude reinstall bsdutils
答案2
您的“语言环境”尚未生成,或生成不正确。
尝试这个:
sudo locale-gen en_US en_US.UTF-8 pl_PL pl_PL.UTF-8
sudo dpkg-reconfigure locales
然后再次尝试安装 MySQL。
答案3
这是从该区块引用的原始答案:
更新区域设置:
sudo locale-gen fi_FI.UTF-8
sudo dpkg-reconfigure locales
apt-get update
运行下面的命令
在你的服务器上,它将替换所有的 archive.ubuntu.com
和 security.ubuntu.com
包存储库 URL old-releases.ubuntu.com
sudo sed -i -e 's/us.old-releases.ubuntu.com\|security.ubuntu.com/old-releases.ubuntu.com/g'/etc/apt/sources.list
sudo sed -i -e 's/archive.ubuntu.com\|security.ubuntu.com/old-releases.ubuntu.com/g'/etc/apt/sources.list
apt-get update