Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

I'm running on SLES12, with apache 2.4.10 and mod_perl 2.0.8

In a vhost config file, I have a "PerlFixupHandler MyHandler" directive. Myhandler.pm is in /etc/apache2/script

If I do a perl -e'use MyHandler' from the commandline, everything works fine. But when it gets used from the server, it fails and is logging this in the error_log:

[Fri Aug 28 18:15:43.053198 2015] [perl:error] [pid 22133] [client x.x +.x.x:x] failed to resolve handler `MyHandler': Can't locate Digest/SH +A.pm: Permission denied at /etc/apache2/script/MyHandler.pm line 7. +\nBEGIN failed--compilation aborted at /etc/apache2/script/MyHandler. +pm line 7.\nCompilation failed in require at (eval 5) line 2.\n, refe +rer: https://x.x.x.x/

If I comment out the reference to Digest::SHA, it just fails on the next module.

For debugging, I added a BEGIN block to dump INC and to try and read the SHA.pm file, and that does not appear to cause any errors.

This configuration used to work fine on apache 2.2 ; I did some minimal updates to the configuration files for the new authentication stuff in 2.4, but nothing related to perl.

Any idea on what's wrong and how to fix it?

Edit: Here's the start of the .pm in question:

package MyHandler; use strict; use warnings; use Apache2::Const qw(:common); use Digest::SHA qw(sha256_hex sha1_hex); use OtherModule; use Apache2::RequestRec; use Apache2::RequestIO; use Apache2::Const; use Apache2::Log; use APR::Table; use CGI::Cookie; use Apache2::URI (); use APR::URI; use APR::Pool ();

In reply to apache 2.4 mod_perl permission denied on standard modules by Crackers2

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (6)
As of 2024-03-28 12:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found