From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com> |
Cc: | Peter <pmc(at)citylink(dot)dinoex(dot)sub(dot)org>, pgsql-general(at)lists(dot)postgresql(dot)org |
Subject: | Re: Something else about Redo Logs disappearing |
Date: | 2020-06-09 05:27:20 |
Message-ID: | 2191826.1591680440@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com> writes:
> On 6/8/20 7:33 PM, Peter wrote:
>> That "cp" is usually not synchronous. So there is the possibility
>> that this command terminates successfully, and reports exitcode zero
>> back to the Postgres, and then the Postgres will consider that log
>> being safely away.
> Which is why just following the above command in the docs is:
> "(This is an example, not a recommendation, and might not work on all
> platforms.) "
Yeah. There have been discussions about changing that disclaimer to be
more forceful, because in point of fact a plain "cp" is generally not safe
enough. You need to fsync the written file, and on many filesystems you
also have to fsync the directory it's in.
> Generally for peace of mind folks use third party tools like:
+1. Rolling your own archive script is seldom advisable.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Paul Förster | 2020-06-09 05:59:13 | Re: troubleshooting postgresql ldap authentication |
Previous Message | Adrian Klaver | 2020-06-09 04:21:47 | Re: Something else about Redo Logs disappearing |