Re: Postgres restart in the middle of exclusive backup and the presence of backup_label file

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Stephen Frost <sfrost(at)snowman(dot)net>
Cc: David Steele <david(at)pgmasters(dot)net>, Nathan Bossart <nathandbossart(at)gmail(dot)com>, Chapman Flack <chap(at)anastigmatix(dot)net>, pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Postgres restart in the middle of exclusive backup and the presence of backup_label file
Date: 2022-04-05 16:42:47
Message-ID: CABUevEya5yL0S5JrLp3MSzoQMTmqWGyNd_q8k6bEMoXjK9BBNA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Apr 5, 2022 at 5:25 PM Stephen Frost <sfrost(at)snowman(dot)net> wrote:

> Greetings,
>
> * David Steele (david(at)pgmasters(dot)net) wrote:
> > On 4/4/22 11:42 AM, Nathan Bossart wrote:
> > >I noticed a couple of other things that can be removed. Since we no
> longer
> > >wait on exclusive backup mode during smart shutdown, we can change
> > >connsAllowed (in postmaster.c) to a boolean and remove CAC_SUPERUSER.
> We
> > >can also remove a couple of related notes in the documentation. I've
> done
> > >all this in the attached patch.
> >
> > These changes look good to me. IMV it is a real bonus how much the state
> > machine has been simplified.
>
> Yeah, agreed.
>

Definitely.

> > I've also run this patch through the pgbackrest regression tests without
> any
> > problems.
>
> Fantastic.
>
> Please find attached an updated patch + commit message. Mostly, I just
> went through and did a bit more in terms of updating the documentation
> and improving the comments (there were some places that were still
> worrying about the chance of a 'stray' backup_label file existing, which
> isn't possible any longer), along with some additional testing and
> review. This is looking pretty good to me, but other thoughts are
> certainly welcome. Otherwise, I'm hoping to commit this tomorrow.
>

+1. LGTM.

I'm not sure I love the renaming of the functions, but I have also yet to
come up with a better idea for how to avoid silent breakage, so go with it.

--
Magnus Hagander
Me: https://www.hagander.net/ <http://www.hagander.net/>
Work: https://www.redpill-linpro.com/ <http://www.redpill-linpro.com/>

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Geoghegan 2022-04-05 16:45:30 Re: Removing more vacuumlazy.c special cases, relfrozenxid optimizations
Previous Message Imseih (AWS), Sami 2022-04-05 16:42:28 Re: Add index scan progress to pg_stat_progress_vacuum