RE: [GENERAL] Too many open files...

From: "Culberson, Philip" <philip(dot)culberson(at)dat(dot)com>
To: "'Thomas Mack'" <mack(at)ips(dot)cs(dot)tu-bs(dot)de>, pgsql-general(at)postgreSQL(dot)org
Subject: RE: [GENERAL] Too many open files...
Date: 2000-01-21 16:13:37
Message-ID: A95EFC3B707BD311986C00A0C9E95B6A9DE33F@datmail03.dat.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

>From your description I would hazard a guess that your servlet is
misbehaving. On Solaris, the default maximum number of open file handles
for a process is 64. Unless if your servlet is opening a BUNCH of files, I
would look for it being in some sort of loop, opening a file, but not
closing it. Do this enough times and you run out of file handles.

-----Original Message-----
From: Thomas Mack [mailto:mack(at)ips(dot)cs(dot)tu-bs(dot)de]
Sent: Friday, January 21, 2000 5:17 AM
To: pgsql-general(at)postgreSQL(dot)org
Subject: [GENERAL] Too many open files...

Well, we got a problem with postgres 6.5.2 on SOlaris 2.6, when:

1) Executing a query with a trigger behind it, making quite a big amount
of
queries on different relations,
2) and when this query is executed from an applet via a servlet on
Apache 1.3.3
using postgresql.jar as db driver.

So, the message is:

ERROR: Load of file /usr/dblocal/pgsql/lib/plpgsql.so failed: ld.so.1:
/usr/dblocal/pgsql/bin/postmaster: fatal: /dev/zero: open failed: Too
many open files

(or similar).

The problem does not exist, if we execute it via psql.

So I tracked it down to dlopen(filename,1). But really, I do not know,
what might
be the real reason for the failure: is it postgres (probably not),
Apache, restricting
the environment "somehow", or postgresql.jar (it should just give the
query to the
backend, so probably not as well), or Solaris itself (but why do I not
get an error,
if I execute it via psql?) or where should I check further?

I am a little confused on how to repair the problem, as it is most
probably not
a problem with postgres. Anybody had similar experiences or even a
solution (besides
not using the trigger)?

Thanks,
Thomas Mack
TU Braunschweig, Abt. Informationssysteme

************

Browse pgsql-general by date

  From Date Subject
Next Message The Hermit Hacker 2000-01-21 18:01:41 BEGIN/END question ...
Previous Message Gabriel Fernandez 2000-01-21 15:23:22 Problems with select ... into ...