Question

1-Click RoR: Unicorn loops - Refreshing Gem list

Posted November 25, 2015 2.6k views
Ruby on Rails Ubuntu Ruby One-Click Install Apps

I am running on 1-Click RoR: Ruby 2.1.3, Rails 4.1.6, Unicorn 4.9.0, RVM 1.26.11.

My app was running fine until I have update Ubuntu and after server restart Unicorn uses 100 % CPU and in the log I have found repeating this:

/usr/local/rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- bundler/setup (LoadError)
from /usr/local/rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /home/rails/config/boot.rb:4:in `<top (required)>'
from /usr/local/rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /usr/local/rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /home/rails/config/application.rb:1:in `<top (required)>'
from /usr/local/rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /usr/local/rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /home/rails/config/environment.rb:2:in `<top (required)>'
from /usr/local/rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /usr/local/rvm/rubies/ruby-2.1.3/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from config.ru:4:in `block in <main>'
from /usr/local/rvm/gems/ruby-2.1.3/gems/rack-1.5.5/lib/rack/builder.rb:55:in `instance_eval'
from /usr/local/rvm/gems/ruby-2.1.3/gems/rack-1.5.5/lib/rack/builder.rb:55:in `initialize'
from config.ru:1:in `new'
from config.ru:1:in `<main>'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/lib/unicorn.rb:48:in `eval'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/lib/unicorn.rb:48:in `block in builder'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/lib/unicorn/http_server.rb:768:in `call'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/lib/unicorn/http_server.rb:768:in `build_app!'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/lib/unicorn/http_server.rb:632:in `init_worker_process'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/lib/unicorn/http_server.rb:655:in `worker_loop'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/lib/unicorn/http_server.rb:529:in `spawn_missing_workers'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/lib/unicorn/http_server.rb:540:in `maintain_worker_count'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/lib/unicorn/http_server.rb:294:in `join'
from /usr/local/rvm/gems/ruby-2.1.3/gems/unicorn-4.9.0/bin/unicorn:126:in `<top (required)>'
from /usr/local/rvm/gems/ruby-2.1.3/bin/unicorn:23:in `load'
from /usr/local/rvm/gems/ruby-2.1.3/bin/unicorn:23:in `<main>'
from /usr/local/rvm/gems/ruby-2.0.0-p353/bin/ruby_executable_hooks:15:in `eval'
from /usr/local/rvm/gems/ruby-2.0.0-p353/bin/ruby_executable_hooks:15:in `<main>'
E, [2015-11-24T21:37:07.877451 #10157] ERROR -- : reaped #<Process::Status: pid 10627 exit 1> worker=0
I, [2015-11-24T21:37:07.877962 #10157]  INFO -- : worker=0 spawning...
I, [2015-11-24T21:37:07.880457 #10630]  INFO -- : worker=0 spawned pid=10630
I, [2015-11-24T21:37:07.889954 #10630]  INFO -- : Refreshing Gem list

I tried to update Gems, it didn’t work and I didn’t make any changes in source code.

Any help highly appreciated.

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

1 answer

Hi
I faced this same issue on the production server. Can you please let me know how you fixed this issue?

Submit an Answer