A upgrade issue:timescaledb 2.16.1 in pg16 upgrade to timescaledb 2.17 in pg17

OS: rockylinux8
When I was upgrading to pg17 and timescaledb2.17, I performed a pre-upgrade check
[postgres@it-zbx-136 ~]$ /usr/pgsql-17/bin/pg_upgrade -b /usr/pgsql-16/bin/ -B /usr/pgsql-17/bin/ -d /var/lib/pgsql/16/data/ -D /var/lib/pgsql/17/data -k -c

The following error was reported:
could not load library “$libdir/timescaledb-2.16.1”: ERROR: could not access file “$libdir/timescaledb-2.16.1”: No such file or directory
In database: postgres
In database: zabbix

The following are my upgrade steps:

dnf install postgresql17-server
su - postgres —> /usr/pgsql-17/bin/initdb
rpm -ivh ./timescaledb-2-loader-postgresql-17-2.17.0-0.el8.x86_64.rpm
rpm -Uvh ./timescaledb-tools-0.17.0-0.el8.x86_64.rpm
rpm -ivh ./timescaledb-2-postgresql-17-2.17.0-0.el8.x86_64.rpm
timescaledb-tune --pg-config=/usr/pgsql-17/bin/pg_config
su - postgres —> /usr/pgsql-17/bin/pg_upgrade -b /usr/pgsql-16/bin/ -B /usr/pgsql-17/bin/ -d /var/lib/pgsql/16/data/ -D /var/lib/pgsql/17/data -k -c

I think in somehow it’s asking for the same library in the new pg. My understanding is that 2.17 should have the symlinks but it seems requiring the linked files.

Let’s double check with @sven as it was packed 3 days ago.

You cannot upgrade timescaledb and postgres at the same time. You need to do those as separate steps. So first you need to upgrade to 2.17.0 in pg16 and then you can upgrade postgres to 17. While changing postgres version the timescaledb versions have to match on both sides.

Indeed, when I successfully upgraded from pg15 to pg16 last time, the TimescaleDB version remained the same. Thanks for the reminder.