From: Phil Endecott <spam_from_pgsql_lists@chezphil.org>
To: pgsql-general@lists.postgresql.org
Subject: Re: Why can't I drop a tablespace?
Date: Wed, 14 Jul 2021 13:17:05 +0100
Message-ID: <1626265025382@dmwebmail.dmwebmail.chezphil.org> (raw)
In-Reply-To: <2949871.1626102784@sss.pgh.pa.us>
References: <2949871.1626102784@sss.pgh.pa.us>
Tom Lane wrote:
> "Phil Endecott" <spam_from_pgsql_list@chezphil.org> writes:
>> Thanks Laurenz. I was looking at the source for "alter table set
>> tablespace" yesterday trying to work out what is supposed to happen.
>> There is a comment at tablecmds.c line 3989: "Thanks to the magic of
>> MVCC, an error anywhere along the way rolls back the whole operation;
>> we don't have to do anything special to clean up." But I guess that
>> creating an entirely new file on a different filesystem is an
>> exception to that.
>
> No, but PANIC'ing during commit is :-(. Ordinarily the files created by a
> failed transaction would be removed during transaction cleanup, but we
> did not reach that code. So these were left behind, but the table's
> original files in the original tablespace should be undamaged.
OK, I've removed them - fingers crossed!
Thanks to everyone who replied for your advice.
Regards, Phil.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: spam_from_pgsql_lists@chezphil.org
Subject: Re: Why can't I drop a tablespace?
In-Reply-To: <1626265025382@dmwebmail.dmwebmail.chezphil.org>
References: <2949871.1626102784@sss.pgh.pa.us> <1626265025382@dmwebmail.dmwebmail.chezphil.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox