Personal Web Hosting Web Hosting by Micfo.com 24x7 World-Class Web Hosting Support. Dedicated Server Hosting
  • Knowledgebase Business Hosting Reseller Hosting Linux VPS Hosting Dedicated Server

CGI-Bin Questions


Perl / CGI scripts, to run properly, must be uploaded to your account via FTP as ASCII files. Also, all CGI scripts must be executable. This requires setting the permissions on the file using your FTP program and making sure the script is world executable (CHMOD).

If you are getting an ‘Internal Server Error’ and you have verified that the CGI script was uploaded as an ASCII file and it is executable, there may be a syntax error in the code.

The easiest way to verify this is to telnet into your account. Go to the directory that contains the script (cd www/directory), and run the program from the prompt by typing in the name of the script. This will highlight the error in the program.

All CGI scripts those are called from the web do not run with your account’s permission by default. This is done for security reasons. The CGI scripts run as the user ‘nobody’, which is a fake username with no permissions. Because of this, any file or directory that you want a script to write to must be world writeable (CHMOD 777). This includes files such as .rdb, .dat, .txt etc.

Check the steps below:

1. Make sure the Perl path is set to /usr/bin/Perl
2. Make sure the .cgi/.pl file was uploaded to cgi-bin folder
3. Make sure the .cgi/.pl file was uploaded in ASCII mode
4. Make sure to CHMOD the script to 755

If the above steps didn’t help, send us a support ticket. Also please make sure to include the readme file.