Tomcat Workers - 连接 Tomcat 和 Apache
我正在尝试解决有关使用 mod_proxy_ajp 连接 Apache 和 Tomcat 的问题。通过阅读我发现问题可能是Apache和Tomcat中的worker数量。所以我尝试在Tomcat中找到worker的定义,但我找不到任何定义。可以吗? Tomcat 可以在没有workers.properties 文件的情况下工作吗?我检查了 Tomcat conf 中的导入,只是为了确保没有不同的文件名,但没有。如何找到我的 Tomcat 设置的工作人员配置?有默认的吗?
我试图解决的问题是,在某些情况下,Tomcat 停止响应 Apache - 在 Apache 日志中我看到许多错误,例如: 1.“(70007)指定的超时已过期:ajp_ilink_receive()无法接收标头” 2.“ajp_read_header:ajp_ilink_receive失败” 3.“(120006)APR不理解此错误代码:代理:从127.0.0.1:9005(localhost)读取响应失败”)
所以我试图找出Apache是否比Tomcat有更多的工作人员。
我正在使用 Apache 2.2.15 和 Tomcat 7,通过 Redhat 计算机上的 mod_proxy ajp 连接。
有什么想法吗? 谢谢! 巴巴
I'm trying to resolve an issue about connecting Apache and Tomcat with mod_proxy_ajp. From reading I found that the problem might be the numbers of workers in the Apache and the Tomcat. So I try to find the worker's definition in the Tomcat but I couldnt find any. Can it be? Can Tomcat work without a workers.properties file? I checked the imports in the Tomcat conf just to make sure that there isnt a different file name but none. How can I find out the worker's configuration of my Tomcat setup? Is there a default?
The problem that I'm trying to solve is that in some cases the Tomcat stops responding to the Apache - in the Apache log I see many errors like:
1. "(70007)The timeout specified has expired: ajp_ilink_receive() can't receive header"
2. "ajp_read_header: ajp_ilink_receive failed"
3. "(120006)APR does not understand this error code: proxy: read response failed from 127.0.0.1:9005 (localhost)")
So I'm trying to find out maybe the Apache has more workers than the Tomcat.
I'm using Apache 2.2.15 and Tomcat 7, connected with mod_proxy ajp on a Redhat machine.
Any ideas?
Thanks!
Baba
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在 Tomcat 端,您必须在 server.xml 中配置 AJP 连接器,例如:
On Tomcat side you have to configure AJP connector in server.xml, for example: