Re: pg_upgrade: transfer pg_largeobject_metadata's files when possible
Nathan Bossart <nathandbossart@gmail.com>
From: Nathan Bossart <nathandbossart@gmail.com>
To: Hannu Krosing <hannuk@google.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, Nitin Motiani <nitinmotiani@google.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2025-08-19T19:18:40Z
Lists: pgsql-hackers
On Tue, Aug 19, 2025 at 09:49:26AM +0200, Hannu Krosing wrote: > Have you considered re-creating pg_shdepend from > pg_largeobject_metadata directly instead of having special cases for > dumping it ? I considered it when you last brought up the idea [0], but my testing indicated that it's measurably slower. > It would also be useful in cases of old (pg_upgraded since before pg > 12) databases which might be missing it anyway. We only use COPY for upgrades from v12 and newer, and the patch at hand only applies to v16 and newer. There should be no need to repair pg_shdepend for any such upgrades because we haven't copied/linked the files since before v12. [0] https://postgr.es/m/CAMT0RQTXiqH7zdQEVSVd2L7_Cw4wQ1eHOD8hfZ%2B0vecMXJWc-w%40mail.gmail.com -- nathan
Commits
-
pg_upgrade: Use COPY for LO metadata for upgrades from < v12.
- b33f75361284 19 (unreleased) landed
-
pg_upgrade: Fix handling of pg_largeobject_metadata.
- 158408fef8b9 19 (unreleased) landed
-
pg_upgrade: Transfer pg_largeobject_metadata's files when possible.
- 3bcfcd815e1a 19 (unreleased) landed
-
Rearrange pg_dump's handling of large objects for better efficiency.
- a45c78e3284b 17.0 cited
-
Expand AclMode to 64 bits
- 7b378237aa80 16.0 cited
-
Fix pg_upgrade for oid removal.
- 12a53c732ced 12.0 cited