TurnKey Linux Virtual Appliance Library

How to use Perl CGI scripts in lamp appliance ?

rob.r374's picture

Hi,

first of all, hi to the community. I'm new to Turnkey linux and after 1 installation, I'm becoming a fan.... Thanks for great work.

I'd like to modify LAMP appliance (I really like TKLPatch approach), but first I need to get some software written as Perl CGI scripts working.

 

At the moment I have an rrd.cgi script in /var/www/cgi-bin and when I try to access if from remote location, I get the script as text - it doesn't get executed.

Since appliance is supposed to support Apache&Perl out of the box, I'm surely missing something simple ?

Thanks in advance,

regards,

Bulek.

 

Liraz Siri's picture

You may need to configure Apache...

CGI should work out of the box (in cgi-bin). I filed a bug report. Thanks for reporting this!

Anyhow, for a Perl CGI script to execute in cgi-bin Apache has to be configured with the +ExecCGI option for the cgi-bin directory and a few other things. See this article for details.

Guest's picture

Trying to run perl scripts (.pl)

I follow the article but doesn't work. 500 internal server error

Any other clue?

Thank you for your excelent work.

olc's picture

same here

same here. LAMP TKL. been trying to get a cgi to run. doesnt run by default.

editing httpd.conf as follows doesnt work at all.

ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
  AllowOverride None
  Options ExecCGI
  AddHandler cgi-script cgi
  Order allow,deny
  Allow from all
</Directory>
Steve's picture

Any new news on this?

I have the same problem - I need to execute a script from cgi-bin  within the /var/www folder

 

Can't quite figure out what to point where - I did check the referenced article but this mostly refers to windows setup

 

Any thoughts much appreciated

Alon Swartz's picture

Answered in another post

I just came across this thread after answering the same issue in a nother. You can see my post here.

Post new comment

The content of this field is kept private and will not be shown publicly. If you have a Gravatar account, used to display your avatar.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <p> <span> <div> <h1> <h2> <h3> <h4> <h5> <h6> <img> <map> <area> <hr> <br> <br /> <ul> <ol> <li> <dl> <dt> <dd> <table> <tr> <td> <em> <b> <u> <i> <strong> <font> <del> <ins> <sub> <sup> <quote> <blockquote> <pre> <address> <code> <cite> <strike> <caption>

More information about formatting options

Leave this field empty. It's part of a security mechanism.
(Dear spammers: moderators are notified of all new posts. Spam is deleted immediately)