From: "shyamc (Shyam Sundhar C)" Date: 2022-07-03T17:29:25+00:00 Subject: [ruby-core:109127] [Ruby master Bug#18895] Mac M1 Monterey 12.4 - Bus error at active support Issue #18895 has been updated by shyamc (Shyam Sundhar C). austin (Austin Ziegler) wrote in #note-4: > shyamc (Shyam Sundhar C) wrote in #note-3: > > I have installed the rbenv with command `arch -x86_64 brew install rbenv ruby-build`. > > > > Also I am not sure that its an option where I can copy the `~/.rbenv` and homebrew files from intel to M1. Can you please advice ? > > Yeah, don���t do that. Either one. > > Unless there is something that you must absolutely link against an extant x86 library that isn���t source available, *always* build native. > > Running under x86 on M1 is *possible*, but: > > 1. Not all x86 instructions work (sometimes resulting in segfaults) > 2. There is a performance hit involved, even if it is negligible most of the time. > > If you cannot build Ruby 2.3 or the necessary gems as native M1 (aarch64, which is entirely possible because Ruby 2.3 EOLed in 2019), then consider shifting your workflow for your older application so that you are running it in a Docker image, where you���re unlikely to have mixed binary formats. > > I���ve been using M1 for a while now, and if you find yourself typing `arch -x86_64` for pretty much *anything*, you���re doing it wrong (I haven���t had to do so in more than a year, although I���m also using new versions of Ruby, not Ruby 2.3). Yea. I understand. I have plans to migrate the ruby version but for now I can't get into that. Running that in a docker container makes more sense for me at this time. Thanks ! ---------------------------------------- Bug #18895: Mac M1 Monterey 12.4 - Bus error at active support https://bugs.ruby-lang.org/issues/18895#change-98268 * Author: shyamc (Shyam Sundhar C) * Status: Feedback * Priority: Normal * ruby -v: ruby 2.3.8p459 (2018-10-18 revision 65136) [x86_64-darwin21] * Backport: 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN ---------------------------------------- Hi All, I have been using intel Mac for a long time. Just moving to M1 environment. Got several issues during bundle install but was able to fix it. Now when I run 'bundle exec rails s' and any callbacks is being called, I am getting this bug with lengthy terminal output. Checked out and tried the existing issue : https://bugs.ruby-lang.org/issues/18555 but unable to resolve it. So here I am, looking for help. ``` ruby /Users/schockalingam/.rbenv/versions/2.3.8/lib/ruby/gems/2.3.0/gems/activesupport-3.2.22.5/lib/active_support/callbacks.rb:162: [BUG] Bus Error at 0x000000030db30ff8 ruby 2.3.8p459 (2018-10-18 revision 65136) [x86_64-darwin21] -- Crash Report log information -------------------------------------------- See Crash Report log file under the one of following: * ~/Library/Logs/CrashReporter * /Library/Logs/CrashReporter * ~/Library/Logs/DiagnosticReports * /Library/Logs/DiagnosticReports for more details. Don't forget to include the above Crash Report log file in bug reports. -- Control frame information ----------------------------------------------- c:0151 p:---- s:0859 e:000858 CFUNC :class_eval c:0150 p:0044 s:0853 e:000852 METHOD /Users/schockalingam/.rbenv/versions/2.3.8/lib/ruby/gems/2.3.0/gems/activesupport-3.2.22.5/lib/active_support/callbacks.rb:162 c:0149 p:0089 s:0849 e:000848 METHOD /Users/schockalingam/.rbenv/versions/2.3.8/lib/ruby/gems/2.3.0/gems/activesupport-3.2.22.5/lib/active_support/callbacks.rb:107 [FINISH] c:0148 p:---- s:0841 e:000840 CFUNC :new c:0147 p:0026 s:0833 e:000832 BLOCK /Users/schockalingam/.rbenv/versions/2.3.8/lib/ruby/gems/2.3.0/gems/activesupport-3.2.22.5/lib/active_support/callbacks.rb:496 [FINISH] ``` Thanks in advance, Shyam C ---Files-------------------------------- ruby-2022-07-03-152254.ips (33.8 KB) gem_env.txt (1.39 KB) terminal_output.txt (944 KB) -- https://bugs.ruby-lang.org/ Unsubscribe: