Tom Lane wrote:
>
> Stefan Loidl <Stefan.Loidl@lrz-muenchen.de> writes:
> > is there a connection timeout in postgres?
> > It seems to me that connections that are idle for about a day,
> > are closed automatically by the corresponding postmaster process
> > and the process exits.
>
> No such mechanism in Postgres itself, but perhaps you are seeing the
> effects of some timeout in your TCP stack.
I've just got a connection to a database on the same host and
I'm starting the postmaster without '-i'.
So I don't think the TCP stack is involved in this case?
Any other ideas where the problem could be?
Besides, I'm testing the connection status with PQstatus(),
but it doesn't return CONNECTION_BAD (after the connection has
been closed) until the next query.
Is there a better way to test a connection?
Thanks,
Stefan
--
Stefan Loidl Phone: +49 89 289-28882
Leibniz Supercomputing Center Fax: +49 89 2809460
Barer Str. 21 mailto:loidl@lrz.de
80333 Munich, Germany http://www.lrz.de