Rails S Return: [Bug] Segmentation Fault

Segmentation fault when running 'rails s'

  1. rvm gemset empty
  2. rvm use ree@my-gemset
  3. gem install bundler
  4. bundle install

This solved the issue for me. Must be some extension got compiled against the wrong version of Ruby (in my case). Hope it works for you!

If you are not using RVM, I found this command to uninstall all gems:

  1. 'gem list | cut -d" " -f1 | xargs gem uninstall -aIx'
  2. gem install bundler
  3. bundle install

Rails 5 Bug (Segmentation fault)

It looks like a defect with the sqlite3 gem.. See bug report here: https://bugs.ruby-lang.org/issues/12781 and https://bugs.ruby-lang.org/issues/12795

It does not appear there is a fix yet.. I'm having this issue as well, initially I was able to run brew update and then bundle update in a new terminal window which allowed me to call .connection on my models and get the console access again.. today this is still working but a very labourious process.

How to solve the [BUG] Segmentation fault?

EDITED: Based on the information you have provided so far, it seems like you have found a bug in Ruby 1.9.3. I recommend that you report this to the Ruby core team.

Until this bug is fixed, you must find a way around it. To find a way around it, you must get more details about exactly what does and does not trigger it.

In the stack trace which you posted, it looks like line 68 of bundler/runtime.rb is requiring the yard gem. Using Ruby 1.9.3, try requiring the yard gem yourself, from IRB or a simple test script. Does that trigger the error? If not, go to the method which "realer" is calling in "bundler" (bundler.rb, line 118). Try calling that method (whatever it is) yourself, from a test script. Does that trigger the error? ...and so on.

Fortunately, when you install Ruby gems, the source code is available in the "gems" directory, and you can study and modify it. I have also had to "hack" the source code of my gems before to work around problems (until a fixed version of the gem is released).

Segmentation fault with Rails after upgrading to OS Sierra, possibly related to sqlite3 gem

Looks like a patch has been issued! The patch will look for sqlite3 in your brew folder instead of using Apple's supplied version by default. Simply run:

bundle update

to get the latest version of sqlite3-ruby and if you don't already have sqlite3 installed in your homebrew directory, run:

brew install sqlite3


Related Topics



Leave a reply



Submit