From: Tom Lane <tgl@sss.pgh.pa.us>
To: James Farrugia <james.farrugia@gmail.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Orphan TOAST object
Date: Sun, 11 May 2008 13:09:48 -0400
Message-ID: <20553.1210525788@sss.pgh.pa.us> (raw)
In-Reply-To: <8d01be800805110946r792efacdp3dbe02829b6da7a9@mail.gmail.com>
References: <8d01be800805110946r792efacdp3dbe02829b6da7a9@mail.gmail.com>
"James Farrugia" <james.farrugia@gmail.com> writes:
> I wonder whether any of you can help me out with this problem.
What PG version is this?
> To get vacuum the TOAST object we created a temporary table foo (col1
> char(1)) and assigned its reltoastrelid (up till now set to 0) to
> pg_toast_35027430's OID and then vacuumed foo. The plan worked and
> immediately age(datfrozenxid) in pg_database reflected a much younger XID.
> We then decided to get rid of pg_toast_35027430 by dropping foo. Foo
> disappeared but pg_toast_35027430 persisted.
Well, yeah, because you didn't create a pg_depend link.
We have seen a couple prior reports of toast tables not going away when
their parent was dropped, but nobody's been able to create a
reproducible case yet. The most likely idea is probably that pg_depend
got corrupted somehow, causing the toast table not to get found by DROP.
Can you find any rows in pg_depend having objid equal to the OID of
pg_toast_35027430? Try reindexing pg_depend and then see if you find
any.
regards, tom lane
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 using the --to and --cc options:
reply via email
To: pgsql-admin@postgresql.org
Cc: tgl@sss.pgh.pa.us, james.farrugia@gmail.com
Subject: Re: Orphan TOAST object
In-Reply-To: <20553.1210525788@sss.pgh.pa.us>
* 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