Ken: Thanks for your info. I was creating one URLConnection per 5 seconds per thread. When I created 400 threads, a lot of threads failed to connect after about 5 minutes. If I run 200 threads, there was not any exception, but connecting to server is obviously slow. So I was thinking I was creating around 20 connections/sec to generate ConnectException.
Is that the limit of Tomcat/Apache? I thought Tomcat/Apache is much more powerful than that. Any more thoughts on that? Thanks a lot! Yaogeng -----Original Message----- From: Ken Anderson [mailto:[EMAIL PROTECTED]] Sent: Wednesday, April 17, 2002 3:44 PM To: Tomcat Users List Subject: Re: URLConnection was rejected in Apache-Tomcat Web envirment! For apache limits, see: http://httpd.apache.org/docs/mod/directives.html For linux, try 'sysctl -a' to see a list of limits. How many connections/sec were you creating? Ken Yaogeng Cheng wrote: > Hi: > > I was testing my servlet under Apach-Tomcat envirment in Linux system. > I opened 200 threads in my Win 2000 and kept opening URLConnections > and sent some String to the servlet using DataOutputStream dateOut = > new DataOutputStream(conn.getOutputStream());. After a period of time, > a lot of threads was failed to connect to the servlets by throwing > java.net.ConnectionException. > > I checked Linux machine, and I found a lot of sockets were opend by my > test client and were not closed and waiting time out. Is it normal > that all these tcp connection did not close by themself and is it the > reason that some URLConnection was rejected? How can I fix the > problem? > > Is there any limitations with my Linux machine or TomCat on the number > of TCP socket (by URLConnection on port 8080) connections? How can I > check it and change the number? > > Thanks > > Yaogeng > -- To unsubscribe: <mailto:[EMAIL PROTECTED]> For additional commands: <mailto:[EMAIL PROTECTED]> Troubles with the list: <mailto:[EMAIL PROTECTED]> -- To unsubscribe: <mailto:[EMAIL PROTECTED]> For additional commands: <mailto:[EMAIL PROTECTED]> Troubles with the list: <mailto:[EMAIL PROTECTED]>
