Upgrade to 9.X with Passenger
Added by Brandon Dixon over 14 years ago
- Ubuntu
- Rails 2.3.5
- Passenger 2.2.4
I went through and did the upgrade from Redmine 8.X to 9.X. No real issues other than some routing ones where Passenger didn't seem to properly route my requests. I solved this issue by editing environment.rb and adding:
config.action_controller.relative_url_root = "/ticketing"
I can now browse to my installation and view all the tickets, menus and other features, but I am not able to save anything. When I try to save something I get a 500 server error and this in my logs:
Error during failsafe response: closed stream [Wed Feb 17 17:31:41 2010] [error] [client 10.1.1.15] Premature end of script headers: login, referer: https://portal.g2-inc.com/ticketing/login?back_url=https%3A%2F%2Fportal.g2-inc.com%2Fticketing%2F [ pid=9237 file=Hooks.cpp:514 time=2010-02-17 17:31:41.290 ]: Backend process 9446 did not return a valid HTTP response. It returned: [Status] *** Exception NoMethodError in application (undefined method `[]=' for nil:NilClass) (process 9446): from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/rack/request_handler.rb:68:in `process_request' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_request_handler.rb:197:in `main_loop' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/railz/application_spawner.rb:340:in `start_request_handler' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/railz/application_spawner.rb:298:in `handle_spawn_application' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/utils.rb:176:in `safe_fork' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/railz/application_spawner.rb:296:in `handle_spawn_application' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server.rb:332:in `__send__' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server.rb:332:in `main_loop' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server.rb:182:in `start_synchronously' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server.rb:149:in `start' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/railz/application_spawner.rb:192:in `start' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/spawn_manager.rb:260:in `spawn_rails_application' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server_collection.rb:121:in `lookup_or_add' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/spawn_manager.rb:254:in `spawn_rails_application' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server_collection.rb:75:in `synchronize' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server_collection.rb:74:in `synchronize' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/spawn_manager.rb:253:in `spawn_rails_application' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/spawn_manager.rb:148:in `spawn_application' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/spawn_manager.rb:285:in `handle_spawn_application' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server.rb:332:in `__send__' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server.rb:332:in `main_loop' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/abstract_server.rb:182:in `start_synchronously' from /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/bin/passenger-spawn-server:50
I have no clue what is going on here, but from what I read it seems to be a permission issue. I went through and recursively set the owner of the whole directory to the web server and the permissions to valid writable permissions. I am not sure where to turn here.
Replies (1)
RE: Upgrade to 9.X with Passenger
-
Added by Felix Schäfer over 14 years ago
It rather seems that your app runs passenger 2.1.2, not 2.2.4 as you have stated above. Please check your passenger/apache configuration, which should be located somewhere under /etc/apache2/mods-available
, and make sure the PassengerRoot
points to the right directory (which I'd suppose would be /usr/lib/ruby/gems/1.8/gems/passenger-2.2.4
in your case, but don't take my word for it). Also be sure to reload or restart apache to make it use the new configuration.