You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by John Deighan <jd...@pcgus.com> on 2011/01/26 16:17:45 UTC

experiencing Out of memory errors

We have an Apache/mod_perl application running under Windows Server 2003
that periodically experiences
"Out of memory" errors (they appear in the Apache error logs) which
forces Apache to restart. Our application does, in fact, use a lot of
memory, and we believe that this is not due to a bug or memory leak.
What we would like is to run this application in a 64 bit environment, thus
allowing us to use more than the 2 GB memory that the Apache process ('httpd')
is limited to (the "Out of memory" errors always occur as the memory usage
of the httpd process approaches this 2 GB limit).

We know that we will need to run a 64 bit version of Windows on 64 bit
hardware to accomplish this. Furthermore, we know that ActiveState has a
binary Perl install of a 64 bit Perl. However, we're not aware of either a
64 bit Apache (though recently I found the blackdot site -
http://www.blackdot.be/ - that provides a Windows compatible binary build
of 64 bit apache, though I know very little about it) or a 64 bit mod_perl.
However, we're also not sure if either of these are needed to escape the
2 GB memory limitation. E.g., can 64 bit Perl be used with a 32 bit
Apache and/or mod_perl?

Any help with accomplishing what we need would be greatly appreciated,
including the possibility of hiring someone on a contract basis to
help us.



OS: Microsoft Windows Server 2003
Perl: v 5.8.9 ActiveState build 826
Apache 2.2.11
mod_perl 2 (not sure of the exact version, but very recent)

Re: experiencing Out of memory errors

Posted by Zeno Davatz <zd...@gmail.com>.
Hi 

Am 27.01.2011 um 12:57 schrieb Michiel Beijen <mi...@otrs.com>:

> Hi John,
> 
> On Wed, 2011-01-26 at 10:17 -0500, John Deighan wrote:
>> However, we're also not sure if either of these are needed to escape the
>> 2 GB memory limitation. E.g., can 64 bit Perl be used with a 32 bit
>> Apache and/or mod_perl?
> 
> You should use the same architecture for Perl and Apache.
> 
>> Any help with accomplishing what we need would be greatly appreciated,
>> including the possibility of hiring someone on a contract basis to
>> help us.
> 
> Probably because of the fact that the Apache foundation does not ship
> 64-bit builds for Windows (which is a shame!), ActiveState does not ship
> a mod_perl with their 64- bit Perl. Compiling your own mod_perl would be
> possible but you need to use preferably the same compiler that was used
> for Apache + perl.
> 
> If you would want to switch to StrawberryPerl 5.12.x 64-bit, you can use
> this pre-compiled mod_perl:
> http://strawberryperl.com/package/kmx/mod_perl/

Is mod_perl compiled with MinGW or with cl.exe for windows?

Seems that apxs suggest MinGW.

I got the same problem with mod_ruby for windows.

Best
Zeno

Re: experiencing Out of memory errors

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

On Thu, January 27, 2011 15:10, John Deighan wrote:
> One question, though: I'm thinking there's not much point to using a
> 64-bit version of mod_perl
> unless I'm using it with a 64-bit version of Apache. Where can I get a
> 64-bit version of Apache that
> will with with the mod_perl below?

You're right, you should not use 64-bit perl with a 32-bit apache
You should get the one from Blackdot probably:
http://www.blackdot.be/?inc=apache/binaries

--
Mike


Re: experiencing Out of memory errors

Posted by John Deighan <jd...@pcgus.com>.
I'd forgotten about Strawberry Perl (came across it about a year ago, but never got around to trying 
it). One question, though: I'm thinking there's not much point to using a 64-bit version of mod_perl 
unless I'm using it with a 64-bit version of Apache. Where can I get a 64-bit version of Apache that 
will with with the mod_perl below?

On 1/27/2011 6:57 AM, Michiel Beijen wrote:
> Hi John,
>
> ... etc.
>
> If you would want to switch to StrawberryPerl 5.12.x 64-bit, you can use
> this pre-compiled mod_perl:
> http://strawberryperl.com/package/kmx/mod_perl/
>
> --
> Mike

[users@httpd] Re: experiencing Out of memory errors

Posted by John Deighan <jd...@pcgus.com>.
I'd forgotten about Strawberry Perl (came across it about a year ago, but never got around to trying 
it). One question, though: I'm thinking there's not much point to using a 64-bit version of mod_perl 
unless I'm using it with a 64-bit version of Apache. Where can I get a 64-bit version of Apache that 
will with with the mod_perl below?

On 1/27/2011 6:57 AM, Michiel Beijen wrote:
> Hi John,
>
> ... etc.
>
> If you would want to switch to StrawberryPerl 5.12.x 64-bit, you can use
> this pre-compiled mod_perl:
> http://strawberryperl.com/package/kmx/mod_perl/
>
> --
> Mike

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


[users@httpd] Re: experiencing Out of memory errors

Posted by Zeno Davatz <zd...@gmail.com>.
Hi 

Am 27.01.2011 um 12:57 schrieb Michiel Beijen <mi...@otrs.com>:

> Hi John,
> 
> On Wed, 2011-01-26 at 10:17 -0500, John Deighan wrote:
>> However, we're also not sure if either of these are needed to escape the
>> 2 GB memory limitation. E.g., can 64 bit Perl be used with a 32 bit
>> Apache and/or mod_perl?
> 
> You should use the same architecture for Perl and Apache.
> 
>> Any help with accomplishing what we need would be greatly appreciated,
>> including the possibility of hiring someone on a contract basis to
>> help us.
> 
> Probably because of the fact that the Apache foundation does not ship
> 64-bit builds for Windows (which is a shame!), ActiveState does not ship
> a mod_perl with their 64- bit Perl. Compiling your own mod_perl would be
> possible but you need to use preferably the same compiler that was used
> for Apache + perl.
> 
> If you would want to switch to StrawberryPerl 5.12.x 64-bit, you can use
> this pre-compiled mod_perl:
> http://strawberryperl.com/package/kmx/mod_perl/

Is mod_perl compiled with MinGW or with cl.exe for windows?

Seems that apxs suggest MinGW.

I got the same problem with mod_ruby for windows.

Best
Zeno

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: experiencing Out of memory errors

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

On Wed, 2011-01-26 at 10:17 -0500, John Deighan wrote:
> However, we're also not sure if either of these are needed to escape the
> 2 GB memory limitation. E.g., can 64 bit Perl be used with a 32 bit
> Apache and/or mod_perl?

You should use the same architecture for Perl and Apache.

> Any help with accomplishing what we need would be greatly appreciated,
> including the possibility of hiring someone on a contract basis to
> help us.

Probably because of the fact that the Apache foundation does not ship
64-bit builds for Windows (which is a shame!), ActiveState does not ship
a mod_perl with their 64- bit Perl. Compiling your own mod_perl would be
possible but you need to use preferably the same compiler that was used
for Apache + perl.

If you would want to switch to StrawberryPerl 5.12.x 64-bit, you can use
this pre-compiled mod_perl:
http://strawberryperl.com/package/kmx/mod_perl/

--
Mike


Re: [users@httpd] Authentication based on QUERY STRING

Posted by Björn Zettergren <bj...@basefarm.se>.
On 01/26/2011 06:52 PM, Rich Bowen wrote:
>
> On Jan 26, 2011, at 10:52 AM, J.Lance Wilkinson wrote:
>
>> I have a developer who's using Apache 1.3.9 (supplied as Oracle HTTP server within Oracle Application Express) and needs to SUPPRESS his default authentication (mod_cosign from weblogin.org) when the user's QUERY_STRING contains the string ":25:".  Otherwise he wants to continue to enforce his
>> authentication.
>>
>> Thoughts?
>
> My first thought is "Holy cow, 1.3.9 was released in August 1999. Why the heck are you using *that* dinosaur."
> Closely followed by, no, that's probably not possible, and especially not in something that ancient.

If you're stuck with that apache version due to oracle, you might be 
able to pull that off by having an apache 2.2 with mod_rewrite & 
mod_proxy in front of your current server, and do your 
authentication/bypassing there. However, if your server is publicly 
accessible, i'd look far and wide for a different "bypass" mechanism 
(rather, no bypass at all).

/Björn

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Authentication based on QUERY STRING

Posted by "J.Lance Wilkinson" <jl...@psulias.psu.edu>.
Mark Montague wrote:
> If you're ignoring the "remarkably bad idea" part of Rich's response, 
> above, here are some more ways to get in trouble:
> 
> - mod_cosign allows you to make authentication optional via the 
> CosignAllowPublicAccess directive.  If you are serving dynamic content 
> (a CGI, etc.), you (or your developer) can then have your dynamic 
> content (a CGI, etc.) force authentication if the user is not 
> authenticated and the query string does not contain ":25:", but allow 
> both authenticated and unauthenticated access otherwise.  For specifics 
> on how to implement this, ask on the cosign-discuss mailing list ( 
> https://lists.sourceforge.net/lists/listinfo/cosign-discuss ).  
> Unfortunately, this solution will not work for static content.
> 
> - You (or your developer) can modify mod_cosign to get what you need; 
> this is horrible and ugly, but probably easier than implementing your 
> own authentication mechanism. You'll probably want to add your 
> additional check (return DECLINED if the query string contains ":25:") 
> in the cosign source code near filters/apache/mod_cosign.c line 428.  
> Lines 209-222 of the same file provide an example of code that checks 
> the query string that could be rewritten for your needs.  See 
> http://cosign.git.sourceforge.net/git/gitweb.cgi?p=cosign/cosign;a=blob;f=filters/apache/mod_cosign.c;h=3a279745e70acef52211678e2a6a3acb89392a04;hb=HEAD 

	ABSOLUTELY not a consideration, so don't worry on that one.

	Admittedly, I was hoping that some other folks (as yet unasked)
	would tell me I'd missed some delightful feature in MOD_COSIGN
	that would allow me to put some kind of env= optionality onto
	the CosignProtected directive...  But this whole discussion has
	proven the fool heartiness of that, too.

> 
>> Again, this seems like a really bad idea.
> 
> The above bears repeating (if it's not obvious why its a bad idea, let 
> us know so we can explain).
> 
> WHY does your developer think he needs to bypass authentication based on 
> what's in the query string?  Knowing the details of the situation may 
> allow us to suggest an alternative solution.  Remind your developer of 
> http://www.catb.org/~esr/faqs/smart-questions.html#goal


	Well, I've asked this question already.   Seems that the 3 DYNAMIC
	pages of content that will not require authentication are being rolled
	into the other DYNAMIC pages which do.   They (not sure who THEY are,
	perhaps the application's customer, perhaps the developer's supervisor,
	or somebody else along the hierarchy) want it all in the same DNS
	name and Oracle application.

	After floating some alternatives back to him, I offered to pass on
	the conceptual request to this august group on the off chance it wasn't
	as ill-advised as I suspected.  Turns out, however, that it's even more
	ill-advised than I'd suspected.

-- 
J.Lance Wilkinson ("Lance")		InterNet: Lance.Wilkinson@psu.edu
Systems Design Specialist - Lead	Phone: (814) 865-4870
Digital Library Technologies		FAX:   (814) 863-3560
E3 Paterno Library
Penn State University
University Park, PA 16802

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Authentication based on QUERY STRING

Posted by Mark Montague <ma...@catseye.org>.
  On January 26, 2011 13:48 , Rich Bowen <rb...@rcbowen.com>  wrote:
>>> On Jan 26, 2011, at 10:52 AM, J.Lance Wilkinson wrote:
>>>> I have a developer who's using Apache 1.3.9 (supplied as Oracle HTTP server within Oracle Application Express) and needs to SUPPRESS his default authentication (mod_cosign from weblogin.org) when the user's QUERY_STRING contains the string ":25:".  Otherwise he wants to continue to enforce his
>>>> authentication.
>
> Meanwhile, suppressing authentication based on a query string argument is not easy simply because it's a remarkably bad idea, as it undermines the very notion of authentication. However, if you must do this, then you'll probably need to implement your own authentication mechanism. HTTP auth happens too early in the process for what you're trying to do.
>
> The only solution that comes to mind is to have a front-end server that looks at the query string (say, mod_rewrite) and rewrites the request to an un-auth copy of the content when the query string has the right magic string in it.


If you're ignoring the "remarkably bad idea" part of Rich's response, 
above, here are some more ways to get in trouble:

- mod_cosign allows you to make authentication optional via the 
CosignAllowPublicAccess directive.  If you are serving dynamic content 
(a CGI, etc.), you (or your developer) can then have your dynamic 
content (a CGI, etc.) force authentication if the user is not 
authenticated and the query string does not contain ":25:", but allow 
both authenticated and unauthenticated access otherwise.  For specifics 
on how to implement this, ask on the cosign-discuss mailing list ( 
https://lists.sourceforge.net/lists/listinfo/cosign-discuss ).  
Unfortunately, this solution will not work for static content.

- You (or your developer) can modify mod_cosign to get what you need; 
this is horrible and ugly, but probably easier than implementing your 
own authentication mechanism. You'll probably want to add your 
additional check (return DECLINED if the query string contains ":25:") 
in the cosign source code near filters/apache/mod_cosign.c line 428.  
Lines 209-222 of the same file provide an example of code that checks 
the query string that could be rewritten for your needs.  See 
http://cosign.git.sourceforge.net/git/gitweb.cgi?p=cosign/cosign;a=blob;f=filters/apache/mod_cosign.c;h=3a279745e70acef52211678e2a6a3acb89392a04;hb=HEAD


> Again, this seems like a really bad idea.

The above bears repeating (if it's not obvious why its a bad idea, let 
us know so we can explain).

WHY does your developer think he needs to bypass authentication based on 
what's in the query string?  Knowing the details of the situation may 
allow us to suggest an alternative solution.  Remind your developer of 
http://www.catb.org/~esr/faqs/smart-questions.html#goal

--
   Mark Montague
   mark@catseye.org


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Authentication based on QUERY STRING

Posted by Rich Bowen <rb...@rcbowen.com>.
On Jan 26, 2011, at 1:38 PM, J.Lance Wilkinson wrote:

> Rich Bowen wrote:
>> On Jan 26, 2011, at 10:52 AM, J.Lance Wilkinson wrote:
>>> I have a developer who's using Apache 1.3.9 (supplied as Oracle HTTP server within Oracle Application Express) and needs to SUPPRESS his default authentication (mod_cosign from weblogin.org) when the user's QUERY_STRING contains the string ":25:".  Otherwise he wants to continue to enforce his
>>> authentication.
>>> 
>>> Thoughts?
>> My first thought is "Holy cow, 1.3.9 was released in August 1999. Why the heck are you using *that* dinosaur."
>> Closely followed by, no, that's probably not possible, and especially not in something that ancient.
> 
> 	I'm certainly inclined to agree with you, but apparently Oracle
> 	disagrees.  There are apparently a multitude of custom Oracle
> 	modules which clearly, if they had Apache 2.x or Apache 2.2.x versions
> 	for, would be distributed and available thus making later versions
> 	of Apache feasible.

If those modules worked on 1.3.9, they would also work on 1.3.42, which, while hardly cutting edge, was at least released this century.

Meanwhile, suppressing authentication based on a query string argument is not easy simply because it's a remarkably bad idea, as it undermines the very notion of authentication. However, if you must do this, then you'll probably need to implement your own authentication mechanism. HTTP auth happens too early in the process for what you're trying to do.

The only solution that comes to mind is to have a front-end server that looks at the query string (say, mod_rewrite) and rewrites the request to an un-auth copy of the content when the query string has the right magic string in it.

Again, this seems like a really bad idea.

--
Rich Bowen
rbowen@rcbowen.com


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Authentication based on QUERY STRING

Posted by "J.Lance Wilkinson" <jl...@psulias.psu.edu>.
Rich Bowen wrote:
> On Jan 26, 2011, at 10:52 AM, J.Lance Wilkinson wrote:
> 
>> I have a developer who's using Apache 1.3.9 (supplied as Oracle HTTP server within Oracle Application Express) and needs to SUPPRESS his default authentication (mod_cosign from weblogin.org) when the user's QUERY_STRING contains the string ":25:".  Otherwise he wants to continue to enforce his
>> authentication.
>>
>> Thoughts?
> 
> My first thought is "Holy cow, 1.3.9 was released in August 1999. Why the heck are you using *that* dinosaur."
> Closely followed by, no, that's probably not possible, and especially not in something that ancient.

	I'm certainly inclined to agree with you, but apparently Oracle
	disagrees.  There are apparently a multitude of custom Oracle
	modules which clearly, if they had Apache 2.x or Apache 2.2.x versions
	for, would be distributed and available thus making later versions
	of Apache feasible.

-- 
J.Lance Wilkinson ("Lance")		InterNet: Lance.Wilkinson@psu.edu
Systems Design Specialist - Lead	Phone: (814) 865-4870
Digital Library Technologies		FAX:   (814) 863-3560
E3 Paterno Library
Penn State University
University Park, PA 16802

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Authentication based on QUERY STRING

Posted by Rich Bowen <rb...@rcbowen.com>.
On Jan 26, 2011, at 10:52 AM, J.Lance Wilkinson wrote:

> I have a developer who's using Apache 1.3.9 (supplied as Oracle HTTP server within Oracle Application Express) and needs to SUPPRESS his default authentication (mod_cosign from weblogin.org) when the user's QUERY_STRING contains the string ":25:".  Otherwise he wants to continue to enforce his
> authentication.
> 
> Thoughts?

My first thought is "Holy cow, 1.3.9 was released in August 1999. Why the heck are you using *that* dinosaur."
Closely followed by, no, that's probably not possible, and especially not in something that ancient.

--
Rich Bowen
rbowen@rcbowen.com


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


[users@httpd] Authentication based on QUERY STRING

Posted by "J.Lance Wilkinson" <jl...@psulias.psu.edu>.
I have a developer who's using Apache 1.3.9 (supplied as Oracle HTTP server 
within Oracle Application Express) and needs to SUPPRESS his default 
authentication (mod_cosign from weblogin.org) when the user's QUERY_STRING 
contains the string ":25:".  Otherwise he wants to continue to enforce his
authentication.

Thoughts?

-- 
J.Lance Wilkinson ("Lance")		InterNet: Lance.Wilkinson@psu.edu
Systems Design Specialist - Lead	Phone: (814) 865-4870
Digital Library Technologies		FAX:   (814) 863-3560
E3 Paterno Library
Penn State University
University Park, PA 16802

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: experiencing Out of memory errors

Posted by "William A. Rowe Jr." <wr...@rowe-clan.net>.
On 1/27/2011 7:16 PM, Michael Peters wrote:
> On 01/27/2011 07:41 PM, Michael Ludwig wrote:
>> Michael Peters schrieb am 27.01.2011 um 19:14 (-0500):
>>
>>> But, even after all that I have applications where we consistently
>>> run 3-4G just for mod_perl/Apache.
>>
>> But surely not in one process as the OP said he'd like to do?
> 
> No you're right, but I'm guessing he might be running a threaded MPM, so single process,
> multiple threads.

Exactly.  Even constraining httpd to smaller stacks is unlikely to be wise
with mod_perl running, consider the default is 256kb IIRC.  Shrinking this
to 128k obviously is a big help, but is unrealistic.

I agree with Peters, run a proxy in front of the server hosting mod_perl.
Even when we ship binary 64 bit for win32, there are far too many broken
perl and similar modules which don't expect sizeof(long*) > sizeof(long),
which has tripped up many porters.  Most of these defects are gone from
apr and httpd, and perl and modperl can likely catch up quickly, but to
isolate every possible modperl XS package on cpan and identify all those
which make stupid long x = (long)xptr; assignments will be arduous.

Re: experiencing Out of memory errors

Posted by Michael Peters <mp...@plusthree.com>.
On 01/27/2011 07:41 PM, Michael Ludwig wrote:
> Michael Peters schrieb am 27.01.2011 um 19:14 (-0500):
>
>> But, even after all that I have applications where we consistently
>> run 3-4G just for mod_perl/Apache.
>
> But surely not in one process as the OP said he'd like to do?

No you're right, but I'm guessing he might be running a threaded MPM, so 
single process, multiple threads.

-- 
Michael Peters
Plus Three, LP

Re: experiencing Out of memory errors

Posted by Michael Ludwig <mi...@gmx.de>.
Michael Peters schrieb am 27.01.2011 um 19:14 (-0500):

> But, even after all that I have applications where we consistently
> run 3-4G just for mod_perl/Apache.

But surely not in one process as the OP said he'd like to do?

-- 
Michael Ludwig

Re: Running a proxy in front of mod_perl on Win32

Posted by Perrin Harkins <pe...@elem.com>.
On Fri, Jan 28, 2011 at 3:31 AM, Michiel Beijen <mi...@otrs.com> wrote:
> On Fri, January 28, 2011 01:14, Michael Peters wrote:
>> Another thing that maybe the OP should look at (if he hasn't already) is
>> to run a proxy in front of the main mod_perl application. Even if the
>> proxy is on the same machine it will help because you can reduce the
>> number of memory-heavy mod_perl processes/threads and handle the same
>> number of connections.
>
> I have read that advice before; then it was because of this bug concerning
> running mod_ssl + mod_perl at the same time on Win32:
> https://issues.apache.org/bugzilla/show_bug.cgi?id=36751

Even if that problem is fixed, the advice to use a proxy server is good.

> What would be the best (windows-style) way of running a proxy in front of
> apache?

There are many proxy servers available.  If you search the list
archives for "proxy" you should find many posts discussing the pros
and cons of various ones.

- Perrin

Re: Running a proxy in front of mod_perl on Win32

Posted by Hendrik Schumacher <hs...@activeframe.de>.
Am Fr, 28.01.2011, 09:31, schrieb Michiel Beijen:
> On Fri, January 28, 2011 01:14, Michael Peters wrote:
>> Another thing that maybe the OP should look at (if he hasn't already) is
>> to run a proxy in front of the main mod_perl application. Even if the
>> proxy is on the same machine it will help because you can reduce the
>> number of memory-heavy mod_perl processes/threads and handle the same
>> number of connections.
>
> I have read that advice before; then it was because of this bug concerning
> running mod_ssl + mod_perl at the same time on Win32:
> https://issues.apache.org/bugzilla/show_bug.cgi?id=36751
>
> Unfortunately the bug still exists but the bug report was set to invalid
> because it did not get proper attention.
>
> What would be the best (windows-style) way of running a proxy in front of
> apache?
>
> Insights are welcome!
> --
> Mike
>
>

(Linux-style) I use nginx and it works great (by coping with ssl and
keep-alives) whether you allow it to cache requests or not. It can serve
thousands of simultaneous connections and still has just a memory
footprint of a few mb. I dont know if the event-model works as great under
windows but there are windows builds available on the website
(http://nginx.org) so it should be worth a try.

Hendrik


Running a proxy in front of mod_perl on Win32

Posted by Michiel Beijen <mi...@otrs.com>.
On Fri, January 28, 2011 01:14, Michael Peters wrote:
> Another thing that maybe the OP should look at (if he hasn't already) is
> to run a proxy in front of the main mod_perl application. Even if the
> proxy is on the same machine it will help because you can reduce the
> number of memory-heavy mod_perl processes/threads and handle the same
> number of connections.

I have read that advice before; then it was because of this bug concerning
running mod_ssl + mod_perl at the same time on Win32:
https://issues.apache.org/bugzilla/show_bug.cgi?id=36751

Unfortunately the bug still exists but the bug report was set to invalid
because it did not get proper attention.

What would be the best (windows-style) way of running a proxy in front of
apache?

Insights are welcome!
--
Mike


Re: experiencing Out of memory errors

Posted by Michael Peters <mp...@plusthree.com>.
On 01/27/2011 07:05 PM, Dave Hodgkinson wrote:

> Can I just say: WTF? 2G in an Apache? Surely there's a better way of architecting
> this?

One thing to remember is that he's running Windows which doesn't have 
Copy-On-Write memory, so depending on what he's doing it might not take 
up as much memory if it were being run on Linux (or other OS with COW).

Another thing that maybe the OP should look at (if he hasn't already) is 
to run a proxy in front of the main mod_perl application. Even if the 
proxy is on the same machine it will help because you can reduce the 
number of memory-heavy mod_perl processes/threads and handle the same 
number of connections.

But, even after all that I have applications where we consistently run 
3-4G just for mod_perl/Apache.

-- 
Michael Peters
Plus Three, LP

Re: experiencing Out of memory errors

Posted by Dave Hodgkinson <da...@gmail.com>.
On 26 Jan 2011, at 15:17, John Deighan wrote:

> What we would like is to run this application in a 64 bit environment, thus
> allowing us to use more than the 2 GB memory that the Apache process ('httpd')
> is limited to (the "Out of memory" errors always occur as the memory usage
> of the httpd process approaches this 2 GB limit).

Can I just say: WTF? 2G in an Apache? Surely there's a better way of architecting
this?