Re: Writing WAL files

From: Robert Inder <robert(at)interactive(dot)co(dot)uk>
To: Michael Lewis <mlewis(at)entrata(dot)com>, Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
Cc: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Writing WAL files
Date: 2020-10-05 19:23:49
Message-ID: CAKqjJm_kiw6Nim09w1VCe7ZaREw_EpJZgasxs6q9cYXFYQu4vA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Mon, 5 Oct 2020 at 18:29, Michael Lewis <mlewis(at)entrata(dot)com> wrote:

>
> If you setup a scripted process to update a single row with a timestamptz
> on the source/primary every minute, then you have a very simple consistent
> change and also a way to check on the replica what is current time vs
> last_scripted_update_time if you will and know the approx lag. It would
> seem like a simple albeit hacky solution to you wanting a file every X
> minutes regardless of server activity.
>

I'd thought of going half way to that, and just have a cron job for
psql -c 'CHECKPOINT'
which doesn't give me the quantitative indication I'd get from updating a
timestamp, but doesn't commit me to know about any particular database,
either.

The thing that I find most disconcerting is that the documentation for
Version 12 says checkpoint_timeout is
"Maximum time between automatic WAL checkpoints"

But the change Adrian Klaverd highlighted suggests that this is
deliberately no longer the case,
and I am left wondering what it does, in fact do/mean now.

By the by, top-posting (reply above all quoted text) is discouraged on
> these groups.
>

Indeed. Once upon a time, my signature use to be along the lines of

So what? It's easier for me, so I'll do it!

> > What's wrong with top posting?
> It makes it hard to see comments in context.

Robert.

--
Robert Inder, 0131 229 1052 / 07808 492
213
Interactive Information Ltd, 3, Lauriston Gardens, Edinburgh EH3 9HH
Registered in Scotland, Company no. SC 150689
Interactions speak louder than
words

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message James B. Byrne 2020-10-05 19:30:01 Re: UUID generation problem
Previous Message Adrian Klaver 2020-10-05 19:20:02 Re: UUID generation problem