Project

General

Profile

Upgrade to 0.9.2, please help!

Added by Colin Mollenhour about 14 years ago

I upgraded to 0.9.2 and now cannot get it to run, I get the Apache 500 error page that says "Application error Rails application failed to start properly".

Previous setup:

  • Ubuntu 9.0.4
  • Ruby 1.8.6
  • Redmine 0.8.7 via svn
  • Passenger 2.0.6
  • Rails 2.1.2

Current setup:

  • Ruby 1.8.6
  • Redmine upgraded to 0.9.2 by running "svn switch svn://rubyforge.org/var/svn/redmine/branches/0.9-stable"
  • Other gems upgraded via "gem". Here is my gem query:
actionmailer (2.3.5)
actionpack (2.3.5)
activerecord (2.3.5)
activeresource (2.3.5)
activesupport (2.3.5)
builder (2.1.2)
cgi_multipart_eof_fix (2.5.0)
daemons (1.0.10)
fastthread (1.0.1)
fcgi (0.8.7)
gem_plugin (0.2.3)
mongrel (1.1.5)
mysql (2.7)
passenger (2.2.10)
rack (1.0.1)
rails (2.3.5)
rake (0.8.3)
rmagick (2.8.0)
rubygems-update (1.3.6)
sqlite-ruby (2.2.3)
sqlite3-ruby (1.2.4)
* I updated apache config for the new passenger paths. Restarted apache and confirm that passenger is running with new version:
# ps aux | grep [p]asse
root      8155  0.0  0.1   3736  1568 ?        Sl   08:02   0:00 /usr/lib/ruby/gems/1.8/gems/passenger-2.2.10/ext/apache2/ApplicationPoolServerExecutable 0 /usr/lib/ruby/gems/1.8/gems/passenger-2.2.10/bin/passenger-spawn-server  /usr/bin/ruby1.8  /tmp/passenger.8140

Apache config:
<VirtualHost *:80>
  ...
  ## REDIRECT TO HTTPS ##
  <LocationMatch "^/redmine">
    RewriteEngine on
    RewriteRule ^(.*) https://%{SERVER_NAME}%{REQUEST_URI} [R,L]
  </LocationMatch>
</VirtualHost>
<VirtualHost *:443>
  ...
  #### REDMINE ####
  Alias /redmine /var/www/example.com/dev/redmine/public
  <Directory /var/www/example.com/dev/redmine/public>
    Options ExecCGI
    AllowOverride all
    Order allow,deny
    Allow from all
  </Directory>
</VirtualHost>
  • I ran all of the steps on the RedmineUpgrade
  • I reapplied file permissions after the svn switch (www-data:www-data, 775)

The script/console works for both production and development:

# ./script/console production
Loading production environment (Rails 2.3.5)
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/rails/gem_dependency.rb:119:Warning: Gem::Dependency#version_requirements is deprecated and will be removed on or after August 2010.  Use #requirement
>>

Nothing is logged in the log except this in production|development.log:

# Logfile created on Sun Feb 28 07:10:02 +0000 2010

Files in public/ such as 500.html are accesible. dispatch.fcgi is 775.

When I try running it with webrick:

# ruby script/server webrick -e production
=> Booting WEBrick
=> Rails 2.3.5 application starting on http://0.0.0.0:3000
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/rails/gem_dependency.rb:119:Warning: Gem::Dependency#version_requirements is deprecated and will be removed on or after August 2010.  Use #requirement
=> Call with -d to detach
=> Ctrl-C to shutdown server
[2010-02-28 08:17:54] INFO  WEBrick 1.3.1
[2010-02-28 08:17:54] INFO  ruby 1.8.6 (2007-09-24) [i486-linux]
[2010-02-28 08:17:54] INFO  WEBrick::HTTPServer#start: pid=8292 port=3000
[2010-02-28 08:19:29] ERROR bad Request-Line `yuK'bìÏ}B3TÑíªÊY/ä ÎáªÂ+)/5'.

The last line appears each time I try to load the page, I am not loading it via localhost though since it is a hosted machine.

Any ideas anyone?

Thanks,
Colin


Replies (4)

RE: Upgrade to 0.9.2, please help! - Added by Colin Mollenhour about 14 years ago

More information. I don't know if this helps but I ran the following from public/:

# ruby -d dispatch.fcgi
Exception `LoadError' at /usr/local/lib/site_ruby/1.8/rubygems.rb:1084 - no such file to load -- rubygems/defaults/operating_system
Exception `LoadError' at /usr/local/lib/site_ruby/1.8/rubygems/config_file.rb:50 - no such file to load -- Win32API
Exception `Gem::LoadError' at /usr/local/lib/site_ruby/1.8/rubygems.rb:777 - Could not find RubyGem memcache-client (>= 1.7.4)

Exception `Gem::LoadError' at /usr/local/lib/site_ruby/1.8/rubygems.rb:777 - Could not find RubyGem tzinfo (~> 0.3.12)

Exception `Gem::LoadError' at /usr/local/lib/site_ruby/1.8/rubygems.rb:777 - Could not find RubyGem i18n (>= 0.1.3)

Exception `TypeError' at (eval):4 - can't modify frozen object
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31 - no such file to load -- fast_xs
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:38 - no such file to load -- fast_xs
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31 - no such file to load -- json
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:38 - no such file to load -- json
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:162 - no such file to load -- json
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/rails/gem_dependency.rb:119:Warning: Gem::Dependency#version_requirements is deprecated and will be removed on or after August 2010.  Use #requirement
Exception `Gem::LoadError' at /usr/local/lib/site_ruby/1.8/rubygems.rb:777 - Could not find RubyGem hoe (>= 1.3.0)

Exception `Gem::LoadError' at /usr/local/lib/site_ruby/1.8/rubygems.rb:777 - Could not find RubyGem tmail (~> 1.2.3)

Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31 - no such file to load -- tmail/tmailscanner
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:38 - no such file to load -- tmail/tmailscanner
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:162 - no such file to load -- tmail/tmailscanner
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:778: warning: instance variable @reload_plugins not initialized
/usr/lib/ruby/gems/1.8/gems/activerecord-2.3.5/lib/active_record/validations.rb:381: warning: `*' interpreted as argument prefix
/usr/lib/ruby/gems/1.8/gems/activerecord-2.3.5/lib/active_record/validations.rb:29: warning: method redefined; discarding old message
/usr/lib/ruby/gems/1.8/gems/activerecord-2.3.5/lib/active_record/dirty.rb:40: warning: `*' interpreted as argument prefix
/usr/lib/ruby/gems/1.8/gems/activerecord-2.3.5/lib/active_record/callbacks.rb:228: warning: `*' interpreted as argument prefix
Exception `Gem::LoadError' at /usr/local/lib/site_ruby/1.8/rubygems.rb:777 - Could not find RubyGem activerecord-mysql-adapter (>= 0)

/usr/lib/ruby/gems/1.8/gems/actionpack-2.3.5/lib/action_controller/routing/routing_ext.rb:2: warning: method redefined; discarding old to_param
/usr/lib/ruby/gems/1.8/gems/actionpack-2.3.5/lib/action_controller/routing/recognition_optimisation.rb:55: warning: method redefined; discarding old recognize_path
/usr/lib/ruby/gems/1.8/gems/actionpack-2.3.5/lib/action_controller/middleware_stack.rb:84: warning: given block not used
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:306: warning: global variable `$gems_rake_task' not initialized
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31 - no such file to load -- openid
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:38 - no such file to load -- openid
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:162 - no such file to load -- openid
Exception `Gem::LoadError' at /usr/local/lib/site_ruby/1.8/rubygems.rb:777 - Could not find RubyGem ruby-openid (>= 2.1.4)

/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:306: warning: global variable `$gems_rake_task' not initialized
/var/www/mollenhour.com/dev/redmine/config/initializers/10-patches.rb:9: warning: redefine human_attribute_name
/var/www/mollenhour.com/dev/redmine/config/initializers/10-patches.rb:17: warning: method redefined; discarding old full_messages
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31 - no such file to load -- mysql
/var/www/mollenhour.com/dev/redmine/app/models/wiki_content.rb:99: warning: method redefined; discarding old previous
(eval):1: warning: method redefined; discarding old hash_for_repositories_entry_path
(eval):1: warning: method redefined; discarding old repositories_entry_path
(eval):24: warning: method redefined; discarding old formatted_repositories_entry_path
(eval):1: warning: method redefined; discarding old hash_for_repositories_entry_url
(eval):1: warning: method redefined; discarding old repositories_entry_url
(eval):24: warning: method redefined; discarding old formatted_repositories_entry_url
/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:409: warning: global variable `$rails_rake_task' not initialized
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31 - no such file to load -- mailer_helper
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:38 - no such file to load -- mailer_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:162 - no such file to load -- mailer_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:269 - no such file to load -- mailer_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:226 - no such file to load -- mailer_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/actionmailer-2.3.5/lib/action_mailer/helpers.rb:56 - Missing helper file helpers/mailer_helper.rb
/var/www/mollenhour.com/dev/redmine/app/models/mailer.rb:27: warning: redefine default_url_options
/var/www/mollenhour.com/dev/redmine/app/models/mailer.rb:401: warning: method redefined; discarding old add_message_id
/var/www/mollenhour.com/dev/redmine/app/models/query.rb:260: warning: method redefined; discarding old available_columns
/var/www/mollenhour.com/dev/redmine/app/models/repository/cvs.rb:108: warning: useless use of a variable in void context
/var/www/mollenhour.com/dev/redmine/lib/redmine/plugin.rb:55: warning: instance variable @settings not initialized
/var/www/mollenhour.com/dev/redmine/app/models/setting.rb:143: warning: redefine openid?
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31 - no such file to load -- sys_helper
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:38 - no such file to load -- sys_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:162 - no such file to load -- sys_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:269 - no such file to load -- sys_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:226 - no such file to load -- sys_helper
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:31 - no such file to load -- wikis_helper
Exception `MissingSourceFile' at /usr/local/lib/site_ruby/1.8/rubygems/custom_require.rb:38 - no such file to load -- wikis_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:162 - no such file to load -- wikis_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:269 - no such file to load -- wikis_helper
Exception `MissingSourceFile' at /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:226 - no such file to load -- wikis_helper

RE: Upgrade to 0.9.2, please help! - Added by Colin Mollenhour about 14 years ago

Update.. When I tested via webrick before I had forgotten to change the protocol from https to http.. So I tried with http and it works with webrick! How can I get it fixed with apache/mod_passenger now?

Thanks,
Colin

RE: Upgrade to 0.9.2, please help! - Added by Colin Mollenhour about 14 years ago

Update.. Checked Apache logs (doh!) and each request generates this:

[Sun Feb 28 08:48:29 2010] [warn] (104)Connection reset by peer: mod_fcgid: read data from fastcgi server error.
[Sun Feb 28 08:48:29 2010] [error] [client 68.52.135.113] Premature end of script headers: dispatch.fcgi

What does it mean?

Thanks,
Colin

RE: Upgrade to 0.9.2, please help! - Added by Colin Mollenhour about 14 years ago

Finally got it fixed.. In case anyone runs across this thread, make sure all your ruby stuff is world-readable with:
sudo chmod -R a+rX /usr/lib/ruby
This should probably be added to the FAQ since apparently gem install xxx doesn't set proper permissions! How annoying!

    (1-4/4)