首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 网站开发 > CGI >

cgi配置有关问题

2012-07-16 
cgi配置问题,求助access.log:127.0.0.1 - - [09/May/2012:09:39:39 +0800] GET / HTTP/1.1 200 655 -

cgi配置问题,求助
access.log:

127.0.0.1 - - [09/May/2012:09:39:39 +0800] "GET / HTTP/1.1" 200 655 "-" "Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:12.0) Gecko/20100101 Firefox/12.0"
127.0.0.1 - - [09/May/2012:09:39:40 +0800] "POST /cgi-bin/hello HTTP/1.1" 404 502 "http://127.0.0.1/" "Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:12.0) Gecko/20100101 Firefox/12.0"
127.0.0.1 - - [09/May/2012:09:40:01 +0800] "GET / HTTP/1.1" 304 212 "-" "Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:12.0) Gecko/20100101 Firefox/12.0"
127.0.0.1 - - [09/May/2012:09:40:03 +0800] "GET / HTTP/1.1" 304 211 "-" "Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:12.0) Gecko/20100101 Firefox/12.0"
127.0.0.1 - - [09/May/2012:09:40:05 +0800] "POST /cgi-bin/hello HTTP/1.1" 404 502 "http://127.0.0.1/" "Mozilla/5.0 (X11; Ubuntu; Linux i686; rv:12.0) Gecko/20100101 Firefox/12.

error.log:

[Wed May 09 10:04:57 2012] [error] [client 127.0.0.1] script not found or unable to stat: /home/mingang/work/html/cgi-binhello, referer: http://127.0.0.1/
[Wed May 09 10:05:13 2012] [error] [client 127.0.0.1] attempt to invoke directory as script: /home/mingang/work/html/cgi-bin //这边提示forbidden
[Wed May 09 10:05:45 2012] [error] [client 127.0.0.1] attempt to invoke directory as script: /home/mingang/work/html/cgi-bin
[Wed May 09 10:06:51 2012] [error] [client 127.0.0.1] script not found or unable to stat: /home/mingang/work/html/cgi-binhello.cgi //提示无法找到hello.cgi
[Wed May 09 10:07:05 2012] [error] [client 127.0.0.1] attempt to invoke directory as script: /home/mingang/work/html/cgi-bin


文件权限:

mingang@mingang-laptop:~/work/html$ ls
cgi-bin index.html
mingang@mingang-laptop:~/work/html$ ls -l
总用量 8
drwxr-xr-x 2 mingang mingang 4096 2012-05-09 09:39 cgi-bin
-rwxr-xr-x 1 mingang mingang 557 2012-05-09 09:39 index.html
mingang@mingang-laptop:~/work/html$ cd cgi-bin/
mingang@mingang-laptop:~/work/html/cgi-bin$ ls
hello.cgi
mingang@mingang-laptop:~/work/html/cgi-bin$ ls -l
总用量 8
-rwxr-xr-x 1 mingang mingang 7175 2012-05-09 09:22 hello.cgi


thank you

[解决办法]
cgi-binhello 怎么少了个/ ?
cgi-bin/hello ?

热点排行