Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PerlInitHandler My::ProxyRemoteAddr

Status
Not open for further replies.

DavePnP

Programmer
Oct 20, 2004
4
0
0
US
I am setting up a light/heavy reverse proxy. I'm using ProxyRemoteAddr to capture the IP address of the client.

The heavy version using Mod_Perl.

Our perl modules are stored in a "non-standard" directory and the scripts that reference these modules all have a 'use lib' statment so the scripts know where to find the appropriate modules.

When using the light heavy configuration I can run a script multiple times as long as the script only requires the same set of modules each time. If I call the script with a different set of parameters which would require it to call a different set of modules then it dies with the error message that it could not find the requested module in @INC. If I reverse the order the error still happens when the script is called the second time.

I traced this issue to the use of: ProxyRemoteAddr. If I do not call this routine then the problem does not occur. It is as if the module list is "locked" when the script is first called and subsequent calls will not load any new modules.

If I add the 'use lib' statment to the startup script the problem also goes away.

I would however like to understand why this is occurring.

Any help/insight is greatly appreciated.

Thanks.











 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top