Re: WAL Archiving and base backup

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: WAL Archiving and base backup
Дата
Msg-id CAKFQuwYL65Sge1sX8gASvC0FPz-nvqFE25ngOvdiBvXfV+cxMQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: WAL Archiving and base backup  (Stephen Frost <sfrost@snowman.net>)
Ответы Re: WAL Archiving and base backup  (Stephen Frost <sfrost@snowman.net>)
Список pgsql-general
On Fri, Jan 14, 2022 at 11:31 AM Stephen Frost <sfrost@snowman.net> wrote:
Greetings,

* Issa Gorissen (issa-gorissen@usa.net) wrote:
> Thx a lot. I thought about it but was not so sure about having a complex
> script (compared to the very simple version when using the exclusive backup
> - but this this is deprecated...).
>
> I will test your option with the simpler version and post it back to it can
> maybe land in PostgreSQL documentation.

The PG docs show how the command works and that's it.  The commands
in the docs aren't intended to be actually used in production
environments.  Writing a full solution involves having a good
understanding of the PG code and how WAL archiving, backups, et al, are
done.

For all my suggestions of "use third-party where possible" I do think that we should have, probably as part of pg_basebackup, a mode that performs a filesystem copy of WAL to an archive location and verifies that the archive is valid otherwise it write to the PostgreSQL log that there was a problem.  pg_basebackup should either be able to install that command (with maybe some CLI prompts for settings or something) using ALTER SYSTEM.  Our documentation can then demonstrate the example usage of the archive_command parameters as being a generic form of that command.

i.e., pg_backbackup --wal-archive-location /path/to/dir/ --wal_to_archive $1

David J.

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

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: WAL Archiving and base backup
Следующее
От: R Batchen
Дата:
Сообщение: How to debug incomplete message on postgres 12.3 docker