Gossamer Forum
Home : General : Perl Programming :

Help with installing mod_perl

Quote Reply
Help with installing mod_perl
Hi,

I wondered if anyone could give me a hand with installing mod_perl on my server.

AFAIK I've compiled mod_perl okay, but I cannot get Apache to work with it.

I've re-built Apache with "--activate-module=src/modules/perl/libperl.a" and it went okay and passed the "./apachectl configtest".

However, when I restarted Apache it wouldn't serve pages - I kept getting 'Document Contains No Data' errors on anything and everything from my server.

I'm also missing a libperl.so file, or rather I'm not sure how to make one or even if I need one (somewhere in the docs there's a reference to adding a line to httpd.conf for this file)?

If anyone can offer me assistance I'd really appreciate it Blush

Many thanks.
Shaun
Quote Reply
Re: [qango] Help with installing mod_perl In reply to
Take a look here:

http://perl.apache.org/guide/
http://perl.apache.org/...iguration_perl_Makef
http://perl.apache.org/...iguration_parameters

.....you'll be reading for a week but it should help Blush.

Last edited by:

RedRum: Feb 12, 2002, 12:47 PM
Quote Reply
Re: [RedRum] Help with installing mod_perl In reply to
Paul,

Thanks - that helped, I've now compiled libperl.so

Unfortunately when I restart Apache after loading the libperl.so module, Apache stops serving pages and instead I get "Document Contains No Data" errors when I request a page, directory, etc. As soon as I remove the directive, everything returns to normal?

Any idea what could be happening here?

Thanks.
Shaun
Quote Reply
Re: [qango] Help with installing mod_perl In reply to
Anything in the error logs?

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Help with installing mod_perl In reply to
Hi Alex,

Yes, Apache restarts normally then immediately the following lines start appearing in Apache's error_log:

[Wed Feb 13 01:14:17 2002] [notice] child pid 15820 exit signal Segmentation fault (11)
[Wed Feb 13 01:14:33 2002] [notice] child pid 15818 exit signal Segmentation fault (11)
[Wed Feb 13 01:14:37 2002] [notice] child pid 15824 exit signal Segmentation fault (11)
[Wed Feb 13 01:14:40 2002] [notice] child pid 15816 exit signal Segmentation fault (11)

Does this help to identify the potential problem?

Also, am I correct in thinking that I can have mod_perl restricted to a specific directory, e.g.; /cgi-mod/ - and put all my mod_perl compliant scripts there?


Thanks.
Shaun
Quote Reply
Re: [qango] Help with installing mod_perl In reply to
Thanks for the replies.

I tried mod_perl-1.26 (was using 1.25), build it as a dynamic module and it now works fine.

All the best
Shaun

PS. I found a resource that mentioned the seg-faults related to "building mod_perl with the same (gcc) compiler as you've used to build perl".

My ISP has recenlty build 5.6.1 for me, so I didn't know how they'd compiled it.
Quote Reply
Re: [qango] Help with installing mod_perl In reply to
I've just experienced this same error compiling mod_perl

I followed the instructions perfectly....and now I get the segmentation fault.

Perl 5.6.1
Apache 1.3.24
mod_perl 1.26


perl Makefile.PL APACHE_SRC=/root/apache_1.3.24/src \
DO_HTTPD=1 \
USE_APACI=1 \
EVERYTHING=1 \
USE_DSO=1

./configure --prefix=/usr/local/apache \
--enable-module=most \
--enable-shared=max \
--activate-module=src/modules/perl/libperl.a \
--enable-module=so


...but I just get "Cannot find server" (even though trying to start apache says it is already running and I can see httpd processes ugh)

Last edited by:

Paul: May 9, 2002, 6:30 AM
Quote Reply
Re: [qango] Help with installing mod_perl In reply to
Hmm I managed to fix this with:

killall httpd

/usr/local/apache/bin/apachectl graceful

I must have had some old processes that were causing problems. After I did that apache restarted and Links SQL was _so_ fast.