由于低于9.5的Postgresql版本将不受支持,我需要在我的Centos环境中更新此软件包。
Current version: postgres -V (PostgreSQL) 9.2.24
在我的生态系统中,还有另一个使用postgresql的rpm。对于这个rpm,有构建、重启脚本,还有监控依赖服务、检查状态等的各种脚本。
这些脚本都使用kwywork postgresql引用postgresql。
https://www.postgresql.org/download/linux/redhat/提供了如何进行更新/安装的确切步骤。但是,例如对于9.6版本,需要使用postgresql-9.6关键字来引用postgresql
这意味着需要仔细检查脚本和代码中对postgresql的所有引用,并分析是否需要更改。当然,之后更新到另一个版本将意味着重复这个过程。
有没有什么“开箱即用”的方法可以让我们在这次更新中保持脚本不变?
我还在这里复制/粘贴安装PostgreSQL9.6的步骤。
yum install https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm
yum install postgresql96-devel postgresql96-server
/usr/pgsql-9.6/bin/postgresql96-setup initdb
systemctl enable postgresql-9.6
systemctl start postgresql-9.6这是为了检查一切都很好
service postgresql-9.6 status发布于 2020-06-03 14:59:26
我不知道有什么“开箱即用的方法”。
你应该经常阅读详细的release notes来检查升级时是否有一些不兼容的地方。
https://stackoverflow.com/questions/62166875
复制相似问题