免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1760 | 回复: 6
打印 上一主题 下一主题

我的服务器(RH9)无法运行pl和cgi~~ [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2005-03-16 21:09 |只看该作者 |倒序浏览
httpd.conf
  1.   

  2. ScriptAlias /cgi-bin/ "var/www/cgi-bin/"

  3. <IfModule mod_cgid.c>;
  4. Scriptsock            run/httpd.cgid
  5. </IfModule>;

  6. <Directory "var/www/cgi-bin">;
  7.    AllowOverride None
  8.    Options ExecCGI
  9.    Allow from all
  10. </Directory>;

复制代码



ERROR 500:

Server error!
The server encountered an internal error and was unable to complete your request.
Error message:
Premature end of script headers: hello.cgi

这是为什么呢?

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
2 [报告]
发表于 2005-03-16 21:15 |只看该作者

我的服务器(RH9)无法运行pl和cgi~~

把你的 hello.cgi 贴上来。

论坛徽章:
0
3 [报告]
发表于 2005-03-16 21:16 |只看该作者

我的服务器(RH9)无法运行pl和cgi~~


  1. #!/usr/bin/perl

  2. #  Alert! The web server is *NOT* processing the script if you can read this line.

  3. print "Content-type: text/html\n\n";
  4. print "Hello world from PERL $]\n";

  5. print "<p>;.cgi scripts  are mapped to Perl.";


复制代码

论坛徽章:
0
4 [报告]
发表于 2005-03-16 21:18 |只看该作者

我的服务器(RH9)无法运行pl和cgi~~

属性全部都是755

论坛徽章:
0
5 [报告]
发表于 2005-03-16 21:54 |只看该作者

我的服务器(RH9)无法运行pl和cgi~~

ok 搞定了。

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
6 [报告]
发表于 2005-03-16 22:09 |只看该作者

我的服务器(RH9)无法运行pl和cgi~~

[quote]原帖由 "fidy"]ok 搞定了。[/quote 发表:

晕……
蛮有奉献精神的嘛!
搞定了也要说一声。
可惜就是不告诉你是怎么搞定的,
所以呀,下次有人犯错,还得自己琢磨。

总之一句话,从来只有我学你们的,你们想要跟我学啊?没门!

论坛徽章:
0
7 [报告]
发表于 2005-03-17 17:21 |只看该作者

我的服务器(RH9)无法运行pl和cgi~~

版主息怒:)
错误比较低级,就是用Edit+ 编辑的时候,文件格式是“pc”,改成"unix"的就好了~~~,还有,我在发帖子的时候漏掉了一个“/”在“var/www/cgi-bin”前面~
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP