Re: The backend has broken the connection... - Mailing list pgsql-jdbc

From Tom Lane
Subject Re: The backend has broken the connection...
Date
Msg-id 21911.1010690439@sss.pgh.pa.us
Whole thread Raw
In response to Re: The backend has broken the connection...  (bcarterette@mail.liberty.k12.mo.us)
List pgsql-jdbc
bcarterette@mail.liberty.k12.mo.us writes:
> I solved it.  The problem was that when I got up to around 70 or 80
> concurrent connections, the database server had too many files open.  I
> added lines in rc.local to increase /proc/sys/fs/file-max and
> /proc/sys/fs/inode-max fourfold, and since then I've been up to almost
> 120 concurrent connections with no problem.

Hmm.  Usually when Postgres runs the system out of file descriptors,
it's everything else that starts falling over, not Postgres itself.
(The backend has code to close other open file descriptor(s) if it
needs another one.  But most Unix programs just die if they can't
open a file the first try.)

What PG version are you running, exactly?  Could you look in the
postmaster log and see what log messages were being generated when
these things happened?  I think this deserves a more careful look
than just "I fixed it".

            regards, tom lane

pgsql-jdbc by date:

Previous
From: bcarterette@mail.liberty.k12.mo.us
Date:
Subject: Re: The backend has broken the connection...
Next
From: "Paulo Merson"
Date:
Subject: Re: JDBC patch for DatabaseMetaData