Re: [GENERAL] IDLE queries taking up space

2011-08-31 Thread Craig Ringer
On 31/08/2011 12:03 AM, JD Wong wrote: Hi, When I run select datname, procpid, current_query from pg_stat_activity; I get 26 rows of queries. How can I set postgres to qutomatically close connections that have finished their queries and now sit idle? If they're not idle in transaction, th

Re: [GENERAL] IDLE queries taking up space

2011-08-30 Thread Merlin Moncure
On Tue, Aug 30, 2011 at 11:03 AM, JD Wong wrote: > Hi, > When I run select datname, procpid, current_query from pg_stat_activity; I > get 26 rows of queries.  How can I set postgres to qutomatically > close connections that have finished their queries and now sit idle? you don't. this should be

Re: [GENERAL] IDLE queries taking up space

2011-08-30 Thread Rodrigo Gonzalez
On 08/30/2011 02:13 PM, Scott Ribe wrote: On Aug 30, 2011, at 10:03 AM, JD Wong wrote: How can I set postgres to qutomatically close connections that have finished their queries and now sit idle? AFAIK you can't, you should check |pg_terminate_backend function and see if it is useful for you

Re: [GENERAL] IDLE queries taking up space

2011-08-30 Thread Scott Ribe
On Aug 30, 2011, at 10:03 AM, JD Wong wrote: > How can I set postgres to qutomatically close connections that have finished > their queries and now sit idle? They haven't finished their queries. They've opened transactions, and then are sitting there doing nothing. In other words, this is a bug

[GENERAL] IDLE queries taking up space

2011-08-30 Thread JD Wong
Hi, When I run select datname, procpid, current_query from pg_stat_activity; I get 26 rows of queries. How can I set postgres to qutomatically close connections that have finished their queries and now sit idle? Thanks! -JD