PostgreSQL - SLES Repo Configuration

Available SuSE repository configuration files

You can use the zypper package manager to install PostgreSQL and/or other components on an SLES 12 / SLES 15 host. zypper will attempt to satisfy package dependencies as it installs a package, but some components require access to specific repositories that are not hosted at postgresql.org.

To add PostgreSQL and/or other components, use the following commands to add PostgreSQL community repository configuration files to your SLES host:

PostgreSQL 13 (v13 PACKAGES ARE FOR BETA TESTING ONLY! USE v12 PACKAGES FOR PRODUCTION).

  • SLES 12: zypper addrepo https://download.postgresql.org/pub/repos/zypp/repo/pgdg-sles-13.repo
  • SLES 15: zypper addrepo https://download.postgresql.org/pub/repos/zypp/repo/pgdg-sles-15-pg13.repo

PostgreSQL 12

  • SLES 12: zypper addrepo https://download.postgresql.org/pub/repos/zypp/repo/pgdg-sles-12.repo
  • SLES 15: zypper addrepo https://download.postgresql.org/pub/repos/zypp/repo/pgdg-sles-15-pg12.repo

PostgreSQL 11

  • SLES 12: zypper addrepo https://download.postgresql.org/pub/repos/zypp/repo/pgdg-sles-11.repo

PostgreSQL 10

  • SLES 12: zypper addrepo https://download.postgresql.org/pub/repos/zypp/repo/pgdg-sles-10.repo

PostgreSQL 9.6

  • SLES 12: zypper addrepo https://download.postgresql.org/pub/repos/zypp/repo/pgdg-sles-96.repo

PostgreSQL 9.5

  • SLES 12: zypper addrepo https://download.postgresql.org/pub/repos/zypp/repo/pgdg-sles-95.repo

After creating the repository configuration files, use the zypper refresh command to refresh the metadata on your SLES host to include the PostgreSQL SUSE repositories:

zypper refresh

Before installing PostgreSQL and/or other supporting components, you must also add SUSEConnect and the SUSE Package Hub extension to the SLES host, and register the host with SUSE, allowing access to SUSE repositories. Use the commands:

zypper install SUSEConnect
SUSEConnect -p PackageHub/12/x86_64
SUSEConnect -p sle-sdk/12/x86_64

For detailed information about registering a SUSE host, visit: https://www.suse.com/support/kb/doc/?id=7016626.

Installing PostgreSQL on SLES host

After adding the repo, use the following command to install PostgreSQL on the SLES host:

PostgreSQL 12:

zypper install postgresql12-server

PostgreSQL 11:

zypper install postgresql11-server

PostgreSQL 10:

zypper install postgresql10-server

PostgreSQL 9.6:

zypper install postgresql96-server

PostgreSQL 95:

zypper install postgresql95-server

Please take a look at the PostgreSQL SuSE package list to see what other packages are available in the repository.