The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Cron Issue with Perl

Discussion in 'General Discussion' started by Solokron, Apr 2, 2004.

  1. Solokron

    Solokron Well-Known Member

    Joined:
    Aug 8, 2003
    Messages:
    849
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    Seattle
    cPanel Access Level:
    DataCenter Provider
    I have a cron job in a user account as follows...

    /home/vwketnk/public_html/autos/cgi-bin/autorun.pl

    When I receive the output from cron to my email addresss I receive...

    Can't locate /home/vwketnk/common.inc in @INC (@INC contains: /usr/lib/perl5/5.8.1/i686-linux /usr/lib/perl5/5.8.1 /usr/lib/perl5/site_perl/5.8.1/i686-linux /usr/lib/perl5/site_perl/5.8.1 /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl/5.6.0 /usr/lib/perl5/site_perl .) at /home/vwketnk/public_html/autos/cgi-bin/autorun.pl line 52.


    Anyone have any ideas?
     
  2. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,475
    Likes Received:
    20
    Trophy Points:
    38
    Location:
    Go on, have a guess
    The problem is in the error message:

    Can't locate /home/vwketnk/common.inc
    .
    .
    .
    at /home/vwketnk/public_html/autos/cgi-bin/autorun.pl line 52

    It's a bug in the script.
     
  3. Solokron

    Solokron Well-Known Member

    Joined:
    Aug 8, 2003
    Messages:
    849
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    Seattle
    cPanel Access Level:
    DataCenter Provider
    This is what I suspected. Shouldn't common.inc be in the default @INC paths?

    Thanks.

     
  4. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,475
    Likes Received:
    20
    Trophy Points:
    38
    Location:
    Go on, have a guess
    Nope, there's no such file in the base installation of perl. Must be something to do with that specific perl script.

    You will always see the @INC errors when a perl script cannot find a file. All that is showing is the paths it is trying to find the file in. The most relevant of which is the very last one just before the closing bracket, the dot (.) usally meaning the same directory as the perl script itself.

    I would imagine line 52 is trying to do something like:

    require "common.inc";

    and that file is missing or in some other directory within /home/vwketnk/
     
    #4 chirpy, Apr 2, 2004
    Last edited: Apr 2, 2004
Loading...

Share This Page