You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "Alexander, Ben" <BA...@arqule.com> on 2000/12/01 15:04:57 UTC

too many open files error

Hello Tomcat users/developers;

We've been using Tomcat as our development server for a few months, but now
that our
project is really getting off the ground I find that I get the following
error message after
I use the server for 10 minutes or so:

----------------------------------------------------------------------------
------------------------------------------------
java.net.SocketException: Too many open files
        at java.net.PlainSocketImpl.socketAccept(Native Method)
        at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:406,
Compiled Code)
        at java.net.ServerSocket.implAccept(ServerSocket.java:240, Compiled
Code)
        at java.net.ServerSocket.accept(ServerSocket.java:224, Compiled
Code)
        at
org.apache.tomcat.service.SimpleTcpEndpoint.acceptSocket(SimpleTcpEndpoint.j
ava:267, Compiled Code)
        at
org.apache.tomcat.service.SimpleTcpEndpoint.acceptConnections(SimpleTcpEndpo
int.java:248, Compiled Code)
        at
org.apache.tomcat.service.TcpListenerThread.run(SimpleTcpEndpoint.java:319,
Compiled Code)
        at java.lang.Thread.run(Thread.java:479, Compiled Code)
Endpoint ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=8090] shutdown
due to exception: java.net.SocketException: Too many open files
----------------------------------------------------------------------------
--------------------------------------------------------

Now, as far as I can tell I'm not opening any files at all, other than a log
file I maintain.  So I guess
my question has two parts:
1)  Assuming I'm all wet, and I'm actually opening files all over the place
and leaving them open, is
there any way that I can check to see what files are open?
2)  If I'm not doing something extra dumb, has anybody else seen this
problem come up before?  It
seems to arise when the program is delivering a gif to build a page, but
presume that it's safe to guess
that getting a gif is not a problem in general.  

I'm doing Servlet programming on Tomcat 3.1, under IRIX 6.5.

Thanks in advance for any help,
Ben

Re: too many open files error

Posted by Marcus Crafter <cr...@dresdnerbank.de>.
Hi Alexander,

	We experienced similar problems in our environment which was under
	Linux. The fix was to tune the kernel parameters in /proc/sys/fs to
	allow more files and inodes across the whole system to be used. We
	doubled these values and haven't had any problems since.

	Is there something similar under IRIX ?

	HTH

	Marcus

On Fri, 1 Dec 2000, Alexander, Ben wrote:

> Hello Tomcat users/developers;
> 
> We've been using Tomcat as our development server for a few months, but now
> that our
> project is really getting off the ground I find that I get the following
> error message after
> I use the server for 10 minutes or so:
> 
> ----------------------------------------------------------------------------
> ------------------------------------------------
> java.net.SocketException: Too many open files
> ----------------------------------------------------------------------------
> --------------------------------------------------------

-- 
        .....
     ,,$$$$$$$$$,      Marcus Crafter
    ;$'      '$$$$:    Computer Systems Engineer
    $:         $$$$:   Open Software Associates GmbH
     $       o_)$$$:   82-84 Mainzer Landstrasse
     ;$,    _/\ &&:'   60327 Frankfurt Germany
       '     /( &&&
           \_&&&&'     Email : Marcus.Crafter@osa.de
          &&&&.        Business Hours : +49 69 9757 200
    &&&&&&&:           After Hours    : +49 69 49086750