You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Tofu Optimist <to...@yahoo.com> on 2003/08/03 03:43:04 UTC

Ah, success.

Hi folks.  It is Saturday evening, 2 Aug 03, 9pm local
time, and I just got my modperl 2 and apache 2 running
on my dev box, built from source, and just ran my
first handler successfully.  Hurrah!!

I started on this wild adventure last Wednesday
evening, so it took me around 3.5 days, working on and
off.  Thanks to the good folks on this list for
helping me out, especially ged & perrin for their
patience and insightful posts.

I wanted to summarize  what I learned, in case it
helps someone else trying to do the same thing.  

CAUTION: I am a linux and apache and mod-perl NEWBIE;
please don�t take the following as gospel, I could be
(and likely am) wrong.  But hopefully my points below
will at least raise helpful issues.  At times I had
trouble as my knowledge was so rudimentary I couldn't
read between the lines in the docs and in the posts. 
(For example, why do the docs casually say "make &&
make test && make install", when in fact you have to
su over to root before the install step?  <g>)  

So here are my notes on this process:

* START CLEAN.  Before starting, get rid of any and
all old perls and apaches on the system.  I had
several instances of both due my installation
fumblings -- I opted to reinstall Red Hat 9 to start
fresh.  If you do this, make sure you ask RH to
install all the programming tools � on my first
reinstall, I opted for the �server� configuration,
which didn�t give me all the compiling tools needed,
and so had to reinstall it again.  Useful tools are
updatedb and locate, and rpm �e.  Took me a while to
realize I could use wget to pull down .tar.gz sources
via http; not knowing about wget, I was trying to get
everything through ftp and that was a drag.

* SEARCH IS YOUR FRIEND.  I really liked the interface
and search function at
http://www.gossamer-threads.com/archive/mod_perl_C1/. 
Amazing resource.  And  searching for key terms or
error messages on Google (main) and Google groups
gives a good a sense of what might be going on.

* MOD_PERL 2 IS STILL YOUNG.  I didn�t realize going
into this that at this point (2 Aug 03) Mod Perl 2 is
still pre-release.  Ack!  My ISP runs Apache 2 so
decided to install mod-perl 2, so I wanted AP2 and MP2
on my dev machine to match my ISP setup.  (Funny � he
got MP2 running in a few hours, vs. my 3.5 days � but
then again, this was also my introduction to linux,
apache, etc.)
 
* DON�T DO EVERYTHING AS ROOT.  Build and test all
packages as non-root, then su to root to make install.
 Don�t make and make test as root.  I did and ran into
troubles and had to start again.

* IF PERL DOESN�T PASS 100% OF ITS TESTS, STOP.  Build
perl 5.8.x first, and make sure it passes every test. 
Do not continue, do not pass go, do not collect $200 
until all the tests run.  I had to use EXPORT
LANG=en_us to get around the UTF bug in Perl 5.8.0. 

* CPAN IS YOUR FRIEND.  After building a successful
perl 5.8.0, I used CPAN to install (in this order) 
CGI, LWP, Bundle::LWP, HTML::Parser.  Now, I didn�t
get 100% clean installs on the last two, and (in
violation of the previous rule above) continued on
with my fingers crossed.

* DON�T MIX APACHE 1 AND APACHE 2 DOCS.  Without
realizing it, I was bouncing between the docs at the
mod_perl site for 1.0 and 2.0.  I didn�t realize how
different the two packages are.  Stay in one world or
the other.  The apache install went easily, following
the instructions online and in Stas� excellent book,
practical mod_perl.

* ONE ERROR.  The mod_perl install went smoothly too,
following the instructions online.  I did get one
error i: �filter/in_bbs_msg..............server side
has failed (response code: 404),see t/logs/error_log
for more details� but again I foolishly forged on
ignoring it.  Will this come back to haunt me?  I hope
not.  Anyone want to tell me what this means?

* DON�T MIX MODPERL1 AND MODPERL2 DOCS.  I read Stas�
book, Practical mod_perl, and really found it useful
and well-written.  But I thought the whole book was
about �mod-perl� � technically it isn�t.  Most of the
book is about MP1, and Chaps 24 and 25 are about MP2. 
My handlers were wrong, my httpd.conf was wrong � I
was trying to run MP1 stuff on MP2.  I made the same
mistake reading ModPerl Developer�s Cookbook.  The
fault was mine � MP 1 and MP 2 are quite different.  I
just didn�t know this going into this process.

* READ PRACTICAL MODPERL CHAP 23 �GETTING HELP AND
ONLINE RESOURCES� FIRST.  I noticed this chapter late
in the game.  Read it first.

Those are my tidbits of advice.  Good luck to you if
you are a newcomer, and thanks to the veterans for
providing all this great information, advice, and
encouragement --

A




__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com