Project

General

Profile

Actions

Bug #17196

closed

Segmentation Fault with Socket#close in Ractors

Added by asuper (Anthony Super) over 3 years ago. Updated 8 months ago.

Status:
Closed
Target version:
-
ruby -v:
ruby 3.0.0preview1 (2020-09-25 master 0096d2b895) [x86_64-linux]
[ruby-core:100181]

Description

While messing around with 3.0.0-preview1, I thought it would be fun to write a really, really simple webserver that used Ractor creation instead of forking or spawning threads. I was right, it was fun! Unfortunately it also caused a segfault. The segfault appears to be on socket closure when a lot of ractors are running at once.

The attached tarball includes the code you need to make it happen. Run bin/server in one terminal/screen session/tmux window/whatever, and ./bug_bench.sh with the other. You'll need to have the apache benchmark utility installed.


Files

reproduce-my-segfault.tar.gz (10 KB) reproduce-my-segfault.tar.gz Tarball that includes reproduction steps + error dump asuper (Anthony Super), 09/26/2020 09:18 PM
error_log.txt (38.6 KB) error_log.txt Just the error dump, in case that's more interesting asuper (Anthony Super), 09/26/2020 09:18 PM

Updated by ko1 (Koichi Sasada) over 3 years ago

  • Assignee set to ko1 (Koichi Sasada)
Actions #2

Updated by hsbt (Hiroshi SHIBATA) over 2 years ago

  • Status changed from Open to Assigned

Updated by wanabe (_ wanabe) about 2 years ago

I tried to reproduce the problem at hand, but it seems to have already been fixed in the current master.
According to git bisect, it seemed to be fixed by #18117 https://bugs.ruby-lang.org/projects/ruby-master/repository/git/revisions/bbedd29b6e98ef6e3fc2ce2b358d2b509b7cd1bb.
How about using 3.0.3 or 3.1.x or master?

Actions #4

Updated by jeremyevans0 (Jeremy Evans) 8 months ago

  • Status changed from Assigned to Closed
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0