tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mohit Anchlia <mohitanch...@gmail.com>
Subject Re: Http 500 and %b in access log
Date Wed, 20 Jan 2010 19:11:58 GMT
On Wed, Jan 20, 2010 at 10:47 AM, Christopher Schultz
<chris@christopherschultz.net> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Mohit,
>
> On 1/20/2010 12:06 PM, Mohit Anchlia wrote:
>> Tomcat 6:
>
> Which specific version, please. Also, what connector(s) are you using.
> Please provide the configuration for them. Are you using another web
> server in front of Tomcat? If so, which one, and how are you connecting
> them (mod_jk, mod_proxy_ajp, mod_proxy_http, etc.)?


Using CATALINA_BASE:   /usr/local/tomcat
Using CATALINA_HOME:   /usr/local/tomcat
Using CATALINA_TMPDIR: /usr/local/tomcat/temp
Using JRE_HOME:       /usr/local/java
Server version: Apache Tomcat/6.0.18
Server built:   Jul 22 2008 02:00:36
Server number:  6.0.18.0
OS Name:        Linux
OS Version:     2.6.9-42.0.10.ELhugemem
Architecture:   i386
JVM Version:    1.5.0_08-b03
JVM Vendor:     Sun Microsystems Inc.

We don't any other web server in front
>
>> I am seeing Exception in localhost java.net.SocketTimeoutException:
>> Read time out. I looked at the access log and I see tomcat returning
>> Http 500. Only thing in common is that "%b" (bytes sent) for all the
>> timeouts are 2657. For rest of them where requests are successful
>> it's less than 2657.
>
> Interesting. Do all responses with fewer than 2657 bytes succeed? Do all
> responses with more than 2656 bytes fail?


YES

> Please post the entire stack trace of the exception.

SEVERE: Servlet.service() for servlet SwitchServlet threw exception
java.net.SocketTimeoutException: Read timed out
        at java.net.SocketInputStream.socketRead0(Native Method)
        at java.net.SocketInputStream.read(SocketInputStream.java:129)
        at java.io.FilterInputStream.read(FilterInputStream.java:111)
        at com.wily.introscope.agent.probe.net.ManagedSocketInputStream.read(ManagedSocketInputStream.java:214)
        at org.apache.coyote.http11.InternalInputBuffer.fill(InternalInputBuffer.java:746)
        at org.apache.coyote.http11.InternalInputBuffer$InputStreamInputBuffer.doRead(InternalInputBuffer.java:776)
        at org.apache.coyote.http11.filters.IdentityInputFilter.doRead(IdentityInputFilter.java:116)
        at org.apache.coyote.http11.InternalInputBuffer.doRead(InternalInputBuffer.java:705)
        at org.apache.coyote.Request.doRead(Request.java:428)
        at org.apache.catalina.connector.InputBuffer.realReadBytes(InputBuffer.java:304)
        at org.apache.tomcat.util.buf.ByteChunk.substract(ByteChunk.java:405)
        at org.apache.catalina.connector.InputBuffer.read(InputBuffer.java:327)
        at org.apache.catalina.connector.CoyoteInputStream.read(CoyoteInputStream.java:162)
        at org.apache.commons.io.IOUtils.copyLarge(IOUtils.java:1025)
        at org.apache.commons.io.IOUtils.copy(IOUtils.java:999)
        at org.apache.commons.io.IOUtils.toByteArray(IOUtils.java:218)
        at com.intuit.engine.efp.efe.efileswitch.SwitchServlet.doPostOrGet(SwitchServlet.java:174)
        at com.intuit.engine.efp.efe.common.servlet.BaseServlet.doPost(BaseServlet.java:48)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
        at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:568)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
        at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
        at java.lang.Thread.run(Thread.java:595)


>> Could someone help me understand what %b is for in localhost access
>> logs and if what I am seeing makes sense.
>
> %b is, as you say, the number of bytes sent (presumably to the client,
> in the response).
>
> Does this always fail with certain clients? If so, which ones? Are these
> normal web browsers, or are you using a custom client?

Yes it always fail with desktop clients on the broadband/modem etc..
Basically ones that are using our GUI application.

>> Does SocketTimeoutException correspond to ConnectionTimeout in the
>> connector? We tried increasing it but didn't make any difference.
>
> ConnectionTimeout is how long the connector will wait after a connection
> is established for the request to come from the client.

Is there also a timeout where connection is closed when 'n' secs
expire irrespecitve of if the client and server are actively talking
to each other.

> There really isn't a setting on the standard HTTP connector that will
> cause a timeout to occur when writing to the connection.
>
> - -chris
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.10 (MingW32)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
>
> iEYEARECAAYFAktXT8wACgkQ9CaO5/Lv0PC+wwCgjE73Gni6yEQ9qJYbldBamfUJ
> +2IAnjgjRVHVoq8Cro2MmrTrjXTXG0jf
> =B4HZ
> -----END PGP SIGNATURE-----
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>

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


Mime
View raw message