LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 07-12-2008, 01:42 AM   #1
shahz
Member
 
Registered: Sep 2006
Location: Quetta, Pakistan
Distribution: RHEL, Ubuntu, Fedora
Posts: 368

Rep: Reputation: 29
500 Internal Server Error


I have installed greenstone properly on my system, I have default apache server running on my pc, I have alias for the greenstone file like following.

ScriptAlias /gsdl/cgi-bin "/opt/greenstone/cgi-bin"
<Directory "/opt/greenstone/cgi-bin">
Options None
AllowOverride None
</Directory>

Alias /gsdl "/opt/greenstone"
<Directory "/opt/greenstone">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>

but when I start my web server I can't access the cgi-bin directory.

my httpd error log is like

rror] [client 127.0.0.1] (13)Permission denied: exec of '/opt/greenstone/cgi-bin/library' failed
[Sat Jul 12 11:22:01 2008] [error] [client 127.0.0.1] Premature end of script headers: library
[Sat Jul 12 11:22:01 2008] [error] [client 127.0.0.1] File does not exist: /var/www/html/favicon.ico


can any body help how to resolve this. thanks in advance

thanks
shahz
 
Old 07-12-2008, 03:00 AM   #2
Acron_0248
Member
 
Registered: Feb 2006
Location: Venezuela
Distribution: Gentoo
Posts: 453

Rep: Reputation: 33
You should add Options ExecCGI for the /gdsl/cgi-bin directory

Also check the permissions of the files at /opt/greenston/cgi-bin, they should be executable (like 0755 or so)
 
Old 07-12-2008, 03:14 AM   #3
shahz
Member
 
Registered: Sep 2006
Location: Quetta, Pakistan
Distribution: RHEL, Ubuntu, Fedora
Posts: 368

Original Poster
Rep: Reputation: 29
Quote:
Originally Posted by Acron_0248 View Post
You should add Options ExecCGI for the /gdsl/cgi-bin directory
I have given full permission for a test purpose the cgi-bin directory permissions are 777, what is ExecCGI for the /gsdkl/cgi-bin please explain a bit.

thanks
shahz
 
Old 07-12-2008, 04:10 AM   #4
shahz
Member
 
Registered: Sep 2006
Location: Quetta, Pakistan
Distribution: RHEL, Ubuntu, Fedora
Posts: 368

Original Poster
Rep: Reputation: 29
I downloaded the new version for the apache server, installed the source did every thing as it was needed.

again when I access the my local url I get the error

http://localhost/gsdl/cgi-bin/

I get the error

Forbidden

You don't have permission to access /gsdl/cgi-bin/ on this server.

I have full permissions for the directory but still I am not able to access it. any suggations.

thanks
shahz
 
Old 07-12-2008, 04:27 AM   #5
Acron_0248
Member
 
Registered: Feb 2006
Location: Venezuela
Distribution: Gentoo
Posts: 453

Rep: Reputation: 33
ExecCGI gives execution permissions at server level (not at files level like 777 for instance)

When a script is called and that script is executed by a defined cgi handler, the server verify that the directory containing the script have execute permissions so the script can be executed by the cgi handler, the ExecCGI option gives that permission.

About the other one, you shouldn't have problem if you add to <Directory "/opt/greenstone/cgi-bin"> the following:
Code:
Order allow,deny
Allow from all
Although (and someone please correct me if I'm wrong with this) you, as a user, don't need access directly to http://localhost/gdsl/cgi-bin, I mean, going to that URL and recieving a 403 error doesn't mean that it's a problem since what it's actually required is that the scripts that runs under the cgi-handler have the right access, again, I'm not sure about this one, however, in case I'm wrong the Order allow,deny I put before should work

Last edited by Acron_0248; 07-12-2008 at 04:28 AM.
 
Old 07-12-2008, 05:03 AM   #6
shahz
Member
 
Registered: Sep 2006
Location: Quetta, Pakistan
Distribution: RHEL, Ubuntu, Fedora
Posts: 368

Original Poster
Rep: Reputation: 29
finally it works

what I did in the httpd.conf file

I added the following

<Directory /gsdl/cgi-bin>
Options +ExecCGI
</Directory>

AddHandler cgi-script .cgi .pl

thanks acron

shahz
 
Old 07-12-2008, 05:54 AM   #7
Acron_0248
Member
 
Registered: Feb 2006
Location: Venezuela
Distribution: Gentoo
Posts: 453

Rep: Reputation: 33
No problem, glad to be of help
 
Old 12-10-2008, 08:38 AM   #8
flyblogger
LQ Newbie
 
Registered: Dec 2008
Posts: 3

Rep: Reputation: 0
Help me too

Hello everybody,

I have the same problem which had Shahz with the installation of Greenstone.

I'm installing Greenstone on Mac OS X Leopard, being a Unix system I'm writing here.

When I go to http://localhost/gsdl/cgi-bin/
All i get is this error message: "403 Forbidden - You don't have permission to access /gsdl/cgi-bin/ on this server. - Apache/2.0.59 (Unix) PHP/5.2.6 DAV/2 Server at localhost Port 8888".

I added this to the httpd.conf file:
Code:
ScriptAlias /gsdl/cgi-bin "/Users/Flavia/Documents/Greenstone2/cgi-bin"
  <Directory /Users/Flavia/Documents/Greenstone2/cgi-bin>
     Options None
     AllowOverride None
  </Directory>
  
  Alias /gsdl "/Users/Flavia/Documents/Greenstone2"
  <Directory /Users/Flavia/Documents/Greenstone2>
     Options Indexes MultiViews FollowSymLinks
     AllowOverride None
     Order allow,deny
     Allow from all
  </Directory>
Can you please Shahz tell me what you exactly wrote in your httpd.conf file?

Thank you very much.

PS: sorry for my italian-english!
 
Old 03-31-2009, 02:50 AM   #9
shahz
Member
 
Registered: Sep 2006
Location: Quetta, Pakistan
Distribution: RHEL, Ubuntu, Fedora
Posts: 368

Original Poster
Rep: Reputation: 29
I have already written in my above post what I added in httpd.conf

check out that.

thanks
shahz
 
Old 03-31-2009, 03:05 AM   #10
vlademir
Member
 
Registered: Jan 2009
Location: The Netherlands
Distribution: Centos,Ubuntu,Mandriva,Suse11.1
Posts: 86

Rep: Reputation: 17
always about the same subject : 500 Internal Server Error
i uploaded using ftp my website files to my server at /var/www/web1/web/
when i type my web www.website.com i got the 500 internal server error
i tried to change the permission to 0755 but nothing
somebody have any idea how to resolve this problem ?
thanks in advance
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
500 Internal server error fa_khan50 Linux - Newbie 0 01-02-2008 12:13 AM
500 Internal Server Error in apache av.dubey Linux - Server 16 01-01-2008 12:32 PM
zenoss 500 Internal Server Error? kav Linux - Software 0 07-13-2007 11:50 AM
500 Internal Server Error bship Linux - Software 5 01-19-2007 04:48 PM
dns and 500 internal server error.. Flawless Slackware 4 08-23-2003 11:08 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

All times are GMT -5. The time now is 09:50 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration