tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stephen Charles Huey" <stephenh...@fastmail.fm>
Subject SocketException: Too many open files
Date Tue, 01 Feb 2005 23:29:51 GMT
I'm running some simple but fast-pounding test programs against our
Tomcat server from a machine on the same network, and we've been tuning
our database, etc, based on this.  But right now, I'm seeing a new one
coming out of our Java code whenever we try to open a URL:


java.net.SocketException: Too many open files
	at java.net.Socket.createImpl(Socket.java:331)
	at java.net.Socket.connect(Socket.java:450)
	at com.sun.net.ssl.internal.ssl.SSLSocketImpl.connect(DashoA12275)
	at com.sun.net.ssl.internal.ssl.SSLSocketImpl.<init>(DashoA12275)
	at com.sun.net.ssl.internal.ssl.SSLSocketFactoryImpl.createSocket(DashoA12275)
	at sun.net.www.protocol.https.HttpsClient.doConnect(DashoA12275)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:402)
	at sun.net.www.http.HttpClient.openServer(HttpClient.java:618)
	at sun.net.www.protocol.https.HttpsClient.<init>(DashoA12275)
	at sun.net.www.protocol.https.HttpsClient.a(DashoA12275)
	at sun.net.www.protocol.https.HttpsClient.a(DashoA12275)
	at sun.net.www.protocol.https.HttpsClient.a(DashoA12275)
	at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.plainConnect(DashoA12275)
	at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(DashoA12275)
	at sun.net.www.protocol.https.HttpsURLConnectionImpl.connect(DashoA12275)



We're opening lots of these, and it appears we're opening more than a
maximum number of connections to the internet.  Is there a way to bump
this up?  Or maybe we're just pounding this harder than it will ever get
hit in the real world?  I'm also seeing this as well:





SEVERE: Endpoint ServerSocket[addr=0.0.0.0/0.0.0.0,port=0,localport=80]
ignored exception: java.net.SocketException: Too many open files
java.net.SocketException: Too many open files
	at java.net.PlainSocketImpl.socketAccept(Native Method)
	at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:353)
	at java.net.ServerSocket.implAccept(ServerSocket.java:448)
	at java.net.ServerSocket.accept(ServerSocket.java:419)
	at org.apache.tomcat.util.net.DefaultServerSocketFactory.acceptSocket(DefaultServerSocketFactory.java:107)
	at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.java:356)
	at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:529)
	at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)
	at java.lang.Thread.run(Thread.java:534)
Feb 1, 2005 4:53:08 PM org.apache.tomcat.util.net.PoolTcpEndpoint
closeServerSocket
SEVERE: Caught exception trying to unlock accept.
java.net.SocketException: Too many open files
	at java.net.Socket.createImpl(Socket.java:331)
	at java.net.Socket.<init>(Socket.java:304)
	at java.net.Socket.<init>(Socket.java:124)
	at org.apache.tomcat.util.net.PoolTcpEndpoint.closeServerSocket(PoolTcpEndpoint.java:326)
	at org.apache.tomcat.util.net.PoolTcpEndpoint.acceptSocket(PoolTcpEndpoint.java:397)
	at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:529)
	at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:619)
	at java.lang.Thread.run(Thread.java:534)
Feb 1, 2005 4:53:08 PM org.apache.tomcat.util.net.PoolTcpEndpoint
acceptSocket
WARNING: Reinitializing ServerSocket


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message