public inbox for [email protected]
help / color / mirror / Atom feedFrom: Peter J. Holzer <[email protected]>
To: [email protected]
Subject: Upgrade Ubuntu 22 -> 24 may break PostgreSQL
Date: Sat, 31 Aug 2024 18:54:45 +0200
Message-ID: <[email protected]> (raw)
'Tis the season again.
Ubuntu 24.04.1 has just been released, so many Ubuntu LTS users will now
be prompted to upgrade from 22.04 to 24.04.
A word of warning to those who use Postgresql from the Ubuntu repo (not
PGDG):
As usual, a newer Ubuntu version comes with a newer Postgres version (16
instead of 14). Also as usual, I got a message during the upgrade that
Postgres 14 is obsolete,. but the binaries have been left installed and
I should upgrade to Postgres 16 manually ASAP.
But after the reboot, PostgreSQL failed to start because it needed a
shared library (libldap) which was no longer there. So a normal
pg_upgradecluster wouldn't work.
In my case the quickest way to recover was to install postgresql-14 on a
VM, copy the data direcory into that instance and make a fresh dump,
then install postgresql-16 on my laptop and restore the dump. Annoying,
but no big deal for the small test database I keep on my laptop. If you
have multi-terabyte databases, your situation may be different.
I'm not exactly sure what went wrong (I got some conflicts during the
upgrade and maybe I shouldn't have invoked apt autoremove?), and you may
not have this problem, but make sure you have a backup before the
upgrade.
hp
--
_ | Peter J. Holzer | Story must make more sense than reality.
|_|_) | |
| | | [email protected] | -- Charles Stross, "Creative writing
__/ | http://www.hjp.at/ | challenge!"
Attachments:
[application/pgp-signature] signature.asc (833B, 2-signature.asc)
download
view thread (4+ messages) latest in thread
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected]
Subject: Re: Upgrade Ubuntu 22 -> 24 may break PostgreSQL
In-Reply-To: <[email protected]>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox