Passenger RequestHandler中的异常Errno :: EPIPE(断管)

时间:2009-07-04 12:55:27

标签: ruby-on-rails apache2 passenger

在Ubuntu hardy slice上升级到Rails 2.3.2和Passenger 2.2.4 使用Apache2的slicehost

我在Apache error.log中遇到了上面讨论过的错误 system / var / logs / apache2 /

[ pid=4249 file=ext/apache2/Hooks.cpp:638 time=2009-07-04
11:47:32.752 ]:
  No data received from the backend application (process 4383) within
45000 msec. Either the backend application is frozen, or your TimeOut
value of 45 seconds is too low. Please check whether your application
is frozen, or increase the value of the TimeOut configuration
directive.
*** Exception Errno::EPIPE in Passenger RequestHandler (Broken pipe)
(process 4391):
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/rack/request_handler.rb:93:in `write'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/rack/request_handler.rb:93:in `process_request'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_request_handler.rb:206:in `main_loop'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/railz/application_spawner.rb:376:in
`start_request_handler'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/railz/application_spawner.rb:334:in
`handle_spawn_application'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/utils.rb:182:in `safe_fork'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/railz/application_spawner.rb:332:in
`handle_spawn_application'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server.rb:351:in `__send__'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server.rb:351:in `main_loop'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server.rb:195:in `start_synchronously'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server.rb:162:in `start'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/railz/application_spawner.rb:213:in `start'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/spawn_manager.rb:261:in `spawn_rails_application'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server_collection.rb:126:in `lookup_or_add'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/spawn_manager.rb:255:in `spawn_rails_application'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server_collection.rb:80:in `synchronize'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server_collection.rb:79:in `synchronize'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/spawn_manager.rb:254:in `spawn_rails_application'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/spawn_manager.rb:153:in `spawn_application'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/spawn_manager.rb:286:in `handle_spawn_application'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server.rb:351:in `__send__'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server.rb:351:in `main_loop'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/lib/
phusion_passenger/abstract_server.rb:195:in `start_synchronously'
        from /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4/bin/passenger-spawn-
server:61
*** Exception Errno::EPIPE in Passenger RequestHandler (Broken pipe)
(process 4383):

以及这些。

pid=4362 file=ext/apache2/Hooks.cpp:638 time=2009-07-04
11:55:19.251 ]:
  No data received from the backend application (process 4383) within
45000 msec. Either the backend application is frozen, or your TimeOut
value of 45 seconds is too low. Please check whether your application
is frozen, or increase the value of the TimeOut configuration
directive.
[ pid=4298 file=ext/apache2/Hooks.cpp:638 time=2009-07-04
11:55:19.255 ]:
  No data received from the backend application (process 4252) within
45000 msec. Either the backend application is frozen, or your TimeOut
value of 45 seconds is too low. Please check whether your application
is frozen, or increase the value of the TimeOut configuration
directive.
[Sat Jul 04 11:55:19 2009] [error] [client 86.96.226.13] Premature end
of script headers: 41, referer: http://domain.com/
[ pid=4373 file=ext/apache2/Hooks.cpp:638 time=2009-07-04
11:55:19.559 ]:

它让我疯狂,在浏览器上,有时它的节目和时间 刷新,应用程序错误500经常出现。 任何方向?

4 个答案:

答案 0 :(得分:3)

看起来您所拥有的错误已合并到Passenger master但尚未发布。您可以通过从以下存储库中检查Passenger out来尝试:

http://github.com/FooBarWidget/passenger/tree/master

一旦你检查出来,你想运行:

./bin/passenger-install-apache2-module

用于Apache Passenger,或者:

./bin/passenger-install-nginx-module

为Nginx乘客。由于这个特殊问题得到解决,它应该适合你。

答案 1 :(得分:1)

我也有这个问题并通过从乘客2.1.2升级到乘客2.2.15来修复它。

要明确这不是铁路问题,这是一个乘客的错误。

错误日志输出:

[ pid=13571 file=Hooks.cpp:508 time=2010-04-28 17:46:16.878 ]:
  Backend process 22235 did not return a valid HTTP response. It returned no data.
*** Exception Errno::EPIPE in Passenger RequestHandler (Broken pipe) (process 22235):
    from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/rack/request_handler.rb:67:in `write'

答案 2 :(得分:0)

虽然此错误仍在发生,但我更新了Passenger 2.2.7版。我发现在我的Apache配置中更新TimeOutKeepAliveTimeout似乎解决了这个问题。 (他们分别从1和2变为10和20)。希望能帮助别人!

答案 3 :(得分:0)

我刚碰到这个。事实证明这是服务器上DNS破坏的症状。我认为由于飓风桑迪,它的名字服务器已经下线了。因此,如果您遇到此问题,请检查您的网络名称解析是否正常工作!

相关问题