You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Michiel Beijen <mi...@gmail.com> on 2013/03/07 15:11:42 UTC

How to determine what makes Apache crash?

Hi,

I'm using mod_perl 2.0.7 on Windows with Apache 2.2.23. I got Apache
from Apachelounge, and compiled mod_perl and perl 5.16.2 myself using
Visual Studio 2008. I'm using a 32-bit Windows Vista.

Pretty frequently my app (which works just fine on Linux) makes Apache
crash. If I perform 500 requests with Apache Bench, I see this:

Benchmarking localhost (be patient)
Completed 100 requests
Completed 200 requests
Completed 300 requests
apr_socket_recv: An existing connection was forcibly closed by the
remote host.   (730054)
Total of 338 requests completed

In the apache error log I see apache is restarting, but this results
in some HTTP 500 errors that make the apache-bench results fail. When
using a web browser, I also get these http 500 errors.

If I run the application using native CGI (i.e. I turn off mod_perl) I
do not see crashes but of course it is *very* slow.

How can I find out what makes apache/mod_perl crash?

--
Mike

Re: How to determine what makes Apache crash?

Posted by Jeff Trawick <tr...@gmail.com>.
On Thu, Mar 7, 2013 at 2:43 PM, Michiel Beijen <mi...@otrs.com>wrote:

> On Thu, Mar 7, 2013 at 4:02 PM, Jeff Trawick <tr...@gmail.com> wrote:
>
> > mod_backtrace (http://emptyhammock.com/projects/httpd/diag/) may be a
> > shortcut to getting a backtrace.  There's a binary for use with Apache
> 2.2
> > on Windows in the download package.
> >
> > Any mechanism for getting a backtrace will require that symbol files
> (.pdb
> > files) matching your Apache httpd build be present.  I don't know how the
> > Apache Lounge distributions accommodate that.  Some other builds provide
> a
> > separate .zip with the .pdb files, to be unpacked from the Apache httpd
> > install directory prior to collecting problem documentation.
>
> Thanks, your modules look helpful. I asked at the apachelounge for how
> to get the symbol files. If needed, I'll compile Apache myself.
>
> I have output like this from whatkilledus, but of course this does not
> really help much:
> http://perlpunks.de/paste/show/5138ecec.24c3.350?plain=1


The symbols within httpd are bogus, and should be corrected with symbol
files from Apache Lounge.

Perhaps the mod_perl folks can comment on the mod_perl/perl section of the
back trace, and how one might try to tie that to some particular area of
your code.



>
> --
> Mike
>



-- 
Born in Roswell... married an alien...
http://emptyhammock.com/

Re: How to determine what makes Apache crash?

Posted by Michiel Beijen <mi...@otrs.com>.
On Thu, Mar 7, 2013 at 4:02 PM, Jeff Trawick <tr...@gmail.com> wrote:

> mod_backtrace (http://emptyhammock.com/projects/httpd/diag/) may be a
> shortcut to getting a backtrace.  There's a binary for use with Apache 2.2
> on Windows in the download package.
>
> Any mechanism for getting a backtrace will require that symbol files (.pdb
> files) matching your Apache httpd build be present.  I don't know how the
> Apache Lounge distributions accommodate that.  Some other builds provide a
> separate .zip with the .pdb files, to be unpacked from the Apache httpd
> install directory prior to collecting problem documentation.

Thanks, your modules look helpful. I asked at the apachelounge for how
to get the symbol files. If needed, I'll compile Apache myself.

I have output like this from whatkilledus, but of course this does not
really help much:
http://perlpunks.de/paste/show/5138ecec.24c3.350?plain=1

--
Mike

Re: How to determine what makes Apache crash?

Posted by Jeff Trawick <tr...@gmail.com>.
On Thu, Mar 7, 2013 at 9:52 AM, Michiel Beijen <mi...@otrs.com>wrote:

> Hi,
>
> I'm using mod_perl 2.0.7 on Windows with Apache 2.2.23. I got Apache
> from Apachelounge, and compiled mod_perl and perl 5.16.2 myself using
> Visual Studio 2008. I'm using a 32-bit Windows Vista.
>
> Pretty frequently my app (which works just fine on Linux) makes Apache
> crash. If I perform 500 requests with Apache Bench, I see this:
>
> Benchmarking localhost (be patient)
> Completed 100 requests
> Completed 200 requests
> Completed 300 requests
> apr_socket_recv: An existing connection was forcibly closed by the
> remote host.   (730054)
> Total of 338 requests completed
>
> In the apache error log I see apache is restarting, but this results
> in some HTTP 500 errors that make the apache-bench results fail. When
> using a web browser, I also get these http 500 errors.
>
> If I run the application using native CGI (i.e. I turn off mod_perl) I
> do not see crashes but of course it is *very* slow.
>
> How can I find out what makes apache/mod_perl crash?
>

I don't see any Windows crash diagnosis information on this page:
http://httpd.apache.org/dev/debugging.html   Is Dr. Watson still the way to
go?

mod_backtrace (http://emptyhammock.com/projects/httpd/diag/) may be a
shortcut to getting a backtrace.  There's a binary for use with Apache 2.2
on Windows in the download package.

Any mechanism for getting a backtrace will require that symbol files (.pdb
files) matching your Apache httpd build be present.  I don't know how the
Apache Lounge distributions accommodate that.  Some other builds provide a
separate .zip with the .pdb files, to be unpacked from the Apache httpd
install directory prior to collecting problem documentation.



>
> --
> Mike
>



-- 
Born in Roswell... married an alien...
http://emptyhammock.com/

How to determine what makes Apache crash?

Posted by Michiel Beijen <mi...@otrs.com>.
Hi,

I'm using mod_perl 2.0.7 on Windows with Apache 2.2.23. I got Apache
from Apachelounge, and compiled mod_perl and perl 5.16.2 myself using
Visual Studio 2008. I'm using a 32-bit Windows Vista.

Pretty frequently my app (which works just fine on Linux) makes Apache
crash. If I perform 500 requests with Apache Bench, I see this:

Benchmarking localhost (be patient)
Completed 100 requests
Completed 200 requests
Completed 300 requests
apr_socket_recv: An existing connection was forcibly closed by the
remote host.   (730054)
Total of 338 requests completed

In the apache error log I see apache is restarting, but this results
in some HTTP 500 errors that make the apache-bench results fail. When
using a web browser, I also get these http 500 errors.

If I run the application using native CGI (i.e. I turn off mod_perl) I
do not see crashes but of course it is *very* slow.

How can I find out what makes apache/mod_perl crash?

--
Mike