Project

General

Profile

Actions

Bug #2097

closed

fork NotImplementedError on FreeBSD

Added by robertgleeson (Robert Gleeson) about 15 years ago. Updated about 13 years ago.

Status:
Third Party's Issue
Assignee:
-
Target version:
-
ruby -v:
ruby 1.9.1p129 (2009-05-12 revision 23412) [x86_64-freebsd7.1]
Backport:
[ruby-core:25564]

Description

=begin
Hi,

I'm not sure if a fix should be applied via patches to the FreeBSD port of ruby or in ruby itself, but on Ruby 1.9.1(patchlevel 129) you cannot fork a process.

irb(main):002:0> Process.fork
NotImplementedError: fork() function is unimplemented on this machine
from (irb):2:in fork' from (irb):2 from /opt/ruby19/bin/irb19:12:in '

I love ruby, and I love FreeBSD. It'd be great if i can combine both. Thanks!
=end


Related issues 1 (0 open1 closed)

Related to Ruby master - Bug #270: lazy timer thraed creationClosedko1 (Koichi Sasada)Actions
Actions #1

Updated by nobu (Nobuyoshi Nakada) about 15 years ago

=begin
Hi,

At Mon, 14 Sep 2009 14:16:11 +0900,
robert gleeson wrote in [ruby-core:25564]:

I'm not sure if a fix should be applied via patches to the
FreeBSD port of ruby or in ruby itself, but on Ruby
1.9.1(patchlevel 129) you cannot fork a process.

On recent *BSD, fork can't work with pthreads, and pthreads is
mandatory to ruby 1.9. This is caused by the kernel internal.
See http://www.freebsd.org/cgi/query-pr.cgi?pr=threads/101323.

I love ruby, and I love FreeBSD. It'd be great if i can
combine both. Thanks!

Persuade the BSD maintainers.

--
Nobu Nakada

=end

Actions #2

Updated by nobu (Nobuyoshi Nakada) about 15 years ago

  • Status changed from Open to Third Party's Issue

=begin

=end

Actions #3

Updated by naruse (Yui NARUSE) about 15 years ago

=begin
use Process.spawn.
=end

Actions #4

Updated by robertgleeson (Robert Gleeson) about 15 years ago

=begin
Hi,

Thanks for reply. It seems this issue is resolved on FreeBSD 7.2 for anyone who stumbles upon this :-)
=end

Actions #5

Updated by naruse (Yui NARUSE) about 15 years ago

=begin
On Ruby 1.9.1 and FreeBSD7.2 fork doesn't work.
But on ruby 1.9.2dev (2009-09-16 trunk 24965) [x86_64-freebsd7.2], fork works.
I don't know why.
=end

Actions #6

Updated by naruse (Yui NARUSE) about 15 years ago

=begin
Just information for someone see this,

FreeBSD 7.2 can fork when pthreads doesn't run.
So in trunk, stop timer thread then fork and restart timer.
=end

Updated by Potapuff (Borys Kuzikov) about 13 years ago

Hey, anybody! Hack this bug!

Updated by naruse (Yui NARUSE) about 13 years ago

Borys Kuzikov wrote:

Hey, anybody! Hack this bug!

Use 7.2 or later.

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0