문제

웹 페이지 서버 "192.168.50.29/cgi-bin/tinypl.cgi"에 액세스하려고 할 때 오류 메시지 I Gen; 이렇게 보인다 :

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, root@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.
Apache/2.2.11 (Fedora) Server at 192.168.50.29 Port 80

오류 기록 :

 [Sat Oct 24 21:30:47 2009] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
 [Sat Oct 24 21:30:47 2009] [notice] Digest: generating secret for digest authentication ...
 [Sat Oct 24 21:30:47 2009] [notice] Digest: done
 [Sat Oct 24 21:30:48 2009] [notice] Apache/2.2.11 (Unix) DAV/2 PHP/5.2.9 mod_ssl/2.2.11 OpenSSL/0.9.8g mod_perl/2.0.4 Perl/v5.10.0 configured -- resuming normal operations
 [Sat Oct 24 21:30:50 2009] [error] [client 192.168.50.69] (13)Permission denied: exec of '/var/www/cgi-bin/tinyPL.cgi' failed
 [Sat Oct 24 21:30:50 2009] [error] [client 192.168.50.69] Premature end of script headers: tinyPL.cgi

누구든지 나를 도와 줄 수 있습니까!

도움이 되었습니까?

해결책

로그 파일에는 오류에 대한 자세한 내용이 있지만 CGI 스크립트의 내부 서버 오류는 일반적으로 서버가 CGI 프로그램을 실행하려고 할 때 예상 헤더가 존재하지 않았 음을 의미합니다.

Perl 스크립트에서는 다음과 같습니다.

use CGI qw(:standard);
print header();

다음과 같은 것을 인쇄 할 것입니다.

Content-type: text/html

CommandLine에서 CGI 스크립트를 실행하고 그 라인을 인쇄하는지 확인하십시오. 다른 문제는 액세스 권한으로 인한 것일 수 있습니다. Apache가 스크립트를 실행하지 못할 수 있습니다.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top