CGI , not sure if its working

servertweak

Verified User
Joined
Feb 3, 2005
Messages
266
i get this error
Message: I looked in my error logs and found this after I tried to run easyhost.cgi:

[Wed May 04 19:55:45 2005] [error] [client 66.138.144.108] Can't locate CGI.pm in @INC (@INC contains: /usr/lib/perl5/5.8.0/i386-linux-thread-multi /usr/lib/perl5/5.8.0 /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.0/i386-linux-thread-multi /usr/lib/perl5/5.8.0 .) at easyhost.cgi line 19.
[Wed May 04 19:55:45 2005] [error] [client 66.138.144.108] BEGIN failed--compilation aborted at easyhost.cgi line 19.
[Wed May 04 19:55:45 2005] [error] [client 66.138.144.108] Premature end of script headers: easyhost.cgi

Just for reference, Line 19 of the easyhost.cgi script is: " use CGI qw/:cgi/; ". Is the Package CGI missing or in a different location?

Then I ran this


The restarted apache and still having these problem and same error


please advise
 
Did you enable CGI for the user?

Did the reseller enable CGI when setting up the user?

Jeff
 
If a simple hello world cgi script will run, then you know that cgi is working and it is a scripting problem and/or needed module and configuration.
 
Try rebuilding perl.
From what I can tell, downloading the CGI.pm file and placing it in perls directory should have done it.

Is that error given when you try to access through apache? If so, does it work executing from the command line?
It might be a mod_perl issue.
 
jmstacey said:
Try rebuilding perl.
From what I can tell, downloading the CGI.pm file and placing it in perls directory should have done it.

Is that error given when you try to access through apache? If so, does it work executing from the command line?
It might be a mod_perl issue.

apache error log..


how do i rebuild perl ?
 
What Operating system are you running? I think perl is installed using the package system on most, if not all operating systems.

Then you might also try rebuilding mod_perl using customapache.
 
jmstacey said:
What Operating system are you running? I think perl is installed using the package system on most, if not all operating systems.

Then you might also try rebuilding mod_perl using customapache.
Running CentOS 3.4

I have rebuild perl for apache 2 and still having the same problem
 
Back
Top