From: | "Adam H(dot) Pendleton" <fmonkey(at)fmonkey(dot)net> |
---|---|
To: | mark(at)nsa(dot)co(dot)il |
Cc: | 'Dave Page' <dpage(at)vale-housing(dot)co(dot)uk>, pgadmin-support(at)postgresql(dot)org |
Subject: | Re: Keep-alive? |
Date: | 2003-10-08 14:01:29 |
Message-ID: | 3F8418B9.5080408@fmonkey.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgadmin-support |
Mark Rappoport wrote:
>Hi Dave, thanks for the swift reply.
>
>No, we're working on a server in a farm; the local office connection is
>a regular ADSL one, going through a Cisco PIX. The farm is about 4 hops
>away.
>I suppose that the PIX is somehow affecting the connection... There's
>probably a multitude of factors affecting this, and I doubt that it's
>the fault of the database backend or pgAdmin...
>
>Regardless, I think that PGAdmin should offer some kind of option to
>automagically reconnect if it sees that the connection is no longer
>alive.
>
>Perhaps there are other pgAdmin users experiencing such disconnections,
>who would benefit from this?
>
>Anyway, thanks. I'll look into the TCP streams heading in and out of
>here and see what's causing this.
>
>
Obviously I don't know what is specifically causing your connection
problems, but I can talk about this in the general sense. I also have a
similar problem connecting to my servers from my new work network.
Existing sessions timeout after a couple of minutes or so. The timeout
is transparent to the server end, and on my end I get a FIN/ACK which
appears to come from the remote machine, but must come from some gateway
here, because the remote machine has no idea the connection is dropped.
In my instance KeepAlives inside SSH have no effect, and the connection
still drops. Sending data down the connection will keep it alive, though.
A problem to consider with pgAdmin automatically re-opening connections
with the server is this: the server has no idea the connection has been
dropped, so it will keep it open until a TCP timeout occurs (which in my
experience is a *very* long time). Since the server keeps these
connections open, any new connections opened will decrease the number of
available non-superuser connections to the database. After a few
timeouts, you will no longer be able to connect to your database. Bad
news!! This happens quite a bit with my IMAP server which only allows 4
connections from the same IP address. On this new work network, if the
IMAP connections get closed by the firewall (this is an assumption since
I have no idea what sort of firewall/gateway is in use here -- the
Internet line is run by a separate company than mine), when my IMAP
application attemps to open some more, it can no longer make an IMAP
connection to the server, since the server rejects the new connections
(> 4). This means that I have to restart my IMAP server severeal times
a day, a big pain to say the least.
Network problems like this are usually better solved somewhere other
than the application, since their impact usually affects more than just
one application.
ahp
From | Date | Subject | |
---|---|---|---|
Next Message | Andreas Pflug | 2003-10-08 14:33:19 | Re: Keep-alive? |
Previous Message | Dave Page | 2003-10-08 13:08:44 | Re: Keep-alive? |