Re: PITR and tar - Mailing list pgsql-general

From Jim Nasby
Subject Re: PITR and tar
Date
Msg-id 8C4728BC-E2DE-4E99-813A-3A15C3F97A80@decibel.org
Whole thread Raw
In response to PITR and tar  (Jeff Davis <pgsql@j-davis.com>)
Responses Re: PITR and tar
List pgsql-general
On May 7, 2007, at 1:58 PM, Jeff Davis wrote:
> Second, it seems that it can cause a bad backup to occur if you
> pass the
> "z" option to tar. Instead, piping the output of tar through the
> compression program seems to avoid that problem (i.e. "tar cf - ... |
> gzip > ..."). I am using FreeBSD's tar, other implementations may be
> different.

What *exactly* are you seeing there? If anything -z should be safer
than piping through gzip, since you could easily accidentally pipe
stderr through gzip as well, which *would* corrupt the backup.

> Are my observations correct, and if so, should they be documented as a
> potential "gotcha" when making base backups?

I believe the bit about tar complaining about changed files is
already in there, no?
--
Jim Nasby                                            jim@nasby.net
EnterpriseDB      http://enterprisedb.com      512.569.9461 (cell)



pgsql-general by date:

Previous
From: Andrew Sullivan
Date:
Subject: Re: Dangers of fsync = off
Next
From: Jim Nasby
Date:
Subject: Re: Continuous Archiving for Multiple Warm Standby Servers