unicorn Ruby/Rack server user+dev discussion/patches/pulls/bugs/help
 help / color / mirror / code / Atom feed
From: Eric Wong <e@80x24.org>
To: vtamara <vtamara@pasosdeJesus.org>
Cc: unicorn-public@yhbt.net, Jeremy Evans <code@jeremyevans.net>
Subject: Re: Bus Error with Unicorn 6.0 on OpenBSD/adJ 6.8 with Ruby 3.0
Date: Tue, 30 Mar 2021 01:58:06 +0000	[thread overview]
Message-ID: <20210330015806.GA4267@dcvr> (raw)
In-Reply-To: <6acb1c84c7392d7b4a64572b20498549@pasosdeJesus.org>

vtamara <vtamara@pasosdeJesus.org> wrote:
> Hi
> 
> Launching a rails application with Ruby 3, Unicorn 6 on OpenBSD/adJ 6.8, I'm
> experiencing a lot of "Bus Error" and "Segmentation Faults" during
> aproximately half hour.

+Cc: Jeremy Evans, who is more familiar with OpenBSD and Ruby 3.0 than I
cf. https://yhbt.net/unicorn-public/6acb1c84c7392d7b4a64572b20498549@pasosdeJesus.org/

vtamara: did previous versions of Ruby, unicorn, or OpenBSD work
for your app?

Is preload_app in use?  If so, does the problem manifest without
preload_app?

Are you using Ractor or any other new/experimental stuff
in Ruby?

Can you reproduce the problem with a simple "hello world"-style app?

> The line 80 of the file
> /var/www/bundler/ruby/3.0/gems/unicorn-6.0.0/lib/unicorn.rb is:
> 
> case ENV["RACK_ENV"]
> 
> Only 4 errors had a backtrace, pasting the first one:
> 
> ----------------------------------------
> I, [2021-03-29T09:34:31.278771 #37959]  INFO -- : Refreshing Gem list
> /var/www/bundler/ruby/3.0/gems/unicorn-6.0.0/lib/unicorn.rb:80: [BUG]
> Segmentation fault at 0x0000000000000019

That's a strange one, I wonder if OpenBSD getenv(3) has some
restrictions or other odd behaviors with it?

Do you have any code/dependencies which are calling "ENV#[]=" in
Ruby; setenv()/putenv() in C, or modifying "environ" directly
in C?

Especially in sub-threads/Ractors at startup...

<snip>

> * Loaded features:
> 
>     0 enumerator.so
>     1 thread.rb
>     2 rational.so
>     3 complex.so
>     4 ruby2_keywords.rb
>     5 /usr/local/lib/ruby/3.0/x86_64-openbsd/enc/encdb.so
>     6 /usr/local/lib/ruby/3.0/x86_64-openbsd/enc/trans/transdb.so

<snip>

> ...

Any other .so extensions?  C extensions can do any number of
things and maybe some interact badly...

  reply	other threads:[~2021-03-30  1:58 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-29 19:06 Bus Error with Unicorn 6.0 on OpenBSD/adJ 6.8 with Ruby 3.0 vtamara
2021-03-30  1:58 ` Eric Wong [this message]
2021-03-30  4:00   ` Jeremy Evans
2021-04-04 11:06     ` vtamara
2021-04-04 16:43       ` Jeremy Evans
2021-04-04 20:03         ` Eric Wong
2021-04-07 21:19           ` Bus Error with Unicorn 6.0 on OpenBSD-current (6.9) with Ruby 3.0 in minimal rails application vtamara
2021-04-08  2:11             ` Jeremy Evans
2021-04-12 22:47               ` vtamara

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://yhbt.net/unicorn/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210330015806.GA4267@dcvr \
    --to=e@80x24.org \
    --cc=code@jeremyevans.net \
    --cc=unicorn-public@yhbt.net \
    --cc=vtamara@pasosdeJesus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhbt.net/unicorn.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).