JBOSS 高并发出错(急)

02-09-21 maji
    

急问!!!!!!!!!!!!!!!!!!

使用 AXIX + JBOSS +ORACLE

在30个并发下运行稳定,在50 个并发时出错

我的 jbossweb-tomcat41.sar\META-INF\jboss-service.xml 的配置为

<Connector className="org.apache.coyote.tomcat4.CoyoteConnector"

address="${jboss.bind.address}" port="9999" minProcessors="10" maxProcessors="200"

enableLookups="true" acceptCount="10" debug="0"

connectionTimeout="20000" useURIValidationHack="false"/>

该配置在 axix + Tomcat +oracle 运行环境下运行稳定

我的 JAVA_OPTS为 Set JAVA_OPTS=-Xms400m -Xmx400m,内存肯定没问题,因为 TOMCAT下只用 256就可以了。

何况JBOSS 我去掉了JMS等不用的功能

连接池我配置了 100 个,应该没问题,数据库支持200个。

错误提示如下(部分)

2004-05-24 15:53:51,352 ERROR [org.apache.axis.Message] java.io.IOException:

ClientAbortException: java.net.SocketException: Software caused connection abort: socket write error

at org.apache.coyote.tomcat4.OutputBuffer.realWriteBytes(OutputBuffer.java:404)

at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:428)

at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:348)

at org.apache.coyote.tomcat4.OutputBuffer.writeBytes(OutputBuffer.java:432)

at org.apache.coyote.tomcat4.OutputBuffer.write(OutputBuffer.java:419)

at org.apache.coyote.tomcat4.CoyoteOutputStream.write(CoyoteOutputStream.java:108)

at sun.nio.cs.StreamEncoder$CharsetSE.writeBytes(StreamEncoder.java:334)

at sun.nio.cs.StreamEncoder$CharsetSE.implWrite(StreamEncoder.java:394)

at sun.nio.cs.StreamEncoder.write(StreamEncoder.java:134)

at java.io.OutputStreamWriter.write(OutputStreamWriter.java:191)

at java.io.BufferedWriter.flushBuffer(BufferedWriter.java:111)

at java.io.BufferedWriter.write(BufferedWriter.java:206)

at java.io.Writer.write(Writer.java:126)

at org.apache.axis.SOAPPart.writeTo(SOAPPart.java:311)

at org.apache.axis.Message.writeTo(Message.java:531)

at org.apache.axis.transport.http.AxisServlet.sendResponse(AxisServlet.java:807)

at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:683)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)

at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:339)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)

at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)

at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)

at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)

at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)

at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)

at org.jboss.web.tomcat.security.JBossSecurityMgrRealm.invoke(JBossSecurityMgrRealm.java:220)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)

at org.apache.catalina.valves.CertificatesValve.invoke(CertificatesValve.java:246)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)

at org.jboss.web.tomcat.tc4.statistics.ContainerStatsValve.invoke(ContainerStatsValve.java:76)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)

at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)

at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2417)

at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)

at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)

at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:172)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)

at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:65)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)

at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)

at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)

at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)

at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)

at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)

at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:197)

at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:781)

at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:549)

at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:605)

at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:677)

at java.lang.Thread.run(Thread.java:536)

2004-05-24 15:53:54,430 ERROR [org.apache.axis.Message] java.io.IOException:

ClientAbortException: java.net.SocketException: Software caused connection abort: socket write error

at org.apache.coyote.tomcat4.OutputBuffer.realWriteBytes(OutputBuffer.java:404)

at org.apache.tomcat.util.buf.ByteChunk.flushBuffer(ByteChunk.java:428)

at org.apache.tomcat.util.buf.ByteChunk.append(ByteChunk.java:348)

at org.apache.coyote.tomcat4.OutputBuffer.writeBytes(OutputBuffer.java:432)

at org.apache.coyote.tomcat4.OutputBuffer.write(OutputBuffer.java:419)

    

1
banq
2004-05-24 18:35

与JBoss无关,这是Tomcat很常见的线程问题,

maji
2004-05-25 09:17

楼主,我在Tomcat 下使用 该配置 server.xml

<Connector port="9999"

maxThreads="200" minSpareThreads="25" maxSpareThreads="75"

enableLookups="false" redirectPort="8443" acceptCount="10"

debug="0" connectionTimeout="20000"

disableUploadTimeout="true" />

并发用户数可以到达100个

在JBOSS下 Tomcat 配置 jboss-service.xml

<Connector className="org.apache.coyote.tomcat4.CoyoteConnector"

address="${jboss.bind.address}" port="9999" minProcessors="10" maxProcessors="200"

enableLookups="true" acceptCount="10" debug="0"

connectionTimeout="20000" useURIValidationHack="false"/>

出现线程异常,是Tomcat配置错误吗?

maji
2004-05-27 08:38

我觉得出现这总错误 无非是三个原因:

1.数据库库连接达到极限

2.应用服务器 最大线程并发数 达到极限

3.内存耗尽

我在EAServer,Tomcat 作为中间件服务器时 碰到类似问题都是通过调整这三个参数进行解决

但是JBoss中 没有解决掉,有两个问题

1. 以上错误是否是由于上面三个原因引起,有没有其它原因

2. JBoss中如何修改上面 第二个参数

banq
2004-05-27 16:01

JBoss的deploy /jbosswebxxxxx目录下的META-INF/jboss-service.xml中修改,参考以前一篇有关JBoss 3.23性能优化的文章

8Go 上一页 2 3 4 5 6 7 8 下一页