免费注册 查看新帖 |

Chinaunix

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

apache+fastcgi问题 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2007-02-27 17:06 |只看该作者 |倒序浏览
Apache启动和cgi程序的编译都没问题
但是运行的时候就出错
以下是一些信息
高手指点一下吧

winXP
apache2.0.59
mod_fastcgi-2.4.2-AP20.dll

httpd.conf

  1. LoadModule fastcgi_module modules/mod_fastcgi-2.4.2-AP20.dll
  2. ...
  3. <IfModule mod_fastcgi.c>
  4.         ScriptAlias /fcgi-bin/ "D:/Program Files/Apache Group/Apache2/fcgi-bin/"
  5.         FastCgiServer fcgi-bin/echo.exe -processes 2
  6. </IfModule>
复制代码


echo.c

  1.     #include "fcgi_stdio.h"
  2.     #include <stdlib.h>

  3.     void main(void)
  4.     {
  5.         int count = 0;
  6.         while(FCGI_Accept() >= 0)
  7.             printf("Content-type: text/html\r\n"
  8.                    "\r\n"
  9.                    "<title>FastCGI Hello!</title>"
  10.                    "<h1>FastCGI Hello!</h1>"
  11.                    "Request number %d running on host <i>%s</i>\n",
  12.                     ++count, getenv("SERVER_NAME"));
  13.     }
复制代码


apache error.log

  1. [Tue Feb 27 17:04:56 2007] [notice] mod_python: Creating 8 session mutexes based on 0 max processes and 250 max threads.
  2. [Tue Feb 27 17:04:56 2007] [notice] Apache/2.0.59 (Win32) mod_python/3.2.8 Python/2.4.4 mod_fastcgi/2.4.2 configured -- resuming normal operations
  3. [Tue Feb 27 17:04:56 2007] [notice] Server built: Jul 27 2006 15:55:03
  4. [Tue Feb 27 17:04:56 2007] [notice] Parent: Created child process 4000
  5. [Tue Feb 27 17:04:56 2007] [notice] mod_python: Creating 8 session mutexes based on 0 max processes and 250 max threads.
  6. [Tue Feb 27 17:04:56 2007] [notice] Child 4000: Child process is running
  7. [Tue Feb 27 17:04:56 2007] [notice] Child 4000: Acquired the start mutex.
  8. [Tue Feb 27 17:04:56 2007] [notice] Child 4000: Starting 250 worker threads.
  9. [Tue Feb 27 17:04:56 2007] [notice] FastCGI: process manager initialized
  10. [Tue Feb 27 17:04:56 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" started (pid 2004)
  11. [Tue Feb 27 17:04:56 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" (pid 2004) terminated with exit with status '-1073741515'
  12. [Tue Feb 27 17:04:57 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" started (pid 3948)
  13. [Tue Feb 27 17:04:57 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" (pid 3948) terminated with exit with status '-1073741515'
  14. [Tue Feb 27 17:05:02 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" restarted (pid 3092)
  15. [Tue Feb 27 17:05:02 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" (pid 3092) terminated with exit with status '-1073741515'
  16. [Tue Feb 27 17:05:03 2007] [error] [client 127.0.0.1] attempt to invoke directory as script: D:/Program Files/Apache Group/Apache2/fcgi-bin/
  17. [Tue Feb 27 17:05:07 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" restarted (pid 368)
  18. [Tue Feb 27 17:05:07 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" (pid 368) terminated with exit with status '-1073741515'
  19. [Tue Feb 27 17:05:07 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" has failed to remain running for 30 seconds given 3 attempts, its restart interval has been backed off to 600 seconds
  20. ...
  21. [Tue Feb 27 17:05:21 2007] [notice] Parent: Received shutdown signal -- Shutting down the server.
  22. [Tue Feb 27 17:05:21 2007] [notice] Child 4000: Exit event signaled. Child process is ending.
  23. [Tue Feb 27 17:05:22 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" has failed to remain running for 30 seconds given 3 attempts, its restart interval has been backed off to 600 seconds
  24. [Tue Feb 27 17:05:22 2007] [warn] FastCGI: server "D:/Program Files/Apache Group/Apache2/fcgi-bin/echo.exe" has failed to remain running for 30 seconds given 3 attempts, its restart interval has been backed off to 600 seconds
  25. ...
复制代码

论坛徽章:
0
2 [报告]
发表于 2007-02-28 10:19 |只看该作者
又在Linux上试了一下
又不出错
晕.....
还是linux简单

论坛徽章:
5
2015年辞旧岁徽章
日期:2015-03-03 16:54:152015年迎新春徽章
日期:2015-03-04 09:53:172015亚冠之水原三星
日期:2015-06-02 16:34:202015年亚冠纪念徽章
日期:2015-10-19 18:13:37程序设计版块每日发帖之星
日期:2015-11-08 06:20:00
3 [报告]
发表于 2007-03-14 05:22 |只看该作者
你把 libfcgi.dll放哪了
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

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

清除 Cookies - ChinaUnix - Archiver - WAP - TOP