Re:PostgreSQL upgrades are hard
by 411111111111111 on Saturday June 25, 2022 @10:28AM
(#31875566)
My issue was indeed the mishmash of versions, as the restore succeeded with the mentioned steps (installing old version, restoring, upgrading).
nonetheless, interesting way to validate a backup, though it would probably take too long on most dumps
If you use -Fc, you can make an SQL file from the dump using pg_restore like this:
Or straight to stdout like this: Although I guess if it's corrupted pg_restore won't work.It is really fast, but might not be practical if your database is too big.