Below are the steps to install PostgreSQL version 11 and 12 using yum
NOTE: internet access is required in the server
Configuring yum repository in RHEL8/OEL8/CentOS8
yum install -y https://download.postgresql.org/pub/repos/yum/reporpms/EL-8-x86_64/pgdg-redhat-repo-latest.noarch.rpm
This creates a pgdg-redhat-all.repo in /etc/yum.repos.d
Run the command
rpm -qi pgdg-redhat-repo
to check package details
Disable the built-in PostgreSQL module to be able to install postgreSQL 11 and 12
dnf module disable postgresql
Clean the yum cache in order to install postgreSQL 11 and 12
yum clean all
If you want PostgreSQL11: Run the command to install PostgreSQL 11
yum install -y postgresql11-server
If you want PostgreSQL12:Run the command to install PostgreSQL 12
yum install -y postgresql12-server
check the version of installed PostgreSQL
psql -V
Comments
0 comments
Please sign in to leave a comment.