From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Vyacheslav Kalinin <vka(at)mgcp(dot)com> |
Cc: | Fernando Hevia <fhevia(at)ip-tel(dot)com(dot)ar>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: pg_toast_temp_xx AND pg_temp_xx SCHEMAS |
Date: | 2009-03-10 23:58:41 |
Message-ID: | 17251.1236729521@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Vyacheslav Kalinin <vka(at)mgcp(dot)com> writes:
>> They're just there to hold temporary tables (so that the names of such
>> tables don't conflict with any non-temporary tables). The reason they
>> seem to accumulate is we only create one when needed, and there's one
>> for each concurrently executing backend if it creates any temp tables.
> Hm, do they get garbage-collected in any way? I have several such schemes
> that won't disappear even though no other sessions but one is there.
No, that would just be a waste of cycles since they'll be needed again
eventually. The steady-state situation should be that you have
max_connections of them, more or less, if you ever get up to
max_connections live connections.
> On a side note: I can drop temporary tables of other sessions via "DROP
> pg_temp_xx.table" (although I can't seem to affect table data seen from
> other session). Is there any security issues/gotchas here?
If you can do that without being superuser, I'd take an interest.
Otherwise the answer is "don't do that".
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2009-03-11 00:24:44 | Re: tsearch2 dictionary for statute cites |
Previous Message | Piotre Ugrumov | 2009-03-10 23:36:36 | Re: Enable user access from remote host |