Re: recovering from "found xmin ... from before relfrozenxid ..."

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: recovering from "found xmin ... from before relfrozenxid ..."
Date: 2020-07-14 08:59:45
Message-ID: CABUevEw9cR8W7waLVcU15cW3xpw1pV2ZyHUuHrBfK-enLJqsJA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Jul 14, 2020 at 3:26 AM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:

> Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> > On Mon, Jul 13, 2020 at 8:58 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> >> The more that I think about it, the more I think that the proposed
> >> functions are tools for wizards only, and so I'm getting hesitant
> >> about having them in contrib at all. We lack a better place to
> >> put them, but that doesn't mean they should be there.
>
> > I understand that it's not too great when we give people access to
> > sharp tools and they hurt themselves with said tools. But this is open
> > source. That's how it goes.
>
> I think you're attacking a straw man. I'm well aware of how open source
> works, thanks. What I'm saying is that contrib is mostly seen to be
> reasonably harmless stuff. Sure, you can overwrite data you didn't want
> to with adminpack's pg_file_write. But that's the price of having such a
> capability at all, and in general it's not hard for users to understand
> both the uses and risks of that function. That statement does not apply
> to the functions being proposed here. It doesn't seem like they could
> possibly be safe to use without very specific expert advice --- and even
> then, we're talking rather small values of "safe". So I wish we had some
> other way to distribute them than via contrib.
>

The countersable of this is pg_resetwal. The number of people who have
broken their database with that tool is not small.

That said, we could have a separate "class" of extensions/tools in the
distribution, and encourage packagers to pack them up as separate packages
for example. Technically they don't have to be in the same source
repository at all of course, but I have a feeling some of them might be a
lot easier to maintain if they are. And then the user would just have to
install something like "postgresql-14-wizardtools". They'd still be
available to everybody, of course, but at least the knives would be in a
closed drawer until intentionally picked up.

--
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

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Julien Rouhaud 2020-07-14 09:08:08 Re: Online checksums verification in the backend
Previous Message Bharath Rupireddy 2020-07-14 08:41:29 Re: Issue with cancel_before_shmem_exit while searching to remove a particular registered exit callbacks