You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by George Carrette <Ge...@iacnet.com> on 1997/06/26 14:21:21 UTC

Making RLimitMEM and RLimitCPU work for httpd children

Because application developers here are making heavy use of the Perl Module
I found it *prudent* to modify the apache 1.2.0 so that RLimitMEM and RLimitCPU
because it is fairly easy to get into infinite loops in perl programs,
especialling when using CGI.pm, evidently.

The changes are described here: http://cpartner.iacnet.com/apache/
along with changed files and differences between these files
and the original 1.2.0 sources.

Pretty limited changes actually.

Re: Making RLimitMEM and RLimitCPU work for httpd children

Posted by Dean Gaudet <dg...@arctic.org>.
I took a look at this George, your example makes it seem like the Rlimit
applies only to things in /cgi-bin.  But I'm guessing the code imposes
these limits process wide all the time, so it's slightly misleading.

In order to integrate something like this into the server as a feature
we'd need a directive that says "apply resource limits to httpd child
in addition to cgis".  And it'd be nice if it could use getrusage() to
setrlimit() appropriate soft values on a per-request basis (and then
remove the limits at the end of the request).  That would be a cool
feature to have.

Dean

P.S. We need context diffs (diff -c3) to apply things against HEAD.

On Thu, 26 Jun 1997, George Carrette wrote:

> Because application developers here are making heavy use of the Perl Module
> I found it *prudent* to modify the apache 1.2.0 so that RLimitMEM and RLimitCPU
> because it is fairly easy to get into infinite loops in perl programs,
> especialling when using CGI.pm, evidently.
> 
> The changes are described here: http://cpartner.iacnet.com/apache/
> along with changed files and differences between these files
> and the original 1.2.0 sources.
> 
> Pretty limited changes actually.
>