Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Perl app won't compile /run from cron

by dave_the_m (Monsignor)
on May 23, 2018 at 21:49 UTC ( [id://1215116]=note: print w/replies, xml ) Need Help??


in reply to Perl app won't compile /run from cron

Perl usually gets extra module paths from the PERL5LIB environment variable rather than PATH. So that would be the first thing to look at.

Also, its possible that cron and the terminal are running as different users (and so with different file/directory permissions), or are using different versions of the perl executable. You can see where the module is being loaded from the terminal by using:

$ perl -le 'require Image::Grab; print $INC{"Image/Grab.pm"}' /some/path/lib/Image/Grab.pm
If that path isn't in the list of paths in the cron error message, that's another place to investigate.

Dave.

Replies are listed 'Best First'.
Re^2: Perl app won't compile /run from cron
by haukex (Archbishop) on May 23, 2018 at 21:52 UTC
    ... or are using different versions of the perl executable.

    Excellent points, and that reminds me of another piece of advice I've learned the hard way (a few times ;-) ): Always use absolute paths in crontab.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1215116]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others taking refuge in the Monastery: (3)
As of 2024-04-25 16:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found