Re: Proposal for Recover mode in pg_ctl (in 8.0)
От | Tom Lane |
---|---|
Тема | Re: Proposal for Recover mode in pg_ctl (in 8.0) |
Дата | |
Msg-id | 17989.1099786612@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: Proposal for Recover mode in pg_ctl (in 8.0) (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: Proposal for Recover mode in pg_ctl (in 8.0)
Re: Proposal for Recover mode in pg_ctl (in 8.0) |
Список | pgsql-hackers |
I wrote: > A possibly more reliable interlock would involve having the postmaster > probe during normal startup to see if there is already an archived WAL > segment for what it thinks is the current segment. Another and simpler way is to recommend that people use archive_command strings that won't overwrite an existing archive file. For instance instead of showing the example archive_command = 'cp %p /mnt/server/archivedir/%f' we could show archive_command = 'test ! -f /mnt/server/archivedir/%f && cp %p /mnt/server/archivedir/%f' or on some machines archive_command = 'cp -i %p /mnt/server/archivedir/%f </dev/null' One tricky point is to make sure that the command will return nonzero status if the target exists. In some quick testing I found that the "cp -i" method doesn't have portable behavior on this point. I think that the "test" method is portable across Unixen, but no idea what to do on Windows. regards, tom lane
В списке pgsql-hackers по дате отправления: