CentOS安装rpm安装MySQL时爆出警告:
警告:MySQL-server-5.5.46-1.linux2.6.x86_64.rpm: 头V3 DSA/SHA1 Signature, 密钥 ID 5072e1f5: NOKEY
原因:这是由于yum安装了旧版本的GPG keys造成的
解决办法:在语句后面加上:
--force --nodeps
如:
rpm -ivh MySQL-server-5.5.46-1.linux2.6.x86_64.rpm --force --nodeps
从 RPM 版本 4.1 开始,在安装或升级软件包时会检查软件包的签名。如果签名校验失败,你就会看到如下所示
的错误消息:
error: V3 DSA signature: BAD, key ID 0352860f
如果它是新的、只针对文件头的签名,你会看到如下所示的错误消息:
error: Header V3 DSA signature: BAD, key ID 0352860f
如果你没有安装合适的钥匙来校验签名,消息中就会包含 NOKEY ,如:
warning: V3 DSA signature: NOKEY, key ID 0352860f
在CentOS下有的时候用yum安装软件的时候最后会提示:
引用
warning: rpmts_HdrFromFdno: Header V3 DSA signature: NOKEY, key ID*****
这是由于yum安装了旧版本的GPG keys造成的,解决办法就是
引用
rpm --import /etc/pki/rpm-gpg/RPM*
再安装软件就不会有这个错误提示了。
另一种报错:
- [root@zzs36 mysql-5.7.13-1.el7.x86_64.rpm-bundle]# rpm -ivh mysql-community-server-5.7.13-1.el7.x86_64.rpm
- warning: mysql-community-server-5.7.13-1.el7.x86_64.rpm: Header V3 DSA/SHA1 Signature, key ID 5072e1f5: NOKEY
- error: Failed dependencies:
- libaio.so.1()(64bit) is needed by mysql-community-server-5.7.13-1.el7.x86_64
- libaio.so.1(LIBAIO_0.1)(64bit) is needed by mysql-community-server-5.7.13-1.el7.x86_64
- libaio.so.1(LIBAIO_0.4)(64bit) is needed by mysql-community-server-5.7.13-1.el7.x86_64
- mysql-community-client(x86-64) >= 5.7.9 is needed by mysql-community-server-5.7.13-1.el7.x86_64
问题分析:看报错,libaio.so.1 在安装时需要被应用进来,说明需要安装这个库。
1)下载库:libaio-0.3.107-10.el6.x86_64.rpm
2)安装库:rpm -ivh libaio-0.3.107-10.el6.x86_64.rpm
3) 需要检查环境中是否安装了mysql的其他包:
rpm -qa | grep mysql
rpm -qa | grep Mysql
rpm -qa | grep maridb
如果安装了,需要进行卸载: rpm -e --nodeps XXXXX
4) 依次安装rpm包:
- rpm -ivh libaio-0.3.109-13.el7.x86_64.rpm
- rpm -ivh mysql-community-common-5.7.13-1.el7.x86_64.rpm
- rpm -ivh mysql-community-libs-5.7.13-1.el7.x86_64.rpm
- rpm -ivh mysql-community-client-5.7.13-1.el7.x86_64.rpm
- rpm -ivh mysql-community-server-5.7.13-1.el7.x86_64.rpm