Re: Progress reporting for pg_verify_checksums

Alvaro Herrera <alvherre@2ndquadrant.com>

From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: Fabien COELHO <coelho@cri.ensmp.fr>
Cc: Michael Banck <michael.banck@credativ.de>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2018-09-03T14:21:32Z
Lists: pgsql-hackers
On 2018-Sep-01, Fabien COELHO wrote:

> > If -P was forgotten and pg_verify_checksums operates on a large cluster,
> > the caller can send SIGUSR1 to pg_verify_checksums to turn progress
> > status reporting on during runtime.
> 
> Hmmm. I cannot say I like the signal feature much. Would it make sense for
> the progress to be on by default, and to have a quiet option instead?

Hmm, I recall this technique being used elsewhere and is sometimes
useful.  Can't remember where though -- by manpages, it's not rsync nor
pv ...

How about making it a toggle?  Default off, enable-able by option,
toggleable by signal.  (If you enable it via the signal, what's the rate
to report at?)

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


Commits

  1. Add progress reporting to pg_checksums

  2. Fix thinko when bumping on temporary directories in pg_verify_checksums

  3. Fix thinko when bumping on temporary directories in pg_checksums