Idle session timeout?

From: Sean Murphy <Sean(dot)Murphy(at)equipoint(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Idle session timeout?
Date: 2007-05-08 16:45:09
Message-ID: 4640A915.5030001@equipoint.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I've got a bunch of users on VB applications connecting to PG 8.2.3 via
psqlodbc with SSL. For a variety of reasons, some good, some probably
bad, I have the app open a connection and leave it open, using it as
needed to run queries back and forth.

If I look in my logs, I see loans of little clusters of entries like this:
2007-05-08 08:44:57 PDT-xxxx(at)yyy(dot)yyy(dot)yyy(dot)yyy LOG: SSL SYSCALL error:
Connection reset by peer
2007-05-08 08:44:57 PDT-xxxx(at)yyy(dot)yyy(dot)yyy(dot)yyy LOG: could not receive
data from client: Connection reset by peer
2007-05-08 08:44:57 PDT-xxxx(at)yyy(dot)yyy(dot)yyy(dot)yyy LOG: unexpected EOF on
client connection

These seem to correspond to dropped connections for my users, generally
if a user with an open app that hasn't used it for a while attempts to
use it. I've put some code in to re-establish the connection to mitigate
user frustration, but it doesn't do much to mitigate my frustration.

I'm WAY out of my depth here, but my impression, based on the
circumstances, is that there is some sort of an idle session timeout
kicking in (most likely on the client side) and dropping the connection.
Judging by the error messages I'd be inclined to say that it's happening
in openSSL, not Postgres, but I don't know.

I've searched documentation and newsgroups for Postgres, psqlodbc, and
openSSL, and haven't found any user-settable timeout parameters. The one
thing I did come across that seemed to my clueless eyes to be relevant
was an OpenSSL API call: SSL_CTX_set_timeout(). Even assuming this is
relevant, wouldn't this be the kind of thing that would need to be
called by Postgres code at the point that SSL is integrated?

Anyway, I appreciate any help or guidance anyone might be able to give.
It would be awesome if there were a user parameter somewhere on the
server or client that someone could point out to me to take care of
this. If this is a bug, please help me figure out who it belongs to. If
this is a feature, please let me know so I can properly account for it
in my code.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Andreas Kretschmer 2007-05-08 16:57:58 Re: Spliting a string in plpgsql
Previous Message Jasbinder Singh Bali 2007-05-08 16:44:28 Spliting a string in plpgsql