On 18.05.2011 00:30, Mike Jakubik wrote:
> On Wed, 2011-05-18 at 00:07 +0200, Rainer Jung wrote:
> 
>> Thanks for the report. Would you mind opening an issues in Bugzilla? You
>> can choose the Tomcat project and Tomcat Connectors as a component. If
>> it turns out as an APR bug, we can move the issue there later.
>>
>> It would be very helpful, if you could provide thread stacks using
>> pstack or gdb. Please provide a couple of such threads stack outputs.
>>
>> Furthermore, if your MPM is worker, not prefork, it would be helpful if
>> you could check using ps, which of the threads in the process actually
>> consume the CPU. I'm not sure about FreeBSD ps flags, but -H -p ...
>> could be right. This helps us select out the right thread stack.
>>
>> Regards,
>>
>> Rainer
>>
>>
> 
> 
> I can recompile apache to prefork if it will make debugging easier (fyi,
> problem occurs with both worker and prefork MPMs) . Some help with the
> actual debugging would be appreciated, i can use GDB but i don’t know
> how to preform the debugging process.

If you can find pstack, that will be easier. pstack just takes the
process id and writes out the stacks for all threads. My quick search
indicates it pstack should exist for FreeBSD.

GDB allows to also get details on the values of variables used, step
through the code etc. You give gdb two arguments, the path to your httpd
binary and the process ID of the CPU consuming process. Once the gdb
prompt is shown, you can enter

thread apply all bt full

which will output thread and variable information for all threads.

pstack and gdb might produce many lines of output, especially for
worker, so you might want to write the result directly to a file, e.g.

pstack PID > /tmp/pstack.txt

And yes, if the problem also occurs for prefork, then that makes
debugging a bit easier.

Regards,

Rainer

Attachment: 0xEE8E0DD5.asc
Description: application/pgp-keys

Reply via email to