Perl on cpanel

Hey Guys,

Just wondering if something specific needs to be done to run perl scripts on an cpanel/whm server...
Currently I am getting:

500 Server Error
A misconfiguration on the server caused a hiccup. Check the server logs, fix the problem, then try again.
LVL 1
ShivtekAsked:
Who is Participating?
 
Brad HoweDevOps ManagerCommented:
You could also create a .htaccess file in the folder you are looking to use .pl scripts and add the following.

AddHandler cgi-script .pl .cgi
Options Includes ExecCGI

Hades666

0
 
Brad HoweDevOps ManagerCommented:

Where are you executing your scripts from?

Did you try to put your script on cgi-bin folder. Then try to execute via

http://www.mydomain.com/cgi-bin/myscript.pl
0
 
FishMongerCommented:
The first thing to check is the web server error log, as the error message suggests.

Some possible causes of a 500 error are:

1) Script uploaded from Windows to *nix server in binary mode instead of ascii mode

2) Permission settings are wrong, which is preventing the web server from executing the script.

3) The shebang line missing or does not have the correct path to perl
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.