when trying to update CentOS8 with PostgreSQL installed in this tutorial

this errors shows up:

repo: downloading from remote: pgdg94
error: Status code: 404 for https://download.postgresql.org/pub/repos/yum/9.4/redhat/rhel-8-x86_64/repodata/repomd.xml (https://download.postgresql.org/pub/repos/yum/9.4/redhat/rhel-8-x86_64/repodata/repomd.xml)

PostgreSQL 9.4 for RHEL/CentOS 8 - x86_64                                                                                                                                                                                                       261  B/s | 162  B     00:00    
Cannot download 'https://download.postgresql.org/pub/repos/yum/9.4/redhat/rhel-8-x86_64': Cannot download repomd.xml: Cannot download repodata/repomd.xml: All mirrors were tried.
Failed to download metadata for repo 'pgdg94'
Error: Failed to download metadata for repo 'pgdg94'

which basically means: the repo is not there anymore (404)

solution to the problem:

  1. remove the repo
    • yum -v repolist; # list all installed repositories
      rm -rf /etc/yum.repos.d/repo-one-wants-to-delete
  2. reinstall postgres according to official documentation updated howto: https://dwaves.de/2020/01/16/gnu-linux-setup-postgres-12-on-centos-8-terminal-bash-debugging-postgresql-connection-problems/
    • CentOS8 will upgrade to postgres 12.5