On 12 Jan 2009, at 10:42, Wincent Colaiuta wrote:
> > My last deployment was based on Rails 2.1.2 and would run for months > without restarts and without leaking memory; memory would sit at > around 35 to 40M per Mongrel instance. > > On updating to 2.2.2 I'm seeing gradual memory bloat and every few > days it hits its resource limit (130M per Mongrel) and monit does a > restart. > I know of two memory leaks in 2.2.2: http://github.com/rails/rails/commit/9f69ff12d44c4d1e475fd6efede120ccedba3b3e http://github.com/rails/rails/commit/5ede4ce188d29aef94af78f27d89169ac4ee54cd Fred > I don't think it's a change in my own code that introduced the leak, > seeing as I made only minimal changes necessary to fix breakage caused > by updating Rails: > > $ git diff 3f39f3a..5fc7345 --stat -- app config lib > app/controllers/application.rb | 26 +----- > app/controllers/comments_controller.rb | 4 +- > app/helpers/application_helper.rb | 10 +++ > app/helpers/articles_helper.rb | 6 -- > app/models/user.rb | 4 +- > app/views/articles/edit.html.haml | 2 +- > app/views/articles/new.html.haml | 2 +- > app/views/articles/show.html.haml | 2 +- > app/views/comments/edit.html.haml | 2 +- > app/views/issues/_issues.html.haml | 2 +- > app/views/search/_article.html.haml | 2 +- > app/views/search/_issue.html.haml | 2 +- > app/views/search/_post.html.haml | 2 +- > app/views/search/_topic.html.haml | 2 +- > config/boot.rb | 4 +- > config/deploy.rb | 3 +- > config/environment.rb | 14 +--- > config/environments/development.rb | 2 - > config/environments/production.rb | 2 - > config/environments/test.rb | 8 +-- > config/initializers/extensions.rb | 17 ++++ > config/locales/en.yml | 5 + > lib/active_record/acts/classifiable.rb | 2 +- > lib/active_record/acts/searchable.rb | 2 +- > lib/sortable.rb | 2 +- > lib/tasks/rspec.rake | 132 ++++++++++++++++++++++++ > ++++++++ > 26 files changed, 194 insertions(+), 67 deletions(-) > > So I'm trying to hunt down the source of the leak, but it's kind of > intimidating because it's almost certainly a change in "vendor", which > churned a whole lot from 2.1.2 to 2.2.2: > > 1313 files changed, 105152 insertions(+), 63806 deletions(-) > > Wondering if anyone else has seen memory leaks creep in while moving > from 2.1.2 to 2.2.2? > > Cheers, > Wincent > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---

