Re: pg_standby -l might destory the archived file

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема Re: pg_standby -l might destory the archived file
Дата
Msg-id 4A24260F.5020902@enterprisedb.com
обсуждение исходный текст
Ответ на Re: pg_standby -l might destory the archived file  (Aidan Van Dyk <aidan@highrise.ca>)
Ответы Re: pg_standby -l might destory the archived file  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Aidan Van Dyk wrote:
> * Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> [090601 10:56]:
>> Tom Lane wrote:
>>> Fujii Masao <masao.fujii@gmail.com> writes:
>>>> pg_standby can use ln command to restore an archived file,
>>>> which might destroy the archived file as follows.
>>> Does it matter?  pg_standby's source area wouldn't normally be an
>>> "archive" in the real sense of the word, it's just a temporary staging
>>> area between master and slave.  (If it were being used as a real
>>> archive, keeping it on the same disk as the live slave seems pretty
>>> foolish anyway, so the case wouldn't arise.)
>> It seems perfectly sane to source pg_standby directly from the archive  
>> to me. And we're talking about symbolic linking, so the archive  
>> directory might well be on an NFS mount.
> 
> I would expect that any archive directly available would at least be RO
> to the postgres slave... But....

Me too.

I wonder if we should just remove the symlink option from pg_standby. 
Does anyone use it? Is there a meaningful performance difference?

> Something like this would stop the "symlink" being renamed... Not portable, but probably portable
> across platforms that have symlinks...
>     diff --git a/src/backend/access/transam/xlog.c b/src/backend/access/transam/xlog.c

That seems reasonable as well.

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: search_path vs extensions
Следующее
От: Kevin Field
Дата:
Сообщение: Re: plperl error format vs plpgsql error format vs pgTAP