Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kXlzH-0005iy-QU for pgsql-bugs@arkaria.postgresql.org; Wed, 28 Oct 2020 13:59:39 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1kXlzF-0005Bt-6X for pgsql-bugs@arkaria.postgresql.org; Wed, 28 Oct 2020 13:59:37 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kXlzF-0005Bm-0g for pgsql-bugs@lists.postgresql.org; Wed, 28 Oct 2020 13:59:37 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kXlz8-0004IQ-Hs for pgsql-bugs@lists.postgresql.org; Wed, 28 Oct 2020 13:59:35 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 09SDxOlI1251839; Wed, 28 Oct 2020 09:59:24 -0400 From: Tom Lane To: Alvaro Herrera cc: Michael Paquier , Tomas Vondra , exclusion@gmail.com, pgsql-bugs@lists.postgresql.org Subject: Re: BUG #16577: Segfault on altering a table located in a dropped tablespace In-reply-to: <20201028134045.GA6709@alvherre.pgsql> References: <20201028134045.GA6709@alvherre.pgsql> Comments: In-reply-to Alvaro Herrera message dated "Wed, 28 Oct 2020 10:40:45 -0300" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1251837.1603893564.1@sss.pgh.pa.us> Date: Wed, 28 Oct 2020 09:59:24 -0400 Message-ID: <1251838.1603893564@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Alvaro Herrera writes: > On 2020-Oct-28, Michael Paquier wrote: >> Haven't thought of that approach, good idea! That would not be >> backpatchable but that would be a solution that does not require >> creating files where we don't need them. Did you begin to look at >> that? > I haven't started on this one yet, but I intend to do so shortly. > Strictly speaking, we can still introduce a new category of pg_shdepend > entries in back branches; it won't break anything that works today. Yeah, as long as the patched version won't actively fail when those pg_shdepend entries are missing, I don't think a backpatch is too hazardous. It might be worth checking that the extra entries don't create huge problems if one does downgrade after some of them exist --- but my feeling for how that mechanism works is that it'd Just Work, and indeed provide the missing DROP protection even without explicit action by the backend. I would not be too excited about offering instructions for people to manually add/remove the dependency entries. The amount of value added, versus the risks of bollixing things completely, doesn't sound like a good tradeoff. regards, tom lane