Re: [TODO] Track number of files ready to be archived in pg_stat_archiver

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: [TODO] Track number of files ready to be archived in pg_stat_archiver
Дата
Msg-id CAB7nPqQ+ERa1dpjwqJA4cve6rKS1228xoQvHzaYtT-sCwNVv1w@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [TODO] Track number of files ready to be archived in pg_stat_archiver  (Simon Riggs <simon@2ndQuadrant.com>)
Ответы Re: [TODO] Track number of files ready to be archived in pg_stat_archiver  (Simon Riggs <simon@2ndQuadrant.com>)
Список pgsql-hackers
On Tue, Nov 18, 2014 at 5:47 AM, Simon Riggs <simon@2ndquadrant.com> wrote:
> On 21 August 2014 09:17, Julien Rouhaud <julien.rouhaud@dalibo.com> wrote:
>
>> Track number of WAL files ready to be archived in pg_stat_archiver
>
> Would it be OK to ask what the purpose of this TODO item is?
>
> pg_stat_archiver already has a column for last_archived_wal and
> last_failed_wal, so you can already work out how many files there must
> be between then and now. Perhaps that can be added directly to the
> view, to assist the user in calculating it. Reading the directory
> itself to count the file is unnecessary, except as a diagnostic.
Not sure if this holds true in a node freshly started from a base
backup with a set of WAL files, or with files manually copied by an
operator.

> Please don't take "it is a TODO item" as "generally accepeted that
> this makes sense".
On systems where the WAL archiving is slower than WAL generation at
peak time, the DBA may want to know how long is the queue of WAL files
waiting to be archived. That's IMO something we simply forgot in the
first implementation of pg_stat_archiver, and the most direct way to
know that is to count the .ready files in archive_status.
-- 
Michael



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

Предыдущее
От: Kouhei Kaigai
Дата:
Сообщение: Re: using custom scan nodes to prototype parallel sequential scan
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: [TODO] Track number of files ready to be archived in pg_stat_archiver