Postgresql client update issue

I currently run a old school blog with PG <-> PHP <-> Apache nothing very fancy all without jails (which I think is what bytes me).

I currently have :
root@debellum:~ # pkg info |grep pg
pgbadger-12.4 Very competent log analyzer for PostgreSQL
php82-pdo_pgsql-8.2.21 The pdo_pgsql shared extension for php
php82-pgsql-8.2.21 The pgsql shared extension for php
root@debellum:~ # pkg info | grep postgr
postgresql15-client-15.8 PostgreSQL database (client)
postgresql15-server-15.8 PostgreSQL is the most advanced open-source database available anywhere

When I pkg update :
root@debellum:~ # pkg upgrade
Updating FreeBSD repository catalogue...
FreeBSD repository is up to date.
All repositories are up to date.
Checking for upgrades (21 candidates): 100%
Processing candidates (21 candidates): 100%
The following 22 package(s) will be affected (of 0 checked):

New packages to be INSTALLED:
postgresql16-client: 16.4

Installed packages to be UPGRADED:
bash: 5.2.26_1 -> 5.2.37
beats8: 8.8.2_9 -> 8.14.3_1
crowdsec: 1.6.2_2 -> 1.6.3_1
crowdsec-firewall-bouncer: 0.0.28_9 -> 0.0.29
htop: 3.3.0_2 -> 3.3.0_5
libedit: 3.1.20240517,1 -> 3.1.20240808,1
php82-dom: 8.2.21 -> 8.2.24
php82-filter: 8.2.21 -> 8.2.24
php82-gd: 8.2.21 -> 8.2.24
php82-gmp: 8.2.21 -> 8.2.24
php82-iconv: 8.2.21 -> 8.2.24
php82-mbstring: 8.2.21 -> 8.2.24
php82-pdo_pgsql: 8.2.21 -> 8.2.24
php82-pgsql: 8.2.21 -> 8.2.24
php82-session: 8.2.21 -> 8.2.24
php82-simplexml: 8.2.21 -> 8.2.24
php82-zlib: 8.2.21 -> 8.2.24
python311: 3.11.9 -> 3.11.10
python39: 3.9.19 -> 3.9.20
tor: 0.4.8.12 -> 0.4.8.13

Installed packages to be REINSTALLED:
apache24-2.4.62 (options changed)

I'll get complaints about
[1/2] Installing postgresql16-client-16.4...
pkg: postgresql16-client-16.4 conflicts with postgresql15-client-15.8 (installs files into the same place). Problematic file: /usr/local/bin/clusterdb

I think one of the php packages is requiring that, but there is not update available for pg server.

Is there a way to solve this?

I'm running
14.1-RELEASE-p5 FreeBSD 14.1-RELEASE-p5 GENERIC amd64
 
I did.
root@debellum:~ # pkg info -r postgresql15-client
postgresql15-client-15.8:
postgresql15-server-15.8
php82-pgsql-8.2.21
php82-pdo_pgsql-8.2.21
 
You need to upgrade to

postgresql16-client
postgresql16-server

Then reinstall

php82-pgsql
php82-pdo_pgsql
pgbadger

Code:
20240723:
  AFFECTS: users of databases/postgresql* and other software using PostgreSQL to run
  AUTHOR: kbowling@FreeBSD.org

  The default version of PostgreSQL has been switched from 15 to 16.
  The upgrade procedure can use up twice the space the databases
  currently needs. If you have a big amount of stored data take a
  closer look at the manpage of pg_upgrade for avoidance and/or
  speedup of the upgrade.

  The upgrade instructions consider a basic usage and do not match
  complex scenarios like replication, sharding, or similar.

  Upgrade instructions:

  First stop your PostgreSQL, create PostgreSQL-binaries and backup your data.
  If you have another Version of PostgreSQL installed, for example 15, your
  files are named according to this.

  # service postgresql stop
  # pkg create postgresql15-server postgresql15-contrib
  # mkdir /tmp/pg-upgrade
  # tar xf postgresql15-server-15.7.pkg -C /tmp/pg-upgrade
  # tar xf postgresql15-contrib-15.7.pkg -C /tmp/pg-upgrade
  # pkg delete -f databases/postgresql15-server databases/postgresql15-contrib databases/postgresql15-client

  Now update PostgreSQL:

    pkg user:
    # pkg install databases/postgresql16-server databases/postgresql16-contrib
    # pkg upgrade

    Portmaster users:
    # portmaster databases/postgresql16-server databases/postgresql16-contrib
    # portmaster -a

    Portupgrade users:
    # portinstall databases/postgresql16-server databases/postgresql16-contrib
    # portupgrade -a

  After installing the new PostgreSQL version you need to convert
  all your databases to new version:

  # su -l postgres -c "/usr/local/bin/initdb --encoding=utf-8 --lc-collate=C -D /var/db/postgres/data16 -U postgres"
  # su -l postgres -c "pg_upgrade -b /tmp/pg-upgrade/usr/local/bin/ -d /var/db/postgres/data15/ -B /usr/local/bin/ -D /var/db/postgres/data16/ -U postgres "

  Now the migration is finished. You can start PostgreSQL again with:

  # service postgresql start

  ATTENTION:
  1) If you use non-default initdb options, you have to adjust the initdb-command accordingly
 
Back
Top