Re: Backups with filesystem snapshots - Mailing list pgsql-general

From Greg Sabino Mullane
Subject Re: Backups with filesystem snapshots
Date
Msg-id CAKAnmmLnSxW6ER0AXn9GxfL=84RWcei_7q2bPwieNyM+SS6mTQ@mail.gmail.com
Whole thread Raw
In response to Backups with filesystem snapshots  (Nick Cleaton <nick@cleaton.net>)
Responses Re: Backups with filesystem snapshots
List pgsql-general
On Mon, Aug 11, 2025 at 9:01 AM Nick Cleaton <nick@cleaton.net> wrote:
If I take an instantaneous filesystem-level snapshot of the postgres
data directory underneath a running postgres server, is that a safe
backup without doing any pg_start_backup/pg_stop_backup ?

Safe, yes[*], but not particularly recommended except for special cases, like spinning up a fast QA cluster. For backups, use a Postgres-aware battle tested system like pgBackRest that offers more flexibility and more safeguards.

* Assuming your hardware/OS drivers are being honest with you about fsync

starting up from that snapshot should look the same as recovering from an unclean postgres shutdown
due to a kernel panic.

Yes, for all practical purposes it would be identical. Technically more similar to pulling the plug on the server. :)

Cheers,
Greg

--
Enterprise Postgres Software Products & Tech Support

pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: Bitnami deprecation
Next
From: Greg Sabino Mullane
Date:
Subject: Re: Inquiry: Using PostgreSQL as a Staging Database for SAP ERP Data Export