You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried using Concurrent.use_stdlib_logger(Logger::DEBUG) to get more information but nothing else is printed to the console. How can I start debugging this problem?
* Operating system: linux
* Ruby implementation: Ruby 2.6.3
* `concurrent-ruby` version: 1.1.5
* `concurrent-ruby-ext` installed: no
* `concurrent-ruby-edge` used: no
After some testing it seems that this commit is the culprit: eb81fff "avoid "can't be called from trap context" errors in ThreadLocalVar". Reverting that commit fixes the problem.
I do not have a reproducer, however, I've spotted potentially dangerous array access in the code which is fixed in #821, please try it and let me know if the issue goes away. Thanks.
Thanks @pawelpacana for the report! I think I see the issue, the assignment conflicts with the each_value on line 100. I'll fix it asap, let you verify and then release a new version.
The stacktraces since the last close of this issue look completely unrelated to concurrent-ruby.
Also if there is a new segfault related to concurrent-ruby, please open a new issue.
Activity
mwsteb commentedon Aug 5, 2019
Not sure if this should be a separate issue or not, but I'm here to report that it happens on Ruby 2.5.5p157 as well. Here's the trace:
cesarizu commentedon Aug 23, 2019
After some testing it seems that this commit is the culprit: eb81fff "avoid "can't be called from trap context" errors in ThreadLocalVar". Reverting that commit fixes the problem.
pitr-ch commentedon Aug 24, 2019
Thank you for reporting and finding out the commit, it is a big help.
rubenfonseca commentedon Aug 26, 2019
We're also seeing this problem with ruby-2.6.3.
dmtask commentedon Aug 27, 2019
Same Problem here.
pitr-ch commentedon Aug 27, 2019
I'll look into this as soon as possible.
dmtask commentedon Aug 28, 2019
@pitr-ch Thank you. :)
pitr-ch commentedon Aug 28, 2019
I do not have a reproducer, however, I've spotted potentially dangerous array access in the code which is fixed in #821, please try it and let me know if the issue goes away. Thanks.
dmtask commentedon Sep 2, 2019
We were able to avoid the mistake and solved it differently. I still try to test the bugfix as fast as possible.
pitr-ch commentedon Sep 3, 2019
Thank you @dmtask!
dmtask commentedon Sep 5, 2019
For me, it works.
davidw commentedon Sep 5, 2019
I am getting segfaults and some of them show this:
I have a minimalistic Rails app that reproduces the problem, if that's helpful.
I tried applying the patch above, but it does not seem to fix it. I just hand-edited in to version 1.1.5, so I don't know if that's sufficient.
pitr-ch commentedon Sep 6, 2019
Thanks @dmtask and @davidw for testing and link to the reproducer. I'll dig further.
27 remaining items
pitr-ch commentedon Aug 28, 2020
Thanks @pawelpacana for the report! I think I see the issue, the assignment conflicts with the
each_valueon line 100. I'll fix it asap, let you verify and then release a new version.pitr-ch commentedon Aug 28, 2020
@pawelpacana pls verify #884 works.
mostlyobvious commentedon Sep 18, 2020
@pitr-ch I can confirm the fix working, thank you 🖤
pitr-ch commentedon Sep 21, 2020
@pawelpacana thanks for confirming
rajnikantmahato commentedon Oct 20, 2020
[SIGSEGV]> ruby
/data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems.rb:1432: [BUG] Segmentation fault at 0x00000005
ruby 2.7.2p137 (2020-10-01 revision 5445e04352) [arm-linux-androideabi]
-- Control frame information -----------------------------------------------
c:0005 p:---- s:0019 e:000018 CFUNC :require
c:0004 p:0086 s:0014 e:000013 TOP /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems.rb:1432 [FINISH]
c:0003 p:---- s:0011 e:000010 CFUNC :require
c:0002 p:0012 s:0006 e:000005 TOP internal:gem_prelude:1 [FINISH]
c:0001 p:0000 s:0003 E:ffffdd38 (none) [FINISH]
-- Ruby level backtrace information ----------------------------------------
internal:gem_prelude:1:in
<internal:gem_prelude>' <internal:gem_prelude>:1:inrequire'/data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems.rb:1432:in
<top (required)>' /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems.rb:1432:inrequire'-- Other runtime information -----------------------------------------------
Loaded script: ruby
Loaded features:
0 enumerator.so
1 thread.rb
2 rational.so
3 complex.so
4 ruby2_keywords.rb
5 /data/data/com.termux/files/usr/lib/ruby/2.7.0/arm-linux-androideabi/enc/encdb.so
6 /data/data/com.termux/files/usr/lib/ruby/2.7.0/arm-linux-androideabi/enc/trans/transdb.so
7 /data/data/com.termux/files/usr/lib/ruby/2.7.0/arm-linux-androideabi/rbconfig.rb
8 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/compatibility.rb
9 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/defaults.rb
10 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/deprecate.rb
11 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/errors.rb
12 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/version.rb
13 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/requirement.rb
14 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/platform.rb
15 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/basic_specification.rb
16 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/stub_specification.rb
17 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/util.rb
18 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/text.rb
19 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/user_interaction.rb
20 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/specification_policy.rb
21 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/util/list.rb
22 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/specification.rb
23 /data/data/com.termux/files/usr/lib/ruby/2.7.0/rubygems/exceptions.rb
Process memory map:
7f555000-7f556000 r-xp 00000000 fd:00 408298 /data/data/com.termux/files/usr/bin/ruby
7f556000-7f557000 r--p 00000000 fd:00 408298 /data/data/com.termux/files/usr/bin/ruby
7f557000-7f558000 rw-p 00000000 00:00 0
b4200000-b4380000 rw-p 00000000 00:00 0 [anon:libc_malloc]
b43f1000-b43f2000 ---p 00000000 00:00 0
b43f2000-b4443000 rw-p 00000000 00:00 0
b4443000-b4444000 ---p 00000000 00:00 0
b4444000-b4495000 rw-p 00000000 00:00 0
b4495000-b4496000 ---p 00000000 00:00 0
b4496000-b44e7000 rw-p 00000000 00:00 0
b44e7000-b44e8000 ---p 00000000 00:00 0
b44e8000-b4539000 rw-p 00000000 00:00 0
b4539000-b453a000 ---p 00000000 00:00 0
b453a000-b458b000 rw-p 00000000 00:00 0
b458b000-b458c000 ---p 00000000 00:00 0
b458c000-b45dd000 rw-p 00000000 00:00 0
b45dd000-b45de000 ---p 00000000 00:00 0
b45de000-b462f000 rw-p 00000000 00:00 0
b462f000-b4630000 ---p 00000000 00:00 0
b4630000-b4681000 rw-p 00000000 00:00 0
b4681000-b4682000 ---p 00000000 00:00 0 [anon:thread stack guard page]
b4682000-b4780000 rw-p 00000000 00:00 0 [stack:13978]
b4780000-b6900000 rw-p 00000000 00:00 0 [stack:13977]
b6937000-b6957000 r--s 00000000 00:0c 12219 /dev/properties/u:object_r:system_prop:s0
b6957000-b69e0000 r-xp 00000000 103:14 2155 /system/lib/libc++.so
b69e0000-b69e4000 r--p 00088000 10
pitr-ch commentedon Nov 27, 2020
@rajnikantmahato why do you believe this is related?
immakdas commentedon Nov 6, 2021
[BUG] Segmentation fault at 0x0000000000000440
ruby 3.0.1p64 (2021-04-05 revision 0fb782ee38) [x86_64-linux]
blizzart commentedon May 4, 2022
still there, Rocky Linux 8, ruby 3.1.2p20 freshly compiled
[BUG] transient_heap_block_alloc: failed
ruby 3.1.2p20 (2022-04-12 revision 4491bb740a) [x86_64-linux]
-- Control frame information -----------------------------------------------
c:0001 p:---- s:0003 e:000002 (none) [FINISH]
-- C level backtrace information -------------------------------------------
/usr/local/bin/ruby(rb_print_backtrace+0x11) [0x55f13ca13dc8] vm_dump.c:759
/usr/local/bin/ruby(rb_vm_bugreport) vm_dump.c:1045
/usr/local/bin/ruby(bug_report_end+0x0) [0x55f13cad2d9b] error.c:798
/usr/local/bin/ruby(rb_bug_without_die) error.c:798
/usr/local/bin/ruby(die+0x0) [0x55f13c8321df] error.c:806
/usr/local/bin/ruby(rb_bug) error.c:808
/usr/local/bin/ruby(Init_TransientHeap+0xe) [0x55f13c8306f5] transient_heap.c:306
/usr/local/bin/ruby(rb_call_inits+0xe) [0x55f13c86dc4e] inits.c:25
/usr/local/bin/ruby(ruby_setup+0x105) [0x55f13c8373a5] eval.c:88
/usr/local/bin/ruby(ruby_init+0x9) [0x55f13c837429] eval.c:100
/usr/local/bin/ruby(main+0x46) [0x55f13c8324e6] error.c:3181
-- Other runtime information -----------------------------------------------
55f13c805000-55f13cbf8000 r-xp 00000000 08:01 420432 /usr/local/bin/ruby
55f13cdf7000-55f13cdfe000 r--p 003f2000 08:01 420432 /usr/local/bin/ruby
55f13cdfe000-55f13cdff000 rw-p 003f9000 08:01 420432 /usr/local/bin/ruby
55f13cdff000-55f13ce11000 rw-p 00000000 00:00 0
55f13e11b000-55f13e13c000 rw-p 00000000 00:00 0 [heap]
7ff1ac30b000-7ff1ac611000 r--s 00000000 08:01 395319 /usr/lib64/libc-2.28.so
7ff1ac611000-7ff1ae8c5000 r--s 00000000 08:01 420432 /usr/local/bin/ruby
7ff1ae8c5000-7ff1ae8dc000 r-xp 00000000 08:01 396555 /usr/lib64/libgcc_s-8-20210514.so.1
7ff1ae8dc000-7ff1aeadb000 ---p 00017000 08:01 396555 /usr/lib64/libgcc_s-8-20210514.so.1
7ff1aeadb000-7ff1aeadc000 r--p 00016000 08:01 396555 /usr/lib64/libgcc_s-8-20210514.so.1
7ff1aeadc000-7ff1aeadd000 rw-p 00017000 08:01 396555 /usr/lib64/libgcc_s-8-20210514.so.1
7ff1aeadd000-7ff1bba92000 r--p 00000000 08:01 395415 /usr/lib/locale/locale-archive
7ff1bba92000-7ff1bbc4e000 r-xp 00000000 08:01 395319 /usr/lib64/libc-2.28.so
7ff1bbc4e000-7ff1bbe4d000 ---p 001bc000 08:01 395319 /usr/lib64/libc-2.28.so
7ff1bbe4d000-7ff1bbe51000 r--p 001bb000 08:01 395319 /usr/lib64/libc-2.28.so
7ff1bbe51000-7ff1bbe53000 rw-p 001bf000 08:01 395319 /usr/lib64/libc-2.28.so
7ff1bbe53000-7ff1bbe57000 rw-p 00000000 00:00 0
7ff1bbe57000-7ff1bbfd8000 r-xp 00000000 08:01 395323 /usr/lib64/libm-2.28.so
7ff1bbfd8000-7ff1bc1d7000 ---p 00181000 08:01 395323 /usr/lib64/libm-2.28.so
7ff1bc1d7000-7ff1bc1d8000 r--p 00180000 08:01 395323 /usr/lib64/libm-2.28.so
7ff1bc1d8000-7ff1bc1d9000 rw-p 00181000 08:01 395323 /usr/lib64/libm-2.28.so
7ff1bc1d9000-7ff1bc1f9000 r-xp 00000000 08:01 396245 /usr/lib64/libcrypt.so.1.1.0
7ff1bc1f9000-7ff1bc3f8000 ---p 00020000 08:01 396245 /usr/lib64/libcrypt.so.1.1.0
7ff1bc3f8000-7ff1bc3f9000 r--p 0001f000 08:01 396245 /usr/lib64/libcrypt.so.1.1.0
7ff1bc3f9000-7ff1bc402000 rw-p 00000000 00:00 0
7ff1bc402000-7ff1bc405000 r-xp 00000000 08:01 395321 /usr/lib64/libdl-2.28.so
7ff1bc405000-7ff1bc604000 ---p 00003000 08:01 395321 /usr/lib64/libdl-2.28.so
7ff1bc604000-7ff1bc605000 r--p 00002000 08:01 395321 /usr/lib64/libdl-2.28.so
7ff1bc605000-7ff1bc606000 rw-p 00003000 08:01 395321 /usr/lib64/libdl-2.28.so
7ff1bc606000-7ff1bc60d000 r-xp 00000000 08:01 395400 /usr/lib64/librt-2.28.so
7ff1bc60d000-7ff1bc80c000 ---p 00007000 08:01 395400 /usr/lib64/librt-2.28.so
7ff1bc80c000-7ff1bc80d000 r--p 00006000 08:01 395400 /usr/lib64/librt-2.28.so
7ff1bc80d000-7ff1bc80e000 rw-p 00007000 08:01 395400 /usr/lib64/librt-2.28.so
7ff1bc80e000-7ff1bc829000 r-xp 00000000 08:01 395394 /usr/lib64/libpthread-2.28.so
7ff1bc829000-7ff1bca28000 ---p 0001b000 08:01 395394 /usr/lib64/libpthread-2.28.so
7ff1bca28000-7ff1bca29000 r--p 0001a000 08:01 395394 /usr/lib64/libpthread-2.28.so
7ff1bca29000-7ff1bca2a000 rw-p 0001b000 08:01 395394 /usr/lib64/libpthread-2.28.so
7ff1bca2a000-7ff1bca2e000 rw-p 00000000 00:00 0
7ff1bca2e000-7ff1bca44000 r-xp 00000000 08:01 396193 /usr/lib64/libz.so.1.2.11
7ff1bca44000-7ff1bcc44000 ---p 00016000 08:01 396193 /usr/lib64/libz.so.1.2.11
7ff1bcc44000-7ff1bcc45000 r--p 00016000 08:01 396193 /usr/lib64/libz.so.1.2.11
7ff1bcc45000-7ff1bcc46000 rw-p 00000000 00:00 0
7ff1bcc46000-7ff1bcc72000 r-xp 00000000 08:01 395382 /usr/lib64/ld-2.28.so
7ff1bcca3000-7ff1bce6c000 rw-p 00000000 00:00 0
7ff1bce72000-7ff1bce73000 r--p 0002c000 08:01 395382 /usr/lib64/ld-2.28.so
7ff1bce73000-7ff1bce75000 rw-p 0002d000 08:01 395382 /usr/lib64/ld-2.28.so
7ffcd2c4c000-7ffcd344b000 rw-p 00000000 00:00 0 [stack]
7ffcd3522000-7ffcd3526000 r--p 00000000 00:00 0 [vvar]
7ffcd3526000-7ffcd3528000 r-xp 00000000 00:00 0 [vdso]
ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0 [vsyscall]
Aborted (core dumped)
chrisseaton commentedon May 4, 2022
Ask around about this.
eregon commentedon Dec 21, 2022
The stacktraces since the last close of this issue look completely unrelated to concurrent-ruby.
Also if there is a new segfault related to concurrent-ruby, please open a new issue.