public inbox for [email protected]
help / color / mirror / Atom feedFrom: Julien Rouhaud <[email protected]>
To: Matthias van de Meent <[email protected]>
Cc: PostgreSQL Hackers <[email protected]>
Subject: Re: Online PostgreSQL version() updates
Date: Wed, 1 Apr 2026 19:24:48 +0800
Message-ID: <ac0AgLVR7htuTG1b@jrouhaud> (raw)
In-Reply-To: <CAEze2WjgxD-uZrjiD7Gtp2gy=ztAOTU+xyLNJg6saYG4erP_=w@mail.gmail.com>
References: <CAEze2WjgxD-uZrjiD7Gtp2gy=ztAOTU+xyLNJg6saYG4erP_=w@mail.gmail.com>
Hi,
On Wed, Apr 01, 2026 at 12:48:08PM +0200, Matthias van de Meent wrote:
> Hi,
>
> March has gone and passed, and the feature freeze for 19 is on the
> horizon; which also means it's time for users to start thinking about
> version updates.
>
> One of the greatest complaints people have about PostgreSQL is that
> they can't update its version() without at least some downtime being
> involved, either due to failovers or because their postmaster needs to
> be restarted. Updating to a new major version() is often
> time-consuming, complicated, and may involve moving terabytes of data;
> sometimes with no practical methods to avoid this.
>
> Until now.
>
> Attached is a patch that allows superusers to update the version() of
> their running system with a simple SQL call: SELECT
> pg_update_version(version_num, 'version_short', 'the full version()
> outout'). Running backends will automatically get updated without
> impacting their active workloads, and new backends will immediately
> notice the new version().
>
> Local testing of the patch indicates no significant performance loss
> in normal workloads, with only a small amount of shared memory being
> spent on the coordination of the update process.
I might be missing something but I don't see how this can be safe.
Indeed, there is no WAL record emitted for this critical operation! Making it
WAL logged will make it crash safe, and will ensure that your replica and
backup are updated too!
view thread (8+ 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], [email protected], [email protected]
Subject: Re: Online PostgreSQL version() updates
In-Reply-To: <ac0AgLVR7htuTG1b@jrouhaud>
* 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