I wrote:
> I think we have a suspect --- will go look.

Jeff, are you doing CLUSTER operations too?

Some preliminary testing says that:

7.4:
CLUSTER leaks a pg_temp_nnn relcache entry per call; if table
  has toast subtable it also leaks a pg_toast_nnn_index entry per call
TRUNCATE on a table with toast leaks a pg_toast_nnn_index entry per call

8.0:
CLUSTER on a table with toast leaks a pg_toast_nnn_index entry per call

Since you showed both pg_temp_nnn and pg_toast_nnn_index items in your
dump, I surmise that there must be a fair number of CLUSTERs going on.

This is probably all actually just one bug --- 7.4's TRUNCATE used the
CLUSTER mechanism while 8.0 doesn't, so that explains why TRUNCATE isn't
showing a leak anymore.  CLUSTER got whacked around too, but it looks
like we only cured half the leak :-(

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

               http://www.postgresql.org/docs/faq

Reply via email to