Find the answer to your Linux question:
Results 1 to 3 of 3
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Apache will not run cgi script

    The message is
    What should Firefox do with this file? etc"

    I am running SUSE 10.1 at home.
    With Firefox I open http://localhost/myscript.html, which includes
    <FORM METHOD="POST" ACTION="cgi-bin/myscript.cgi">

    myscript.cgi is a Perl script, beginning with
    #!/usr/bin/perl <-- path verified
    .... etc.

    When POST in the html file is executed, I get:
    "you have chosen to open myscript.cgi which is a CGI script from http://localhost
    What should Firefox do with this file? etc"

    When I put the same html and cgi files on a commercial server they work.

    Do I not have CGI enabled in Apache?

    /etc/apache2/default-server.conf contains this:

    ScriptAlias /cgi-bin/ "/hdb/www/cgi-bin/"
    <Directory "/hdb/www/cgi-bin">
    AllowOverride None
    Options +ExecCGI -Includes
    Order allow,deny
    Allow from all

    I would greatly appreciate any suggestions.

  2. #2
    Linux Engineer jledhead's Avatar
    Join Date
    Oct 2004
    North Carolina
    does the user apache runs as have execute permissions on the cgi file?
    chmod +x
    should do it if the apache user already owns the file

  3. #3
    Yes, I have tried both 755 and 777.

  4. $spacer_open

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts