Skip to Main Content

Infrastructure Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Apache/CentOS--error: attempt to invoke directory as script. Please help.

581674Nov 12 2007 — edited Nov 13 2007
I am running CentOS 4.5 with kernel 2.6.9-55.EL and Apache 2.0.52.
When I am typing http://linxdell.systems.com to execute index.cgi, I am getting:
Forbidden
You don't have permission to access / on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request
In the error_log I found:
attempt to invoke directory as script: /var/www/htdocs/
But if I type http://linxdell.systems.com/index.cgi, it works fine.

Below is some of my httpd.conf:

DocumentRoot "/var/www/htdocs"

<Directory />
Options FollowSymLinks ExecCGI Indexes
AllowOverride All
</Directory>

<Directory "/var/www/htdocs">
Options Indexes FollowSymLinks All Multiviews ExecCGI
SetHandler cgi-script
AllowOverride All
Order allow,deny
Allow from all
</Directory>

DirectoryIndex generate_page.pl index.html index.htm index.cgi

ScriptAlias /cgi-bin "/var/www/cgi-bin" (also tried with Alias)

<Directory "/var/www/cgi-bin">
AllowOverride All
SetHandler cgi-script
Options ExecCGI Indexes
Allow from all
</Directory>

I will really appreciate any help to solve this problem.
Thanks.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 11 2007
Added on Nov 12 2007
3 comments
4,885 views