[LRUG] Backing up Postgres

Tim Cowlishaw tim at timcowlishaw.co.uk
Thu Jan 29 01:59:21 PST 2015

Aha, sorry - didn't read your message closely enough! In that case,
you might get some mileage out of backing up the posgres data dir at
the filesystem level periodically, and duplicating the write-ahead log
to replay any transactions since the last FS backup? This approach is
described here, I'm afraid I can't claim to have any first-hand
experience of it though:

On 29 January 2015 at 09:52, Andrew Stewart <boss at airbladesoftware.com> wrote:
> On 29 Jan 2015, at 10:50, Tim Cowlishaw <tim at timcowlishaw.co.uk> wrote:
>> Aha! I have a script for exactly this: it's nothing fancy, but it will
>> take a backup, compress it, and rotate the last n backups. Could
>> trivially be extended to send them to S3 too:
>> https://gist.github.com/timcowlishaw/d8734bbaa4c9e85a8a24
> Thanks!  But as far as I can tell it doesn't do incremental backups.  I wouldn't want to hit the database every few minutes for a full dump...
> Cheers,
> Andy

More information about the Chat mailing list