[Gllug] DB connection / netstat wierdness

Daniel P. Berrange dan at berrange.com
Tue Feb 3 18:38:48 UTC 2004


On Tue, Feb 03, 2004 at 06:01:59PM +0000, Richard Huxton wrote:
> > If I look at the second app server which I rebooted with prejudice:
> >
> > app02# netstat -t -n -a |grep 5432 | grep 192.168.100.4 | wc -l
> >    0
> 
> Have you waited long enough for the TCP timeout to kick in here (usually 1 
> hour plus IIRC). PG should notice the disconnect after TCP tells it the 
> connection is gone.

You know, I thought I had but it turns out the default keepalive timeout
is 2 hours on Linux. Rather more than is desirable when you're trying to
bring back up an app servers after a crash. I'm going to tune
/proc/sys/net/ipv4/tcp_keepalive_time to be 10 minutes instead and 
see how it goes.

Dan.
-- 
|=-               http://www.berrange.com/~dan/gpgkey.txt             -=|
|=-   berrange at redhat.com  -  Daniel Berrange  -  dan at berrange.com    -=|
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 240 bytes
Desc: not available
URL: <http://mailman.lug.org.uk/pipermail/gllug/attachments/20040203/92b9aee7/attachment.pgp>
-------------- next part --------------
-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug


More information about the GLLUG mailing list