乘客错误 - PhusionPassenger :: ClassicRails :: ApplicationSpawner ::错误

时间:2010-12-13 16:11:24

标签: ruby-on-rails passenger

Ruby on rails项目:我在服务器(app,config)上升级了我的文件,成功运行了bundle install。然后乘客抛出了这个例子。它没有让我任何意义。那可能是什么?我可以获得任何有关例外的详细描述吗?

Exeption on apache error_log: 
(eval):1: warning: already initialized constant RAILS_ROOT
[ pid=26440 thr=23860019550640 file=utils.rb:176 time=2010-12-13 17:33:29.576 ]: *** Exception NameError in application (wrong constant name LddkProjekts
) (process 26440, thread #<Thread:0x2b66affab360>):
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/classic_rails/application_spawner.rb:334:in `const_get'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/classic_rails/application_spawner.rb:334:in `find_rack_app'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/classic_rails/application_spawner.rb:308:in `start_request_handler'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/classic_rails/application_spawner.rb:275:in `send'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/classic_rails/application_spawner.rb:275:in `handle_spawn_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/utils.rb:479:in `safe_fork'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/classic_rails/application_spawner.rb:270:in `handle_spawn_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:357:in `__send__'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:357:in `server_main_loop'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:206:in `start_synchronously'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:180:in `start'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/classic_rails/application_spawner.rb:149:in `start'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:219:in `spawn_rails_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server_collection.rb:132:in `lookup_or_add'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:214:in `spawn_rails_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server_collection.rb:82:in `synchronize'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server_collection.rb:79:in `synchronize'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:213:in `spawn_rails_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:132:in `spawn_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:275:in `handle_spawn_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:357:in `__send__'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:357:in `server_main_loop'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:206:in `start_synchronously'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/helper-scripts/passenger-spawn-server:99
[ pid=26386 thr=23860019550640 file=utils.rb:176 time=2010-12-13 17:33:29.585 ]: *** Exception IOError in PhusionPassenger::ClassicRails::ApplicationSpawner (Connection closed) (process 26386, thread #<Thread:0x2b66affab360>):
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/app_process.rb:105:in `read_from_channel'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/classic_rails/application_spawner.rb:287:in `handle_spawn_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:357:in `__send__'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:357:in `server_main_loop'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:206:in `start_synchronously'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:180:in `start'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/classic_rails/application_spawner.rb:149:in `start'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:219:in `spawn_rails_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server_collection.rb:132:in `lookup_or_add'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:214:in `spawn_rails_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server_collection.rb:82:in `synchronize'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server_collection.rb:79:in `synchronize'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:213:in `spawn_rails_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:132:in `spawn_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/spawn_manager.rb:275:in `handle_spawn_application'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:357:in `__send__'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:357:in `server_main_loop'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/lib/phusion_passenger/abstract_server.rb:206:in `start_synchronously'
    from /usr/lib/ruby/gems/1.8/gems/passenger-3.0.0/helper-scripts/passenger-spawn-server:99

谢谢!

2 个答案:

答案 0 :(得分:13)

您需要在apache配置文件中将RailsBaseURI指令更改为RackBaseURIRailsBaseURI用于Rails 1和Rails 2应用程序,而RackBaseURI是Rails 3的用法。

有人报告说,丢失的config.ru文件导致了相同的错误消息。

您可以查看http://groups.google.com/group/phusion-passenger/browse_thread/thread/e5c7495a6fef4ba7上的讨论。

答案 1 :(得分:0)

请检查您正在使用的Gems版本。就我而言,Gemfile中存在一个问题。在我的情况下,我使用较低版本的宝石'rubyzip','0.9.9',我更新到宝石'rubyzip','1.0.0'解决了这个问题。红宝石拉链

由于 迪普