From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Robert Haas <robertmhaas(at)gmail(dot)com> |
Cc: | Gilles Darold <gilles(dot)darold(at)dalibo(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Patch to implement pg_current_logfile() function |
Date: | 2016-03-10 15:26:47 |
Message-ID: | 1315.1457623607@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> On Wed, Mar 9, 2016 at 12:32 PM, Gilles Darold <gilles(dot)darold(at)dalibo(dot)com> wrote:
>> I choose to allow the log collector to write his current log file name
>> into the lock file 'postmaster.pid'.
> Gosh, why? Piggybacking this on a file written for a specific purpose
> by a different process seems like making life very hard for yourself,
> and almost certainly a recipe for bugs.
That's a *complete* nonstarter. postmaster.pid has to be written by the
postmaster process and nobody else.
It's a particularly bad choice for the syslogger, which will exist
fractionally longer than the postmaster, and thus might be trying to write
into the file after the postmaster has removed it.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Simon Riggs | 2016-03-10 15:30:05 | Re: Add generate_series(date,date) and generate_series(date,date,integer) |
Previous Message | Petr Jelinek | 2016-03-10 15:26:41 | Re: Reworks of CustomScan serialization/deserialization |