From: Adrian Klaver <adrian.klaver@aklaver.com>
To: Robert Inder <robert@interactive.co.uk>
To: pgsql-general@postgresql.org
Subject: Re: Writing WAL files
Date: Sun, 4 Oct 2020 10:01:24 -0700
Message-ID: <8bac1611-0476-d0ea-a6b6-c9266b6cc6b2@aklaver.com> (raw)
In-Reply-To: <CAKqjJm83gnw2u0ugpkgc4bq58L=cLwbvmh69TwKKo83Y1CnANw@mail.gmail.com>
References: <CAKqjJm83gnw2u0ugpkgc4bq58L=cLwbvmh69TwKKo83Y1CnANw@mail.gmail.com>
On 10/4/20 9:54 AM, Robert Inder wrote:
> I am moving a database from PSQL 9 (!) on CentOS 6 to PSQL 12 on CentOS 7
It would help to know what the x in 9.x is? Before version 10 of
Postgres, the second number denoted a major version.
>
> I have a pair of servers -- one live, one standby.
> The live server defines an archive_command as "rsync...." to shift WAL
> files to the standby server,
> The standby server uses "pg_standby" to monitor and process incoming WAL
> files.
> I believe this is all very vanilla, and indeed changes made in the live
> database are duly shipped to the standby.
>
> BUT...
>
> One of the things I like about the old PGSQL 9 setup is that it
> generates and ships a WAL file every few minutes, even if nothing has
> happened in the database.
> I find it re-assuring to be able to see WAL files arriving and being
> processed without problem even when the live system was idle.
>
> But I cannot get PGSQL 12 to do this. It only writes (and thus ships)
> WAL files when something happens in the database.
> If the database is idle, it simply does not write any WAL files.
>
> I thought I would get WAL files written from an idle database if, in
> postgresql.conf, I set "archive_timeout" to 120.
>
> And I've tried setting "checkpoint_timeout" to 90s,
>
> But to no avail. No WAL files are written unless the database changes.
>
> So what am I missing? How CAN I get postgresql 12 to write
> "unnecessary" WAL files every couple of minutes?
>
> 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
--
Adrian Klaver
adrian.klaver@aklaver.com
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: adrian.klaver@aklaver.com, robert@interactive.co.uk
Subject: Re: Writing WAL files
In-Reply-To: <8bac1611-0476-d0ea-a6b6-c9266b6cc6b2@aklaver.com>
References: <CAKqjJm83gnw2u0ugpkgc4bq58L=cLwbvmh69TwKKo83Y1CnANw@mail.gmail.com> <8bac1611-0476-d0ea-a6b6-c9266b6cc6b2@aklaver.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox