On 13.10.2011 06:16, Jorge Medina wrote:
> I have Apache (2.2.20) in front of a single Tomcat (6.0.32) instance
> using mod_jk (1.2.31) with the AJP protocol.
> I am getting errors like the sample below frequently (a few hundred
> times a day).  The server does not have a heavy load, it serves about
> 150 req/minute and average response time of 200 ms)
> 
> [2011-10-12T23:27:00.644-0400] [20239:27] [info]
> ajp_service::jk_ajp_common.c (2543): (S1) sending request to tomcat
> failed (unrecoverable), because of client read error (attempt=1)
> [2011-10-12T23:27:00.654-0400] [20239:27] [info]
> service::jk_lb_worker.c (1388): service failed, worker S1 is in local
> error state
> [2011-10-12T23:27:00.655-0400] [20239:27] [info]
> service::jk_lb_worker.c (1407): unrecoverable error 400, request
> failed. Client failed in the middle of request, we can't recover to
> another instance.
> [2011-10-12T23:27:00.655-0400] [20239:27] [info] jk_handler::mod_jk.c
> (2620): Aborting connection for worker=wlb
> 
> 
> a) Could I get some help to interpret the messages above?

The browser or whatever is talking to your webserverstarted a request,
but didn't send the full request. Most likely it took too long to send
the full POST body, but it could also happen during other requestread
phases.

> b) What is being referred as "Client" ? The client originating the
> request or does mod_jk calls "Client" my Tomcat instance? (I guess I
> don't know if mod_jk establishes the connection to Tomcat or if Tomcat
> is establishing the channel to mod_jk)

Client is the web server client, e.g. the browser or similar.

> c) Messages are logged as [info] rather than warning or errors...why?
> Should I not be concerned about these messages?

Because typically there's nothing to fix on the server side. Only if
this happens very frequently, you might have a network problem, or a lot
of users with bad network connections.

> d) If that is a symptom of a problem, how do I fix it? (In fact, I am
> being reported that clients of my app are timing out waiting for a
> response, but my application logs don't have any indication of
> receiving the request, so I am trying to find out if the message above
> is an indication that the problem occurs in the Tomcat Connector, and
> therefor my web app running in Tomcat never got the request at all)

It is a message concerning only communication between client and web
server, no communication between web server and Tomcat is involved in
the problem. If you want to debug, concentrate on the communication
between client and web server and try to understand the request details
for which it happens (GET or POST or something else; Content-Length set
or chunked encoding for the request used etc.). You might need to sniff
traffic.

> === workers.properties
> 
> workers.tomcat_home=/opt/greatapp/tomcat
> workers.java_home=/opt/jdk/jdk6.0
> ps=/

The above three are useless garbage.

> worker.list= wlb, jkwatch
> worker.wlb.type=lb
> worker.wlb.balance_workers=S1
> worker.wlb.max_reply_timeouts=3
> 
> worker.jkwatch.type=status
> worker.jkwatch.read_only=True
> worker.jkwatch.mount=/private/admin/watch/jk
> 
> worker.S1.type=ajp13
> worker.S1.host=localhost
> worker.S1.port=6009
> worker.S1.lbfactor=1
> worker.S1.connection_pool_timeout=600
> worker.S1.socket_keepalive=False
> worker.S1.socket_timeout=15
> worker.S1.reply_timeout=300000
> worker.S1.recovery_options=27
> 
> 
> === uriworkermap.properties
> 
> /myapp=wlb
> /myapp/*=wlb
> /private/admin/watch/jk=jkwatch

Not too bad :)

For improvements look at the full exampleconfig contained in a recent
source download of mod_jk.But as said: the problem is not with
communication web server to tomcat.

Regards,

Rainer


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

Reply via email to