Segmentation fault when running 'rails s'
rvm gemset empty
rvm use ree@my-gemset
gem install bundler
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:
- '
gem list | cut -d" " -f1 | xargs gem uninstall -aIx
' gem install bundler
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
Ruby/Rails Array of Strings to Postgresql Insert
The Program 'Rails' Is Currently Not Installed
Ruby Is Already Using the Class Name of My Model
Rails Cancan and State MAChine - Authorizing States
Insert Rows on Specific Line in a File
Project Euler #3 in Ruby Solution Times Out
Compass Error for Command 'Grunt Server'
Scraping an Angularjs Application
Linking Two Models in a Multi-Model Form
How to Refactor Openssl Pkcs5_Keyivgen in Ruby
Ruby on Rails How to Deal with Nan
How to Test Whether a String Would Match a Glob in Ruby
How to Convert 1 to "First", 2 to "Second", and So On, in Ruby