0

We have recently switched from an old Apache with prefork to 2.4.9 with worker, configured as

ServerLimit         16
StartServers         2
MaxRequestWorkers  150
MinSpareThreads     25
MaxSpareThreads     75
ThreadsPerChild     25

At the same time we switched from mod_jk 1.2.37 to 1.2.40. Now we sporadically get:

20140625 18:04:29  [32187:139712338515728] [warn] ajp_get_endpoint::jk_ajp_common.c (3229): Unable to get the free endpoint for worker abc from 1 slots
20140625 18:04:29  [32187:139712338515728] [error] jk_handler::mod_jk.c (2744): Could not get endpoint for worker=abc
20140625 18:04:29  [32187:139712338515728] [info] jk_handler::mod_jk.c (2806): Service error=0 for worker=abc
20140625 18:04:29  500  "/abc/search?xyz=2" 534b abc:- 0.200348s

What is 1 slot? Isn't mod_jk supposed to dynamically configure itself to match Apache? I found that under "high" load (after about 20 simultaneous requests) this becomes more likely to happen with more ThreadsPerChild. Whereas with ThreadsPerChild 1 it doesn't seem to happen at all, effectively reducing me to the equivalent of prefork.

Am I overseeing something or did mod_jk's picking up of Apache parameters break in 1.2.40?

1 Answer 1

1

The doc for connection_pool_size says:

JK will discover this number for the Apache web server automatically and set the pool size to this value.

It turns out that this is not true. It defaults to 1. Setting this to the same value as ThreadsPerChild made the problem go away.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.