This project is archived and is in readonly mode.

#4524 ✓invalid
Daniel Spangenberg

Mongrel under Rails 3 beta 3

Reported by Daniel Spangenberg | May 3rd, 2010 @ 12:42 AM

Hey there,
I tryed to deploy my rails app to my server.
After I started Mongrel and visited the site this logfile was created.
I hope this log helps.

Daemonized, any open files are closed. Look at /srv/www/portal/current/tmp/pids/mongrel.8020.pid and /srv/www/portal/current/log/mongrel.8020.log for info. Starting Mongrel listening at 127.0.0.1:8020 ** Starting Rails with production environment... /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.0.beta3/lib/active_support/dependencies.rb:209:in require': no such file to load -- dispatcher (LoadError)

from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.0.beta3/lib/active_support/dependencies.rb:209:in `require'
from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.0.beta3/lib/active_support/dependencies.rb:197:in `load_dependency'
from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.0.beta3/lib/active_support/dependencies.rb:209:in `require'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/rails.rb:148:in `rails'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:113:in `cloaker_'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:149:in `call'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:149:in `listener'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:99:in `cloaker_'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:50:in `call'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:50:in `initialize'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:84:in `new'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:84:in `run'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/command.rb:212:in `run'
from /usr/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:281
from /usr/bin/mongrel_rails:19:in `load'
from /usr/bin/mongrel_rails:19

Comments and changes to this ticket

  • Runar2

    Runar2 June 13th, 2010 @ 09:38 PM

    I'm experiencing the exact same problem, and it's really annoying.

  • Rohit Arondekar

    Rohit Arondekar June 14th, 2010 @ 03:31 PM

    Can you confirm if this problem still exists on Rails 3 Beta 4?

    It might be that Mongrel doesn't support Rails 3 yet. But please do try and confirm if this issue still exists on Rails 3 Beta 4.

  • knapo

    knapo June 18th, 2010 @ 07:33 PM

    Same on Rails 3.0.0.beta4 (and Rails 2.3.8 as well)

  • Rohit Arondekar

    Rohit Arondekar June 19th, 2010 @ 02:10 AM

    • State changed from “new” to “open”
    • Assigned user set to “josh”

    Confirmed on Rails master with both mongrel 1.1.5 and 1.2.0.pre2.

    I found this issue and I think it's related http://github.com/fauna/mongrel/issues#issue/2

  • Rohit Arondekar
  • Jean

    Jean August 7th, 2010 @ 01:21 PM

    • Tag changed from rails3 server startup to rails3 server startup, deployment, mongrel, rails3rc
    • Importance changed from “” to “Low”

    on rails3-rc I have the exact same problem:

    $ mongrel_rails start
    ** Starting Mongrel listening at 0.0.0.0:3000
    ** Starting Rails with development environment...
    You did not specify how you would like Rails to report deprecation notices for your development environment, please set config.active_support.deprecation to :log at config/environments/development.rb
    /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/activesupport-3.0.0.rc/lib/active_support/dependencies.rb:219:in `require': no such file to load -- dispatcher (LoadError)
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/activesupport-3.0.0.rc/lib/active_support/dependencies.rb:219:in `require'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/activesupport-3.0.0.rc/lib/active_support/dependencies.rb:205:in `load_dependency'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/activesupport-3.0.0.rc/lib/active_support/dependencies.rb:570:in `new_constants_in'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/activesupport-3.0.0.rc/lib/active_support/dependencies.rb:205:in `load_dependency'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/activesupport-3.0.0.rc/lib/active_support/dependencies.rb:219:in `require'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/../lib/mongrel/rails.rb:148:in `rails'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/mongrel_rails:113:in `cloaker_'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:149:in `call'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:149:in `listener'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/mongrel_rails:99:in `cloaker_'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:50:in `call'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:50:in `initialize'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/mongrel_rails:84:in `new'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/mongrel_rails:84:in `run'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/../lib/mongrel/command.rb:212:in `run'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/gems/mongrel-1.1.5/bin/mongrel_rails:281
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/bin/mongrel_rails:19:in `load'
        from /home/jean/.rvm/gems/ruby-1.8.7-p299/bin/mongrel_rails:19
    

    mongrel_rails fails to start on a load error
    however starting with the rails server command it says

    => Booting Mongrel
    => Rails 3.0.0.rc application starting in development on http://0.0.0.0:3000
    => Call with -d to detach
    => Ctrl-C to shutdown server
    You did not specify how you would like Rails to report deprecation notices for your development environment, please set config.active_support.deprecation to :log at config/environments/development.rb
    
    and it starts
  • makkaroni

    makkaroni September 2nd, 2010 @ 02:15 PM

    Same thing here:
    rails3.0.0,
    mongrel 1.1.5

    
    test_app# mongrel_rails start
    ** Starting Mongrel listening at 0.0.0.0:3000
    ** Starting Rails with development environment...
    /usr/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require': no such file to load -- dispatcher (LoadError)
        from /usr/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
        from /usr/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
        from /usr/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:591:in `new_constants_in'
        from /usr/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:225:in `load_dependency'
        from /usr/local/lib/ruby/gems/1.8/gems/activesupport-3.0.0/lib/active_support/dependencies.rb:239:in `require'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/rails.rb:148:in `rails'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:113:in `cloaker_'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:149:in `call'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:149:in `listener'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:99:in `cloaker_'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:50:in `call'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:50:in `initialize'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:84:in `new'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:84:in `run'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/command.rb:212:in `run'
        from /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:281
        from /usr/local/bin/mongrel_rails:19:in `load'
        from /usr/local/bin/mongrel_rails:19
    

    But using the rails server command:

    
    test_app# rails server
    => Booting WEBrick
    => Rails 3.0.0 application starting in development on http://0.0.0.0:3000
    => Call with -d to detach
    => Ctrl-C to shutdown server
    [2010-09-02 15:06:56] INFO  WEBrick 1.3.1
    [2010-09-02 15:06:56] INFO  ruby 1.8.7 (2009-06-12) [i686-linux]
    [2010-09-02 15:07:01] INFO  WEBrick::HTTPServer#start: pid=15279 port=3000
    
  • Jonas

    Jonas September 28th, 2010 @ 10:49 PM

    I get the same error message.

    After I have added gem 'dispatcher' to the Gemfile the mongrel_cluster starts without an error.

    But it does not serve any request:

    Tue Sep 28 23:46:18 +0200 2010: Error calling Dispatcher.dispatch #<NameError: uninitialized constant ActionController::CgiRequest>
    /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/rails.rb:76:in
    process' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/rails.rb:74:insynchronize' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/rails.rb:74:in process' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:159:inprocess_client' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:158:in each' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:158:inprocess_client' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:285:in run' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:285:ininitialize' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:285:in new' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:285:inrun' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:268:in initialize' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:268:innew' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel.rb:268:in run' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:282:inrun' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:281:in each' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/configurator.rb:281:inrun' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:128:in run' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/../lib/mongrel/command.rb:212:inrun' /var/lib/gems/1.8/gems/mongrel-1.1.5/bin/mongrel_rails:281 /var/lib/gems/1.8/bin/mongrel_rails:19:in load' /var/lib/gems/1.8/bin/mongrel_rails:19 </code>

  • Henrik Hodne

    Henrik Hodne September 29th, 2010 @ 04:43 AM

    Try adding gem 'mongrel' to your Gemfile and running rails server instead of mongrel_rails, and tell us what your results are. Seems to work just fine for me. I think mongrel_rails was created for Rails 2, and not Rails 3.

    This is what I tested it with:

    › ruby -v
    ruby 1.8.7 (2010-08-16 patchlevel 302) [i686-darwin10.5.0]
    › rails -v
    Rails 3.0.0
    › gem spec mongrel | ruby -ryaml -rubygems -e "puts YAML.load(STDIN).version.to_s"
    1.1.5
    

    These are the complete steps to reproduce what I did (assuming ruby is installed):

    › gem install rails
    › rails new Rails3TestApp
    › cd Rails3TestApp
    › echo "gem 'mongrel'" > Gemfile
    › bundle install
    › rails generate scaffold foo bar:string
    › rake db:migrate
    › rails server # Then go to localhost:3000/foos in your browser.
    

    Hope this helps.

  • Henrik Hodne

    Henrik Hodne September 29th, 2010 @ 05:57 AM

    Oops, that echo line should be echo "gem 'mongrel'" >> Gemfile. Otherwise it would overwrite the entire file.

  • Jonas

    Jonas September 29th, 2010 @ 07:12 PM

    Hendrik,

    you are right. mongrel with script/rails s mongrel works perfect.

    Seems to be, that mongrel_rails does not work with Rails 3. That's very bad, because many people use mongrel cluster on production.

    http://github.com/fauna/mongrel/issues#issue/2

    But it's not an Rails problem.

    Can any rails dev close that bug?

    Thanks

  • David Trasbo

    David Trasbo September 29th, 2010 @ 07:46 PM

    • State changed from “open” to “invalid”

    Done.

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

Pages