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.

Error 500 while loading perl file.

Discussion in 'General Discussion' started by sh4ka, Mar 24, 2009.

  1. sh4ka

    sh4ka Well-Known Member

    Joined:
    May 12, 2005
    Messages:
    442
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    US
    cPanel Access Level:
    DataCenter Provider
    Hello,

    We have a perl script that is located under cgi-bin/yabb/

    Everytime it's loaded is causing an error 500, suexec logs shows everything correct but error_log shows this:

    Code:
    [Wed Mar 25 00:58:18 2009] [error] [client 190.135.xxx.xxx] [B]Can't locate Upload/CGI.pm in @INC[/B] (@INC contains: /usr/lib/perl5/5.8.8/i686-linux /usr/lib/perl5/5.8.8 /usr/lib/perl5/site_perl/5.8.8/i686-linux /usr/lib/perl5/site_perl/5.8.8 /usr/lib/perl5/site_perl/5.8.7 /usr/lib/perl5/site_perl/5.8.6 /usr/lib/perl5/site_perl/5.8.5 /usr/lib/perl5/site_perl . ./Modules ./Modules/Upload ./Modules/Digest ./Modules ./Modules/Upload ./Modules/Digest) at ./Sources/Subs.pl line 605.
    [Wed Mar 25 00:58:18 2009] [error] [client 190.135.xxx.xxx] [B]BEGIN failed--compilation aborted at ./Sources/Subs.pl line 605.[/B]
    [Wed Mar 25 00:58:18 2009] [error] [client 190.135.xxx.xxx] [B]Compilation failed in require at YaBB.pl line 57.[/B]
    [Wed Mar 25 00:58:18 2009] [error] [client 190.135.xxx.xxx] [B]Premature end of script headers: YaBB.pl[/B]
    It seems CGI.pm module can't be found.. can this be installed on the server? searched for this module in WHM - Main >> Software >> Module Installers but I wasn't able to find any module named like this.

    In the other hand.. a simple "hello world" in the same directory works perfect.. so.. perl is working.. but the forum .pl file doesn't, don't know why.. permissions are 755 and owner are user.user.

    Can anybody guide me? I'm using RHEL 5 + latest cPanel Current release tree.

    Thanks.
     
    #1 sh4ka, Mar 24, 2009
    Last edited by a moderator: Mar 24, 2009
  2. sh4ka

    sh4ka Well-Known Member

    Joined:
    May 12, 2005
    Messages:
    442
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    US
    cPanel Access Level:
    DataCenter Provider
    However, after ran find command saw that cgi.pm is actually installed :s

    May this be a script problem? or a server problem? what do you think?
     
  3. rhenderson

    rhenderson Well-Known Member

    Joined:
    Apr 21, 2005
    Messages:
    785
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Oklahoma
    cPanel Access Level:
    Root Administrator
  4. cPanelStephen

    cPanelStephen Active Member
    Staff Member

    Joined:
    Aug 7, 2007
    Messages:
    25
    Likes Received:
    0
    Trophy Points:
    1
    It would appear your script is trying to use Upload::CGI, which isn't a module published on CPAN. Do you have a module CGI.pm in a directory named Upload, that is included in the @INC path for that script?

    If you're trying to use the CPAN published CGI.pm module, you will need to drop the Upload:: from the use of that module inside the script
     
Loading...

Share This Page