in reply to Seems simple enough how do I redirect old cgi scripts to mod perl?

You don't need to move the script. You can leave it in the cgi-bin directory and put in a <Location> block with the full URL of the individual script, and specify the SetHandler and Apache::Registry stuff in there.
  • Comment on Re: Seems simple enough how do I redirect old cgi scripts to mod perl?

Replies are listed 'Best First'.
Re^2: Seems simple enough how do I redirect old cgi scripts to mod perl?
by ManagedLinks (Initiate) on Oct 01, 2005 at 00:07 UTC
    Wow thanks guys for all the input. Damn (oops not very monkish) I should have joined here years ago.

    I am just learning the ins and outs of mod_perl so I followed the instructions of how to set it up

    didn't even think of setting the individual script to a mod_perl script. just stuck to the paradigm of a directory


    I'll try this solution

    <Location /cgi-bin/mlserver.pl>
    SetHandler perl-script
    PerlHandler Apache::Registry
    Options ExecCGI
    allow from all
    PerlSendHeader On
    </Location>

    its great because it also cuts out the rewrite requirement

    Rewrite the script as an apache handler ... Great idea that would be much faster. I'll have to work out how to talk to mySQL from Apache but I am sure theres lots of info about that lying around.

    Steve I already ruled out a "redirect" because the script is called thousands of times per hour and the client times out if there is no response within 5 seconds.

    I can't afford the extra time and network activity a redirect introduces.

    Great Answers guys I'm impressed :) And your probably saying "Doh".
    I'll get there