Perl Files Downloading Instead of Running

Discussion in 'Installation/Configuration' started by emil2k, Dec 15, 2007.

  1. emil2k

    emil2k New Member

    I have set up a development machine at home and I'm trying to move perl files that I know work from my HostGator account to my home account, but when I placed the files and proceded with the installation and matched the same permissions as on my previous host, for some reason when I try to view the perl file via browser it tries to download it instead of running it.

    This is what I have in my httpd.conf and this is a Debian Etch with Apache2

    ScriptAlias /cgi-bin/ /var/www/project/trunk/cgi-bin/
    <Directory /var/www/project/trunk/cgi-bin>
            AllowOverride None
            Options ExecCGI -MultiViews +SymLinksIfOwnerMatch
            Order allow,deny
            Allow from all
    Can somebody tell me what I should do :confused:
  2. falko

    falko Super Moderator ISPConfig Developer

    Add this to your vhost configuration and restart Apache:

    AddHandler cgi-script .cgi
    AddHandler cgi-script .pl
  3. emil2k

    emil2k New Member

    It's still downloading the file instead of running it :confused:
  4. falko

    falko Super Moderator ISPConfig Developer

    Can you post your vhost configuration?
  5. emil2k

    emil2k New Member

    I actually just fixed this, it figures that I just needed some modules installed and the scripts were not running but for some reason whether it is FireFox or the server the 500 error wasn't showing like usual instead it was downloading some empty files, I found the logs in /var/log/apache2/error.log which said which modules needed to be installed.

    I installed them through the cpan command and it works now.

    But now I'm having trouble (not related to the above) with .htaccess files running mod_rewrite, I enabled the rewrite module with a symlink and changed the AllowOverride to All and reloaded and it still doesn't do the simple check found here:

    When I click the second link it simply shows a 404, this is what I put in the httpd.conf for this:

    <Directory /var/www>
            AllowOverride All
    Should I start another topic for this?
  6. falko

    falko Super Moderator ISPConfig Developer

    What's in your .htaccess file?
  7. emil2k

    emil2k New Member

Share This Page