#1  
Old 2nd March 2010, 13:47
fooboo fooboo is offline
Member
 
Join Date: Sep 2009
Posts: 49
Thanks: 1
Thanked 1 Time in 1 Post
Default Serving Perl?

I have a working install of ISPConfig3. It serves html and php without a problem but I'm trying to install a perl based site (Bugzilla).
Bugzilla installs all of it's cgi files to the root of the target website (not cgi-bin).
As far as I can tell bugzilla is setup correctly as it comes with a script that does most of it for you.

I know the files are in the folder as if I type in <mydomain>.com/index.cgi I get a page of perl as text (rather than it being processes) so the site can find and serve the files it just not processing them.

If I tick CGI on my site setup ISPConfig adds default settings to point to /cgi-bin/ but I need to set this up so that perl is interpreted at run time from the /web root directory.

Has anyone any experience of this?

I've tried modding the vhost file (I know you're not supposed to :P) to see if I could work out the correct settings but to no avail.
Reply With Quote
Sponsored Links
  #2  
Old 3rd March 2010, 14:21
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,735 Times in 2,571 Posts
Default

Can you post your current vhost configuration?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 10th March 2010, 19:03
fooboo fooboo is offline
Member
 
Join Date: Sep 2009
Posts: 49
Thanks: 1
Thanked 1 Time in 1 Post
Default

Sorry I didn't realise I had a reply, I didn't get an email notification even though I've subscribed.

<Directory /var/www/<domain>>
AllowOverride None
Order Deny,Allow
Deny from all
</Directory>

<VirtualHost <local ip>:80>
DocumentRoot /var/www/<domain>/web

ServerName <domain>
ServerAdmin webmaster@<domain>

ErrorLog /var/log/ispconfig/httpd/<domain>/error.log

ErrorDocument 400 /error/400.html
ErrorDocument 401 /error/401.html
ErrorDocument 403 /error/403.html
ErrorDocument 404 /error/404.html
ErrorDocument 405 /error/405.html
ErrorDocument 500 /error/500.html
ErrorDocument 503 /error/503.html

<Directory /var/www/<domain>/web>
Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
<Files ~ '.php[s3-6]{0,1}$'>
Order allow,deny
Deny from all
Allow from none
</Files>
</Directory>
<Directory /var/www/clients/client1/web25/web>
Options FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
<Files ~ '.php[s3-6]{0,1}$'>
Order allow,deny
Deny from all
Allow from none
</Files>
</Directory>

# cgi enabled
<Directory /var/www/clients/client1/web25/cgi-bin>
Order allow,deny
Allow from all
</Directory>
ScriptAlias /cgi-bin/ /var/www/clients/client1/web25/cgi-bin/
AddHandler cgi-script .cgi
AddHandler cgi-script .pl


</VirtualHost>
Reply With Quote
  #4  
Old 11th March 2010, 17:54
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,735 Times in 2,571 Posts
Default

Can you add the following line right behind
Code:
ScriptAlias /cgi-bin/ /var/www/clients/client1/web25/cgi-bin/
:
Code:
ScriptAlias / /var/www/clients/client1/web25/web/
Restart Apache afterwards. Does it work then?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #5  
Old 11th March 2010, 18:50
fooboo fooboo is offline
Member
 
Join Date: Sep 2009
Posts: 49
Thanks: 1
Thanked 1 Time in 1 Post
Default

I tried that and it didn't make a difference.
I tried modifying the directory too to remove cgi-bin and still no luck.
Reply With Quote
  #6  
Old 15th March 2010, 11:35
fooboo fooboo is offline
Member
 
Join Date: Sep 2009
Posts: 49
Thanks: 1
Thanked 1 Time in 1 Post
Default

If I type in the index file name 'index.cgi' (since it wont automatically serve that file) I get a 403 error, which looks like a permission problem but I don't know who or what permissions I'd need to set. Can anyone advise me?
Reply With Quote
  #7  
Old 16th March 2010, 14:29
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,735 Times in 2,571 Posts
Default

What's in Apache's error log when this happens?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #8  
Old 16th March 2010, 15:14
fooboo fooboo is offline
Member
 
Join Date: Sep 2009
Posts: 49
Thanks: 1
Thanked 1 Time in 1 Post
Default

attempt to invoke directory as script: /var/www/clients/client1/web25/web
client denied by server configuration: /var/www/clients/client1/web25/weberror

On reading this I added a '/' to the end of the ScriptAlias to see if that makes a difference but I still get:

attempt to invoke directory as script: /var/www/clients/client1/web25/web
script not found or unable to stat: /var/www/clients/client1/web25/web/error/noindex.html


so I added 'DirectoryIndex index.cgi' to see if that would make it server the cgi as the index file but I get the same error.

I tried another example for the setup:

<Directory /var/www/clients/client1/web25/web>
AllowOverride All
DirectoryIndex index.cgi
AddHandler cgi-script .cgi
AddHandler cgi-script .pl
Options +ExecCGI
</Directory>

but this gives me:

Directory index forbidden by Options directive: /var/www/<my domain>/web/

and displays the default Apache webpage you get after a new install.
Reply With Quote
  #9  
Old 16th March 2010, 17:57
fooboo fooboo is offline
Member
 
Join Date: Sep 2009
Posts: 49
Thanks: 1
Thanked 1 Time in 1 Post
 
Default

Wahay it works

A friend pointed out that I could add directives to the .htaccess file. After doing so it worked straight away.
Thanks for your help, I learned stuff along the journey.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Want Perl equivalent of linux strings command to extract strings from binary file rjamesd Programming/Scripts 3 30th November 2009 14:46
Remoting Using PERL and Getting junk ' error? What is wrong? bpmee General 1 21st May 2009 09:46
Runaway Perl aws910 Server Operation 2 19th November 2007 17:24
Perl and cgi script installation linuxuser1 General 30 26th April 2006 23:09
Perl non-printable chars and unwanted formatting spinoza Programming/Scripts 4 1st April 2006 20:30


All times are GMT +2. The time now is 05:10.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.