You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Roelf Diedericks <ro...@inet.co.za> on 2002/11/11 23:10:03 UTC

CGI hangs with Modperl::Registry and apache2.

I've tried a whole lot of things to get a simple product called
 "yabb Gold SP1" (Yet Another Bulletin Board, available at

http://www.yabbforum.com/downloads.php?file=./downloads/Y1Gold_SP1.1_pl.zip)
working with modperl-2, and apache on Win32.

Yabb is a basic forum/bulletin board system that uses textfiles for storage,
so no database is required.

Try number 1:
apache_2.0.43-win32-x86-no_ssl.msi, ActivePerl-5.6.1.633-MSWin32-x86.msi
and mod_perl2 (ftp://theoryx5.uwinnipeg.ca/pub/other/Apache2.tar.gz)

No luck. The script simply hangs. All amount of debugging showed that it
hangs
when it does the first jump into a subroutine  &LoadCookies(); in the code.

It never even reaches the sub. All amounts of debugging the 'require's etc
turned
out fine, no problems there. The first jump to a sub, defined in an external
file
seemed to kill apache. The apache child actually dies.

Attempt number 2:
Using Randy's huge perl-5.8-win32-bin.tar.gz default extract, and install.
At least the script runs partially (I get some output) but the apache slave
still
dies somewhere near the end of processing the cgi.

The relevant httpd.conf section I added everytime was:
 <Location /yabb>
      PerlHandler ModPerl::Registry
      Options +ExecCGI
      PerlOptions +ParseHeaders
</Location>

I've also tried these tests with ModPerl::PerlRun, to even worse effect.

I've been able to use HTML::Mason quite brilliantly but I really need
yabb for a current project. I'm just about to give up on mod_perl and
apache on win32 as being too unstable for this project, and I'm not
interested in trying apache 1.3.x on win32 due to the threading issues.

If something like fastcgi was available for apache2 (yet) I'd have used that
in the meantime just to get this CGI  script's performance going.

Has anyone else tried any large-ish CGI scripts under apache2-win32
and modperl and gotten good results? If you have, I'd love to hear about
it, even if just to keep my spirits up. :) Yabb, is the first rather complex
CGI I've tried under mod_perl and the results look grim.

Final question to the list:
Has anyone else noticed the extraordinary startup times for apache2 when
mod_perl is used, and you have a couple of handlers defined?


Roelf Diedericks
Internet Architect
I-Net Bridge (Pty) Ltd.
Johannesburg
South Africa
w) +27-11-2800600
h) +27-11-4862454
e) roelfd at inet.co.za


Re: CGI hangs with Modperl::Registry and apache2.

Posted by Randy Kobes <ra...@theoryx5.uwinnipeg.ca>.
On Tue, 12 Nov 2002, Roelf Diedericks wrote:

> Randy, wouldn't it be a good idea to compile your binary distributions
> of mod_perl2 with MP_TRACE enabled, so that we can use
> PerlTrace when testing mod_perl2? 
> 
> It would just make it easier for compiler lazy people like myself, and 
> might help us aid the developers in tracking down niggly problems 
> such as this.

That's true, but to get the full debug functionality, one would
have to compile perl, apache, and mod_perl with debugging
enabled. And not everyone would want that by default, as it comes
with speed and size penalties. Also, even with this, it's easier
to debug things in this context with Visual Studio present, and
if you have this, it'd be better to compile it yourself anyway.  
Perhaps, if there's enough of a demand, I could make up a package
with debugging enabled; that might be worth it at this
development stage to help track problems like the ones you've
encountered.

-- 
best regards,
randy


Re: CGI hangs with Modperl::Registry and apache2.

Posted by Roelf Diedericks <ro...@inet.co.za>.
Randy, wouldn't it be a good idea to compile your binary distributions
of mod_perl2 with MP_TRACE enabled, so that we can use
PerlTrace when testing mod_perl2? 

It would just make it easier for compiler lazy people like myself, and 
might help us aid the developers in tracking down niggly problems 
such as this.

Pardon the previous direct email. I didn't look before replying :)

Regards,
Roelf Diedericks.


Re: CGI hangs with Modperl::Registry and apache2.

Posted by Randy Kobes <ra...@theoryx5.uwinnipeg.ca>.
On Tue, 12 Nov 2002, Roelf Diedericks wrote:

> I've tried a whole lot of things to get a simple product called
>  "yabb Gold SP1" (Yet Another Bulletin Board, available at 
> http://www.yabbforum.com/downloads.php?file=./downloads/Y1Gold_SP1.1_pl.zip)
> working with modperl-2, and apache on Win32.
> 
> Yabb is a basic forum/bulletin board system that uses textfiles for storage,
> so no database is required.
> 
> Try number 1:
> apache_2.0.43-win32-x86-no_ssl.msi, ActivePerl-5.6.1.633-MSWin32-x86.msi
> and mod_perl2 (ftp://theoryx5.uwinnipeg.ca/pub/other/Apache2.tar.gz)
> 
> No luck. The script simply hangs. All amount of debugging
> showed that it hangs when it does the first jump into a
> subroutine &LoadCookies(); in the code.  It never even reaches
> the sub. All amounts of debugging the 'require's etc turned out
> fine, no problems there. The first jump to a sub, defined in an
> external file seemed to kill apache. The apache child actually
> dies.

Others have also noticed this problem - it seems to be with
some threading stuff in 5.6.1 that is improved in 5.8.

> 
> Attempt number 2: Using Randy's huge perl-5.8-win32-bin.tar.gz
> default extract, and install. At least the script runs
> partially (I get some output) but the apache slave still dies
> somewhere near the end of processing the cgi.

Any error messages when it dies? Can you track down
where it dies?

> 
> The relevant httpd.conf section I added everytime was:
>  <Location /yabb>
>       PerlHandler ModPerl::Registry
>       Options +ExecCGI
>       PerlOptions +ParseHeaders
> </Location>
> 
> I've also tried these tests with ModPerl::PerlRun, to even worse effect.
> 
> I've been able to use HTML::Mason quite brilliantly but I really need
> yabb for a current project. I'm just about to give up on mod_perl and
> apache on win32 as being too unstable for this project, and I'm not
> interested in trying apache 1.3.x on win32 due to the threading issues.

mod_perl-2 is still in the development stage. To try to track
the problem down ...
- does this work as an ordinary cgi script satisfactorily?
- does it 'use strict' and 'use warnings'?
- is it known to work on mod_perl-2/Apache-2 on linux?

-- 
best regards,
randy kobes