I’m currently running RT 5.0.7 and talking to Postgres 9.2.4. I need to upgrade my Postgres to hopefully the most recent version (which is in the 17.x number) - EDIT - looks like my flavour of Linux only supports 15.12 at the moment, which is probably okay, so, rest of this question stands.
Unfortunately, I’m using a Oracle Linux 7 system, so, it’s going to be a challenge getting PG upgraded at all, but, that aside, are there any known issues or incompatibilities with RT and the most recent versions of PG?
Should it be as simple as theoretically stopping RT/Apache/etc doing the PG upgrade, restarting PG and restarting RT’s bits and pieces?
Wow! That is a really, really ancient release of the DB and an unsupported OS release as well, unless you purchased extended support. I would make certain that your Perl DB modules are at the level to support pg-15.x. Do you have enough room to have the postgres-15 DB with data along side your current 9.2 DB? If so, set up a test box to run through the upgrade. Good luck.
You’re not wrong…sadly, the OS was forced upon me, and there seems no easy way to upgrade OL/RHEL without highly destructive “wipe and re-install” measures.
So far, I’ve had no issues keeping RT and Perl modules up to date. Everything has worked for the last five or so years.
I definitely have enough space for the Postgres-15 software, and even duplicate the database, but, a test box is a tougher ask, as I don’t have any way to install Oracle Linux 7 on anything.
It looks like the Postgres RPMs now install things into a directory specific for their version, such as /usr/pgsql-13 for Postgres 13.
My plan was to install Postgres 13, clone the database, configure Postgres 13 to point to that clone (by clone, I was planning on shutting down Postgres 9 and using rsync to copy the data to another location), and try to start Postgres 13 up with the data.
If that works, then going from Postgres 13 to 15 is probably easier.
Certainly open to other suggestions, but to a certain degree my hands are tied in that I have no way to build a second machine with the same configuration and try to do what I want.
Thanks for the reminder to check the Perl DB modules. I assumed that the RT dependency check would take care of that, but, I’ll review…
Hi,
I am not sure that going to version 13 and then to version 15 will save you that much. I would probably go directly to pg-15. How much downtime can you have in your setup? You could dump the production database and restore it to the pg-15 DB running on a separate port. Given any sort of maintenance window, you could point the production RT to the new DB to test functionality and timing and identify problems and their solution. Then repeat for the actual upgrade when you are satisfied with the results.
–Ken
Replying to my own post in case someone else needs to do what I did.
I performed the upgrade today, and it more or less worked okay.
Things I did:
Add the Yum repository from the PostgreSQL.org maintainers
Make sure “yum update” sees the new/upgraded version available
Run a pg_dumpall of my entire database Just In Case
run pg_upgrade from Postgresql15 in --check mode
Solve a bunch of broken things from the previous step
Get a clean pg_upgrade --check
Run pg_upgrade
Make sure Postgresql-9 was disabled in systemctl
Enable and start PostgreSQL-15
The pg_upgrade found a few things that needed tweaking. In particular, I needed to run the initdb from pgsql-15 with a --locale setting, and carefully review the directories and paths used by pg_upgrade.