in reply to Re^2: Help with Apache::RegistryLoader
in thread Help with Apache::RegistryLoader

You still don't give enough information about the problem, but if you can't get it to work, lets try a work-around:
Why don't you try to use a 'startup.pl' script to compile your modules in the first apache server?
example for apache2:
# in /etc/apache2/mods-enabled/perl.conf: PerlModule Apache2 PerlModule ModPerl::Registry PerlInitHandler Apache::Reload PerlRequire /etc/apache2/startup.pl # in /etc/apache2/startup.pl use lib qw(/var/www/cgi-bin /var/www/cgi-bin/modules); use DBI; use CGI qw(:cgi); use File::Find; use HTML::Template; use OwnModulesHere; print STDERR "Pre-loading HTML Templates...\n"; if (1) { find( sub { return unless /\.tmpl$/; HTML::Template->new( filename => "$File::Find::dir/$_", cache => 1, ); }, '/var/www/TemplatesFolder', ); }
"We all agree on the necessity of compromise. We just can't agree on when it's necessary to compromise." - Larry Wall.

Replies are listed 'Best First'.
Re^4: Help with Apache::RegistryLoader
by Anonymous Monk on Jul 08, 2005 at 05:29 UTC
    well tried using use lib in my startup.pl file. but doesn't seem to be doing anything.

    use CGI (); use Image::Size (); use Imager (); use strict; use CGI::Carp qw(fatalsToBrowser); CGI->compile(':all'); use lib ("cgi-bin/beta.pl"); use lib ("cgi-bin/betaupload.pl"); BEGIN { unshift(@INC, '/var/www/perl'); } 1;
      eh, use lib is to tell perl where to look for modules:
      #when using use lib ("/home/user/usermods/") #and your script is in /usr/local/somewhere/script.pl. #calling use MyOwnModule; #it's searching in /home/user/usermods/ as well.
      "We all agree on the necessity of compromise. We just can't agree on when it's necessary to compromise." - Larry Wall.