Question on memory allocation error in 1.0.1.devel.4171
Added by Oleg Feferman over 14 years ago
Hello,
I am new to Redmine, sorry if my question is stupid but here it is (I've tried search but found nothing)
Redmine 1.0.1.devel.4171 is running on my VPS. I have created test project and repository for it (which I can access via svn client).
At the beginning everything works good but after some time when you go to repository tab inside project - following message is shown:
Internal error An error occurred on the page you were trying to access. If you continue to experience problems please contact your redMine administrator for assistance. Back
When I check logs I see following
Processing RepositoriesController#show (for 1.2.3.4 at 2010-09-24 13:42:21) [GET] Parameters: {"action"=>"show", "id"=>"proj-test", "controller"=>"repositories"} Errno::ENOMEM (Cannot allocate memory - svn list --xml 'https://myserv.com/svn/proj-test/'@HEAD --username 'admin' --password 'admin123' --no-auth-cache --non-interactive): lib/redmine/scm/adapters/abstract_adapter.rb:191:in `popen' lib/redmine/scm/adapters/abstract_adapter.rb:191:in `shellout' lib/redmine/scm/adapters/abstract_adapter.rb:177:in `shellout' lib/redmine/scm/adapters/subversion_adapter.rb:82:in `entries' app/models/repository.rb:63:in `entries' app/controllers/repositories_controller.rb:79:in `show' /usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service' /usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run' /usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread' /usr/lib/ruby/1.8/webrick/server.rb:162:in `start' /usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread' /usr/lib/ruby/1.8/webrick/server.rb:95:in `start' /usr/lib/ruby/1.8/webrick/server.rb:92:in `each' /usr/lib/ruby/1.8/webrick/server.rb:92:in `start' /usr/lib/ruby/1.8/webrick/server.rb:23:in `start' /usr/lib/ruby/1.8/webrick/server.rb:82:in `start' Rendering /opt/redmine/public/500.html (500 Internal Server Error)
If now I go to Administration\Settings and try to send test email - it is not sent and following messageis displayed:
An error occurred while sending mail (Cannot allocate memory - /usr/sbin/sendmail -i -t)
Now if I restart redmine (by killing it process) and launch it again - everything works well until some time (several hours maybe) but than it fails again.
What can I do to fix this?
Thanks,
Oleg
Replies (5)
RE: Question on memory allocation error in 1.0.1.devel.4171 - Added by Felix Schäfer over 14 years ago
Allocate more memory to the VPS (my redmine processes typically take up in the ranges of 120M private/280M virtual memory on passenger, most file processing (e.g. sending files and so on) happening in memory, this could also get bigger depending on the filesizes your redmine handles), and consider switching to something else than webrick, which is fine for test and dev environments, but not well suited for production. A drop-in alternative is mongrel (IIRC you just need to install the mongrel gem and script/server mongrel
instead of just script/server
), other alternatives are passenger (apache module) or thin, unicorn, and so on.
RE: Question on memory allocation error in 1.0.1.devel.4171 - Added by Oleg Feferman over 14 years ago
Hello Felix,
Thank you for your answer! I am having 256M of memory on my VPS and ps shows me that redmine uses 25% with (approx 18% immediately after start). Seems like it is enough. But I launch it from screen and detaching from it - don't you know if this may create some memory limitations...
So in your opinion - what is the best alternative to webrick? Mongrel?
Thanks you!
Oleg
RE: Question on memory allocation error in 1.0.1.devel.4171 - Added by Felix Schäfer over 14 years ago
Oleg Feferman wrote:
So in your opinion - what is the best alternative to webrick? Mongrel?
If you have apache on that box: passenger, if not, the best compromise between performance and ease-of-use/configuration is mongrel.
RE: Question on memory allocation error in 1.0.1.devel.4171 - Added by Oleg Feferman over 14 years ago
Felix, Thank you! Will try to go with passenger than :)
RE: Question on memory allocation error in 1.0.1.devel.4171 - Added by Oleg Feferman over 14 years ago
If somebody cares I ended with mongrel installed and everything works well with it.