[Mongrel] mongrel timing out

Michael Steinfeld
Mon, 19 Mar 2007 17:28:25 -0000

Hi Ezra,

My mistake was that I didn''t install the mysql gem. I did think it was
installed already, but it wasn''t so once I did--about 24hrs ago-- my
mongrels have not died. Thanks for responding though.

On another note, do you typically change you mysql settings? What do
you set your interactive_timeout to in environments.rb?

Thanks,

Mike

On 3/18/07, Ezra Zygmuntowicz <ezmobius at gmail.com>
wrote:
> Michael-
>
>
>         The "Mongrel timed out on this thread" message usually
happens when
> your Rails action is taking too long to complete and more requests
> are queuing up in mongrel. Do you have any really long running
> actions in your app? Are you shelling out or using IO.popen to call
> external programs?
>
> -Ezra
>
> On Mar 18, 2007, at 7:21 AM, Michael Steinfeld wrote:
>
> > I am not sure when it exactly occurred but I have 2 servers I am
> > about to migrate to apache+mongrel from lighty+fastcgi
> >
> > oddly, both my servers seemed to have died at the same time
> > everytime I restart within a 24 hr period ( I don''t know
when, my
> > logs don''t show it ). Can someone please point me in the
direction
> > of what I need to do to trace the cause of this. Or what you would
> > need from me to help?
> >
> >
> >
> >
> > This is a RHEL4 box running rails 1.2.2 and ruby 1.8.5
> >
> > here is part of the log entry
> >
> > Mongrel timed out this thread: shutdown
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:675:in
> > `write''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/vendor/mysql.rb:532:in `write''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/vendor/mysql.rb:506:in `command''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/vendor/mysql.rb:238:in `close''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/mysql_adapter.rb:236:in
> >  `disconnect!''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/mysql_adapter.rb:231:in
> >  `reconnect!''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/abstract_adapter.rb:93:
> > in `verify!''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/abstract/connection_spe
> > cification.rb:109:in `verify_active_connections!''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord- 1.15.3/lib/
> > active_record/connection_adapters/abstract/connection_spe
> > cification.rb:108:in `each_value''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/abstract/connection_spe
> > cification.rb:108:in `verify_active_connections!''
> > /usr/local/lib/ruby/gems/1.8/gems/rails-1.2.3/lib/dispatcher.rb:
> > 111:in `prepare_application''
> > /usr/local/lib/ruby/gems/1.8/gems/rails-1.2.3/lib/dispatcher.rb:
> > 39:in `dispatch''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/rails.rb:
> > 78:in `process''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/rails.rb:
> > 76:in `synchronize''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel- 1.0/lib/mongrel/rails.rb:
> > 76:in `process''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:618:in
> > `process_client''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:617:in
> > `each''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:617:in
> > `process_client''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:736:in
> > `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:736:in
> > `initialize''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:736:in
> > `new''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:736:in
> > `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:720:in
> > `initialize''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:720:in
> > `new''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:720:in
> > `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/
> > configurator.rb:271:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/
> > configurator.rb:270:in `each''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/
> > configurator.rb:270:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel- 1.0/bin/mongrel_rails:
> > 127:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/
> > command.rb:211:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243
> > /usr/local/bin/mongrel_rails:16:in `load''
> > /usr/local/bin/mongrel_rails:16
> > Mongrel timed out this thread: shutdown
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:675:in
> > `write''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/vendor/mysql.rb:532:in `write''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/vendor/mysql.rb:506:in `command''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/vendor/mysql.rb:238:in `close''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/mysql_adapter.rb:236:in
> >  `disconnect!''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/mysql_adapter.rb:231:in
> >
> > Mongrel timed out this thread: shutdown
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:675:in
> > `write''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/vendor/mysql.rb:532:in `write''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/vendor/mysql.rb:506:in `command''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/vendor/mysql.rb:238:in `close''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/mysql_adapter.rb:236:in
> > `disconnect!''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/mysql_adapter.rb:231:in
`reconnect!''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/abstract_adapter.rb:93:in
`verify!''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/abstract/
> > connection_specification.rb:10
> > 9:in `verify_active_connections!''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/
> > active_record/connection_adapters/abstract/
> > connection_specification.rb:10
> > 8:in `each_value''
> > /usr/local/lib/ruby/gems/1.8/gems/activerecord- 1.15.3/lib/
> > active_record/connection_adapters/abstract/
> > connection_specification.rb:10
> > 8:in `verify_active_connections!''
> > /usr/local/lib/ruby/gems/1.8/gems/rails-1.2.3/lib/dispatcher.rb:
> > 111:in `prepare_application''
> > /usr/local/lib/ruby/gems/1.8/gems/rails-1.2.3/lib/dispatcher.rb:
> > 39:in `dispatch''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/rails.rb:
> > 78:in `process''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel- 1.0/lib/mongrel/rails.rb:
> > 76:in `synchronize''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/rails.rb:
> > 76:in `process''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:618:in
> > `process_client''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:617:in
> > `each''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:617:in
> > `process_client''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel- 1.0 /lib/mongrel.rb:
> > 736:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:736:in
> > `initialize''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:736:in
> > `new''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel- 1.0/lib/mongrel.rb:
> > 736:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:720:in
> > `initialize''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel.rb:720:in
> > `new''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel- 1.0/lib/mongrel.rb:
> > 720:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/
> > configurator.rb:271:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/
> > configurator.rb:270:in `each''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/lib/mongrel/
> > configurator.rb:270:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:
> > 127:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel- 1.0/lib/mongrel/
> > command.rb:211:in `run''
> > /usr/local/lib/ruby/gems/1.8/gems/mongrel-1.0/bin/mongrel_rails:243
> > /usr/local/bin/mongrel_rails:16:in `load''
> > /usr/local/bin/mongrel_rails:16
> > Mongrel timed out this thread: shutdown
> >
> >
> > --
> > -mike
> >
> > _______________________________________________
> > Mongrel-users mailing list
> > Mongrel-users at rubyforge.org
> > http://rubyforge.org/mailman/listinfo/mongrel-users
>
> -- Ezra Zygmuntowicz
> -- Lead Rails Evangelist
> -- ez at engineyard.com
> -- Engine Yard, Serious Rails Hosting
> -- (866) 518-YARD (9273)
>
>
> _______________________________________________
> Mongrel-users mailing list
> Mongrel-users at rubyforge.org
> http://rubyforge.org/mailman/listinfo/mongrel-users
>


--
-mike