Configure and maintain
Backup and recovery planning
Prepare and rehearse recovery before upgrading a deployment.
A database migration can make an older application image incompatible with the current data. The absence of a release-note warning does not establish that a downgrade is safe.
Stop external writers and pause incoming work before taking the consistency point. Keep PostgreSQL running during the dump. Confirm each command succeeds; a created file alone is not evidence of a successful backup. Resume the application only under your upgrade or cancellation plan.
For an embedded PGLite deployment, stop the application before copying its entire configured storage directory and configuration. PostgreSQL commands do not apply to PGLite.