Hello everyone,
could you please help me with a problem. My Tomcat is running on the following
configuration:
1. OS Centos 4
2. Java 1.5
3. Standalone Tomcat 5.5.12
4. 512MB RAM guaranteed/2GB Burst RAM
5. MySQL 4
I rent a VPS and if I run the 'cat /proc/user_beancounters' command I may see
the number of tcp sockets available to my hosting plan:
resource held maxheld barrier limit failcnt
numtcpsock 171 171 500 500 46691
The problem is that the number of 'held' sockets is increasing constantly, and
within say, 10-12 hours my VPS is down if I don't restart Tomcat.
After the restart of the failed VPS I see in the admin panel that the reason of
failure was the number of open sockets that exceeded the limits.
I usually have 300-500 users per day who browse 1-5 pages. The app has a custom
cache, so the number of mysql connections is very small.
The two last app log records say:
/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/
26-10/11:53 ERROR
org.apache.catalina.core.ContainerBase.[Catalina].[].[/].[jsp] -
Servlet.service() for servlet jsp threw exception
javax.servlet.jsp.JspException: ServletException in '/pages/jsp/index.jsp':
javax.servlet.jsp.JspException: Unable to get connection, DataSource invalid:
"java.sql.SQLException: Cannot connect to MySQL server on localhost:3306. Is
there a MySQL server running on the machine/port you are trying to connect to?
(java.net.SocketException)"
at
org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.java:919)
/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/
26-10/11:53 ERROR
org.apache.catalina.core.ContainerBase.[Catalina].[].[/].[action] -
Servlet.service() for servlet action threw exception
java.lang.IllegalStateException: getOutputStream() has already been called for
this response
at org.apache.catalina.connector.Response.getWriter(Response.java:606)
at
org.apache.catalina.connector.ResponseFacade.getWriter(ResponseFacade.java:195)
at javax.servlet.ServletResponseWrapper.getWriter
/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/
The five last catalina.out records are the same:
/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/
Exception Processing ErrorPage[errorCode=500, location=/error500.do]
org.apache.jasper.JasperException: getOutputStream() has already been called
for this response
at
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:510)
at org.apache.jasper.servlet.JspServletWrapper.service
/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/=/
I would highly appreciate your help or ideas. Thank you in advance!
--
Best regards,
Sergey mailto:[EMAIL PROTECTED]
---------------------------------------------------------------------
To start a new topic, e-mail: [email protected]
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]