Skip to content

Installing PostgreSQL 12 beta/RC on RHEL/CentOS/Fedora

PostgreSQL 12 is in beta right now, and we need everyone to test it!

We have been building repos even from daily builds, Below are the steps to install PostgreSQL 12 on RHEL 8:
First, please ownload repo rpm from here:

https://yum.postgresql.org/repopackages.php. You can copy and paste the following lines on your box:

On RHEL 8:
yum -y install https://download.postgresql.org/pub/repos/yum/reporpms/EL-8-x86_64/pgdg-redhat-repo-latest.noarch.rpm


On RHEL/CentOS 7:
https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm


On Fedora 29+:
yum -y install https://download.postgresql.org/pub/repos/yum/reporpms/F-30-x86_64/pgdg-fedora-repo-latest.noarch.rpm


On RHEL/CentOS 7 and 8, you need to enable EPEL repo, if you want GIS packages as well:

RHEL :
yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm


RHEL/CentOS 7:
yum -y install https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm


Since PostgreSQL12 is not stable yet, we distribute the RPMs via the "testing" repo. To enable the repo, please edit the repo file and enable v12 testing repo.

RHEL/CentOS: /etc/yum.repos.d/pgdg-redhat-all.repo


Fedora: /etc/yum.repos.d/pgdg-fedora-all.repo


Please find

[pgdg12-updates-testing]


and set

enabled=1


You can now install PostgreSQL 12:

RHEL/CentOS 7:
yum -y install postgresql12-server postgresql12-contrib


RHEL 8 and Fedora:
yum -y install postgresql12-server postgresql12-contrib


Initialize the cluster:

/usr/pgsql-12/bin/postgresql-12-setup initdb


If you are running multiple versions, you may want to change the port number first, by editing

/var/lib/pgsql/12/data/postgresql.conf


Now, start PostgreSQL 12:

systemctl enable --now postgresql-12


$ psql -c "SELECT version()"
version
-----------------------------------------------------------------------------------------------------------
PostgreSQL 12beta3 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 9.1.1 20190503 (Red Hat 9.1.1-1), 64-bit
(1 row)



Please report any bugs to https://www.postgresql.org/account/submitbug/

Trackbacks

No Trackbacks

Comments

Display comments as Linear | Threaded

No comments

Add Comment

Enclosing asterisks marks text as bold (*word*), underscore are made via _word_.
Standard emoticons like :-) and ;-) are converted to images.

To prevent automated Bots from commentspamming, please enter the string you see in the image below in the appropriate input box. Your comment will only be submitted if the strings match. Please ensure that your browser supports and accepts cookies, or your comment cannot be verified correctly.
CAPTCHA

Form options

Submitted comments will be subject to moderation before being displayed.