Re: backup manifests

From: Stephen Frost <sfrost(at)snowman(dot)net>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Suraj Kharage <suraj(dot)kharage(at)enterprisedb(dot)com>, tushar <tushar(dot)ahuja(at)enterprisedb(dot)com>, Rajkumar Raghuwanshi <rajkumar(dot)raghuwanshi(at)enterprisedb(dot)com>, Rushabh Lathia <rushabh(dot)lathia(at)gmail(dot)com>, Tels <nospam-pg-abuse(at)bloodgate(dot)com>, David Steele <david(at)pgmasters(dot)net>, Andrew Dunstan <andrew(dot)dunstan(at)2ndquadrant(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Jeevan Chalke <jeevan(dot)chalke(at)enterprisedb(dot)com>, vignesh C <vignesh21(at)gmail(dot)com>
Subject: Re: backup manifests
Date: 2020-03-27 22:24:31
Message-ID: 20200327222430.GO13712@tamriel.snowman.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Greetings,

* Andres Freund (andres(at)anarazel(dot)de) wrote:
> On 2020-03-27 16:57:46 -0400, Stephen Frost wrote:
> > I really don't know what to say to this. WAL is absolutely critical to
> > a backup being valid. pgBackRest doesn't have a way to *just* validate
> > a backup today, unfortunately, but we're planning to support it in the
> > future and we will absolutely include in that validation checking all of
> > the WAL that's part of the backup.
>
> Could you please address the fact that just about everybody uses base
> backups + later WAL to have a short data loss window? Integrating the
> WAL files necessary to make the base backup consistent doesn't achieve
> much if we can't verify the WAL files afterwards. And fairly obviously
> pg_basebackup can't do much about WAL created after its invocation.

I feel like we have very different ideas about what "just about
everybody" does here. In my view, folks use pg_basebackup because it's
easy and they can create self-contained backups that include all the WAL
needed to get the backup up and running again and they don't typically
care about PITR all that much. Folks who care about PITR use something
that manages WAL for them, which pg_basebackup and pg_receivewal really
don't do and it's not easy to add scripting around them to figure out
what WAL is needed for what backup, etc.

If we didn't think that the ability to create a self-contained backup
was useful, it sure seems odd that we've done a lot to make that work
(having both fetch and stream modes for it) and that it's the default.

> Given that we need something separate to address that "verification
> hole", I don't see why it's useful to have a special case solution (or
> rather multiple ones, for stream and fetch) inside pg_basebackup.

Well, the proposal up-thread would end up with almost zero changes to
pg_basebackup itself, but, yes, there'd be changes to BASE_BACKUP and
different ones for STREAMING_REPLICATION to support getting the WAL
checksums into the manifest.

Thanks,

Stephen

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Fabien COELHO 2020-03-27 22:25:58 Re: pgbench - rework variable management
Previous Message Alvaro Herrera 2020-03-27 22:17:00 Re: backup manifests