Skip to main content.
home | support | download

Back to List Archive

Re: Configuring search.cgi to run w/mod_perl

From: Michael Peters <mpeters(at)not-real.plusthree.com>
Date: Thu Aug 18 2005 - 16:51:04 GMT
Edmund Peirce wrote:
> hey all,
> 
> Sorry for cluttering the list about this, I'm learning as I go, i'm
> new to mod_perl, and apache, so bear with me, if you would.
> 
> I have a simple installation of swish-e, everything is working fine,
> except when I try to configure apache(apache2) to run the search.cgi
> script as a mod_perl handler. I've tried the various examples in the
> documentation on how to do this, however, to be honest, I'm really
> having trouble understanding apaches config syntax - anytime I change
> something, I usually get fatal syntax errors, and my server doesn't
> load. My setup is very basic: one index, and one site being spidered.
> The cgi script runs fine (located in /cgi-bin/search.cgi), and I am
> loading the mod_perl module fine.
> 
> Is there a simple <perl></perl> directive I can add to httpd.conf to
> get search.cgi to run as a mod_perl handler?  I'm about to just leave
> it handled as it is, but I felt I should ask the list before I give up
> entirely.

Are you trying to just run search.cgi under mod_perl? or run it
explicityly as a handler? You can run most 'clean' CGI scripts using
Apache::Registry and almost all dirty ones using Apache::PerlRun. This
would be my suggestion.

Take a look at:
http://perl.apache.org/docs/1.0/guide/getwet.html#Porting_Existing_CGI_Scripts_to_run_under_mod_perl

There are some speed differences between straight handlers and registry
scripts, but they are hardly noticeable and almost never a bottleneck.

-- 
Michael Peters
Developer
Plus Three, LP
Received on Thu Aug 18 09:51:13 2005