Re: BUG #17212: pg_amcheck fails on checking temporary relations

Peter Geoghegan <pg@bowt.ie>

From: Peter Geoghegan <pg@bowt.ie>
To: Mark Dilger <mark.dilger@enterprisedb.com>
Cc: Robert Haas <robertmhaas@gmail.com>, Pavel Borisov <pashkin.elfe@gmail.com>, Alexander Lakhin <exclusion@gmail.com>, PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2021-10-11T18:40:34Z
Lists: pgsql-bugs, pgsql-hackers
On Mon, Oct 11, 2021 at 11:26 AM Mark Dilger
<mark.dilger@enterprisedb.com> wrote:
> That's fine by me, but I was under the impression that people wanted the extraneous noise removed.

A NOTICE message is supposed to be surfaced to clients (but not stored
in the server log), pretty much by definition.

It's not unreasonable to argue that I was mistaken to ever think that
about this particular message. In fact, I suspect that I was.

> Since pg_amcheck can know the command is going to draw a "you can't check that right now" type message, one might argue that it is drawing these notices for no particular benefit.

But technically it *was* checked. That's how I think of it, at least.
If a replica comes out of recovery, and we run pg_amcheck immediately
afterwards, are we now "checking it for real"? I don't think that
distinction is meaningful.

> Somebody could quite reasonably complain about this on a hot standby with millions of unlogged relations.  Actual ERROR messages might get lost in all the noise.

That's a good point.

-- 
Peter Geoghegan



Commits

  1. Remove unstable pg_amcheck tests.

  2. pg_amcheck: avoid unhelpful verification attempts.

  3. amcheck: Skip unlogged relations in Hot Standby.

  4. amcheck: Skip unlogged relations during recovery.