Reasons for not overwriting processed wal archives?

Поиск
Список
Период
Сортировка
От Koen De Groote
Тема Reasons for not overwriting processed wal archives?
Дата
Msg-id CAGbX52EgQ2_3pSTDybkH2HTmn3pXJbEo1Gg6aC2cqqVJ2otJ=Q@mail.gmail.com
обсуждение исходный текст
Ответы Re: Reasons for not overwriting processed wal archives?  ("David G. Johnston" <david.g.johnston@gmail.com>)
Список pgsql-general

States:

> It is advisable to test your proposed archive command to ensure that it indeed does not overwrite an existing file, and that it returns nonzero status in this case.

Why exactly is this?

Assuming a situation in which the files, as part of the archive_command, are gzipped to their final location.

If the gzip fails, or stops halfway, perhaps due to a network issue... you're left with a file that isn't the full representation of the wal archive.

So it needs to be done again.

In cases where the file is simply moved, this can also occur. Wal size can be configured, and transfers might fail.

So they'd have to be done again.

If we test first for a file with that name being present, and refusing to go forward if there is... an admin is going to have to manually intervene and delete the half-finished file.

So isn't it better to just overwrite?

What scenario am I missing here?

Regards,
Koen

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

Предыдущее
От: Koen De Groote
Дата:
Сообщение: In case of network issues, how long before archive_command does retries
Следующее
От: "David G. Johnston"
Дата:
Сообщение: Re: Reasons for not overwriting processed wal archives?