Short version for the impatient: a pg_dump that exits with code 0 tells you the dump finished. It doesn't tell you the dump restores, and it says nothing about whether the restored database has your data in it. The only way to know is to restore it somewhere disposable and look.
I've been thinking about this since two Postgres announcements landed on postgresql.org in the same week. BackupDrill is an open-source CLI for Supabase projects that restores each backup into a throwaway container. SafeGrd does a similar thing as a service. Two separate projects shipping the same idea in a week tells me a lot of people are tired of finding out about broken backups on the worst possible day. I haven't used either one yet. What follows is the DIY version I'd build first, so you can judge what the tools add.
What a green pg_dump actually proves
Not much. When pg_dump exits cleanly, you know it connected, read the catalogs, streamed table data, and wrote an archive to disk.…