After doing a bundle install, I run 'rails s' it runs into this error.
$ rails s
/Users/XXXX/.rvm/gems/ruby-1.8.7-p352@r3/gems/json-1.5.3/ext/json/ext/json/ext/parser.bundle: [BUG] Segmentation fault
ruby 1.8.7 (2011-06-30 patchlevel 352) [i686-darwin10.8.0]
Abort trap
Any help would be greatly appreciated. Thanks!
In practice, segfaults are almost always due to trying to read or write a non-existent array element, not properly defining a pointer before using it, or (in C programs) accidentally using a variable's value as an address (see the scanf example below).
A segmentation fault occurs when a program attempts to access a memory location that it is not allowed to access, or attempts to access a memory location in a way that is not allowed (for example, attempting to write to a read-only location, or to overwrite part of the operating system).
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:
Your gemset is not compiled for the version of ruby you are using. I found this worked for me:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With