0


Linux yum安装pgsql出现Bad GPG signature错误

官方文档:https://www.postgresql.org/download/linux/redhat/

sudo yum install -y https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm
sudo yum install -y postgresql12-server
sudo /usr/pgsql-12/bin/postgresql-12-setup initdb
sudo systemctl enable postgresql-12
sudo systemctl start postgresql-12

按照官方文档操作执行如下命令:

sudo yum install -y postgresql12-server

提示找不到,此时需要进行如下操作:

# 查找repo文件,复制pgdg-redhat-all.repo这个文件名
ls -l /etc/yum.repos.d/

# 编辑这个配置文件,将刚刚复制的文件名添加进去
vim /etc/yum/pluginconf.d/releasever_adapter.conf

继续执行:sudo yum install -y postgresql12-server

出现错误:Error: Failed to download metadata for repo 'pgdg-common': repomd.xml GPG signature verification error: Bad GPG signature

此时只需要修改安装命令即可:

sudo yum install -y --nogpgcheck postgresql12-server
标签: linux 运维 服务器

本文转载自: https://blog.csdn.net/luostudent/article/details/136332580
版权归原作者 是良辰 所有, 如有侵权,请联系我们删除。

“Linux yum安装pgsql出现Bad GPG signature错误”的评论:

还没有评论