在Linux 中用Yum 安装java,报如下错误:
[dave@www.cndba.cn software]# yum install -y java-1.8.0-openjdk.x86_64 java-1.8.0-openjdk-devel.x86_64
……
Public key for ttmkfdir-3.0.9-32.1.el6.x86_64.rpm is not installed
[dave@www.cndba.cn software]#
yum 使用多年,第一次遇到这个问题,其实还是偷懒导致的,在yum源中配置gpgcheck=0导致的,修改gpgcheck 为0后,重新安装解决问题。
[dave@www.cndba.cn software]# vim /etc/yum.repos.d/CentOS-Base.repo
[dave@www.cndba.cn software]# cat /etc/yum.repos.d/CentOS-Base.repo
# CentOS-Base.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client. You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#
[base]
name=www.cndba.cn
baseurl=file:///mnt
gpgcheck=0
[dave@www.cndba.cn software]#
Linux 平台下 yum 源 配置 手册
https://www.cndba.cn/dave/article/154
版权声明:本文为博主原创文章,未经博主允许不得转载。