[GENERAL] Clearing out old idle connections

2006-05-24 Thread Gavin Hamill
Hullo :) We have pg 8.1.3 and for whatever reason (network blips, poor pooling on behalf of the client, etc.) we sometimes see a large number (dozens) of old connections in the idle state which never get reused. Is there a function in postgres similar to MySQL's 'wait_timeout' which

Re: [GENERAL] Clearing out old idle connections

2006-05-24 Thread Ivan Zolotukhin
Hello, We have pg 8.1.3 and for whatever reason (network blips, poor pooling on behalf of the client, etc.) we sometimes see a large number (dozens) of old connections in the idle state which never get reused. It seems that I have more or less the same problem. Sometimes I see in `ps aux`

Re: [GENERAL] Clearing out old idle connections

2006-05-24 Thread Richard Huxton
Gavin Hamill wrote: Hullo :) We have pg 8.1.3 and for whatever reason (network blips, poor pooling on behalf of the client, etc.) we sometimes see a large number (dozens) of old connections in the idle state which never get reused. They should expire based on your TCP/IP settings. It's a

Re: [GENERAL] Clearing out old idle connections

2006-05-24 Thread Florian G. Pflug
Richard Huxton wrote: Gavin Hamill wrote: Hullo :) We have pg 8.1.3 and for whatever reason (network blips, poor pooling on behalf of the client, etc.) we sometimes see a large number (dozens) of old connections in the idle state which never get reused. They should expire based on your

Re: [GENERAL] Clearing out old idle connections

2006-05-24 Thread Tom Lane
Florian G. Pflug [EMAIL PROTECTED] writes: You can (at least on linux, I assume it's the same for BSD) set the keepalive flag of a connection. This results in empty packets being sent every 30 seconds or so, and the connection is reported to be dead if no ACK is received within a timeout. I

Re: [GENERAL] Clearing out old idle connections

2006-05-24 Thread Scott Marlowe
On Wed, 2006-05-24 at 14:00, Tom Lane wrote: Florian G. Pflug [EMAIL PROTECTED] writes: You can (at least on linux, I assume it's the same for BSD) set the keepalive flag of a connection. This results in empty packets being sent every 30 seconds or so, and the connection is reported to be