Re: Killing oversized Perl processes

2010-03-11 Thread Perrin Harkins
On Thu, Mar 11, 2010 at 4:41 PM, ARTHUR GOLDBERG wrote: > 2) Kill apache httpd processes occasionally, to control the effect of slow > perl memory leaks. I'll do this by setting MPM Worker MaxRequestsPerChild to > some modest value. (I'll try 100.) You definitely should be doing that, and possibl

Killing oversized Perl processes

2010-03-11 Thread ARTHUR GOLDBERG
Running Perl programs in mod_perl in Apache (2.2) on RHEL: [10 a...@virtualplant:/etc]$ cat /etc/redhat-release Red Hat Enterprise Linux Server release 5.4 (Tikanga) [11 a...@virtualplant:/etc]$ uname -r 2.6.18-164.11.1.el5 Occasionally a process grows so large that it freezes the system: se

Re: Setting Content-Type in a custom response (mp2)

2010-03-11 Thread Torsten Förtsch
On Thursday 11 March 2010 15:18:08 Steve Hay wrote: > I have a mod_perl-2 handler that uses custom_response() to display error > messages if something goes wrong: > > $r->custom_response(Apache2::Const::SERVER_ERROR, $error); > return Apache2::Const::SERVER_ERROR; > > That almost works fine, but

Setting Content-Type in a custom response (mp2)

2010-03-11 Thread Steve Hay
I have a mod_perl-2 handler that uses custom_response() to display error messages if something goes wrong: $r->custom_response(Apache2::Const::SERVER_ERROR, $error); return Apache2::Const::SERVER_ERROR; That almost works fine, but the trouble is that the Content-Type header is always set to "text

Upgrading chained response handlers to mod_perl2

2010-03-11 Thread Iain Kennedy
Hi, I'm in the process of upgrading an application to mod_perl2. The application currently relies on chained content handlers. Each PerlResponseHandler in the chain uses the following mechanism to get (and then process) the requested file: $r->filter_register; my ($fh, $status) = $self->{'r'}->fi