[ back to toc ]


Date: 2002/04/11 13:55

I have got a perl portal script (PoaS) from the hotscripts.com site, it
says that it is a complete portal program. We are new to perl and cgi in
general, after installing it on my server, I am getting an Internal Server
Error while trying to test it through my browser and I can't view any cgi
script within the file. Can you tell me where I am going wrong when I
uploaded it in ASCII mode and have set the permissions correctly?

The Internal Server Error message comes from Apache. This error comes from
some more basic mis-settings than that of how the sendmail path is set.
Ensure that the script is uploaded into the proper directory and that the
web server user (usually called www-data) has permission to execute that
script. Also ensure that the very fist line of the script contains

#! /usr/bin/perl

or try

#! /usr/local/bin/perl

and also ensure that the perl interpreter is there where the first line of
the code tells it to you, and is executable by www-data (or whatever user
the web server is executing).

If that does not help ensure that the first thing your program prints is

Content-Type: text/html

and an empty line following these. You can check it starting the program
from the command line. If this still does not help then you can look at
(if you can) the Apache error log file. There is usually some more
information regarding the error.

[ back to toc ]