Phusion white papers Phusion overview

Ruby Enterprise Edition 1.8.7-2010.02 released

By Hongli Lai on June 7th, 2010

It has been a while since the last REE release. We apologize for not releasing earlier, it’s been very busy for us lately. Nonetheless, a number of important issues have motivated us to release again, including various Rails 3 compatibility issues. Read on for more information.

What is Ruby Enterprise Edition?

Ruby Enterprise Edition (REE) is a server-oriented distribution of the official Ruby interpreter, and includes various additional enhancements, such as:

REE can be easily installed in parallel to your existing Ruby interpreter, allowing you switch to REE with minimal hassle or risk. REE has been out for about a year now and is already used by many high-profile websites and organizations, such as New York Times, Shopify and 37signals.

“We switched to enterprise ruby to get the full benefit of the [copy-on-write] memory characteristics and we can absolutely confirm the memory savings of 30% some others have reported. This is many thousand dollars of savings even at today’s hardware prices.”
Tobias Lütke (Shopify)

Ruby Enterprise Edition is 100% open source.

Changes

Upgraded to Ruby 1.8.7-p249
The previous REE release was based on 1.8.7-p248. p249 hasn’t changed much: it only includes some WEBrick fixes.
Upgraded to RubyGems 1.3.7
The previous REE release included RubyGems 1.3.5. 1.3.7 is required by the latest version of Bundler as well as Rails 3.
Backported various bug fixes
The following bug fixes are fixed by upstream Ruby, but not yet released, i.e. these fixes are not part of the latest Ruby 1.8.7-p249 release. We’ve backported these fixes because they solve important compatibility issues.

  • Fixed a Marshal bug that was apparently caused by GCC optimizations. This is a major bug that appears to be responsible for all the REE crash bug reports of late. It is so severe that the Rails 3 documentation actually recommends not using 1.8.7-p248 and 1.8.7-p249:

    “Note that Ruby 1.8.7 p248 and p249 has marshaling bugs that crash Rails 3.0.0. Ruby 1.9.1 outright segfaults on Rails 3.0.0, so if you want to use Rails 3 with 1.9.x, jump on 1.9.2 trunk for smooth sailing.”

    Ruby bug #2557. Given that Ruby 1.8 is still so widely used, being forced to use Ruby 1.9.2 (-dev version even) is not such a good thing. With these backports Rails 3 should be once again usable on 1.8, at least until upstream releases a new version with the fix.

  • Fixed an “undefined method `closed?’ for nil:NilClass” Net::HTTP bug. Ruby issue #2708 and REE issue #35.
  • Fixed a bug where the ‘super’ keyword doesn’t behave correctly. Ruby issue #2537 and REE issue #40.
Fixed various FreeBSD issues
  • REE on FreeBSD would occasionally crash with a bizarre “Illegal Instruction” error. After some though investigations, it would appear that the problem is caused by the MBARI patch set in combination with some FreeBSD oddities. MBARI tries to reserve the upper part of the system stack for the garbage collector. In order to do this, it queries the OS for the size of the stack. FreeBSD reports a large size (on 64-bit FreeBSD it reports 512 MB by default), but in reality only about 4 MB could be used: if you go over it then the process will crash. We’ve fixed this issue by limiting the stack usage to 4 MB when on FreeBSD.
  • Fixed some long-standing iconv installation bugs. The iconv Ruby extension is used by various important parts of Ruby and Rails. FreeBSD installs the iconv .h headers files into /usr/local/include, but gcc doesn’t look in this location by default, and neither does the iconv extension’s extconf.rb. We’ve modified the REE installer to force the compiler to look in /usr/local/include while installing the iconv extension.
  • Added a bootstrap binary for x86_64 FreeBSD 8. This means that on this platform you don’t have to install Ruby first before you can run the REE installer (which is written in Ruby).
Rational and gcd performance improvement patches
Kurt Stephens has contributed a set of patches which dramatically improve the performance of the Rational class and the #gcd method. Rational performance has been improved by over 50%. Ruby issue #2561 and REE issue #23
Various other minor bug fixes
  • GEM_HOME, GEM_PATH and RUBYOPT are unset before running the installer so that those options can’t interfere with installation.
  • RUBY_HEAP_SLOTS_GROWTH_FACTOR wasn’t properly parsed as a floating point number. This has now been fixed.
  • Fixed OpenSSL compilation problems. Patch contributed by hso@nosneros.net. REE issue #39.
More Ubuntu packages
We now provide packages for:

  • Ubuntu 8.04 32-bit
  • Ubuntu 8.04 64-bit
  • Ubuntu 10.04 32-bit
  • Ubuntu 10.04 64-bit

Download & upgrade

To install Ruby Enterprise Edition, please visit the download page. To upgrade from a previous version, simply install into the same prefix that you installed to last time. Please also refer to the documentation for upgrade instructions.

  • http://rubymate.com/ Ethan Cane

    This came at just the right time.

    Many thanks for the Ubuntu packages.

    Great work and a flawless installation.

    Many thanks.

    Ethan Cane

  • Pingback: Link dump for June 7th | The Queue Blog()

  • ben

    there is a diff between the release notes and my terminal :D

    ruby -v
    ruby 1.8.7 (2010-04-19 patchlevel 253) [x86_64-linux], MBARI 0x6770, Ruby Enterprise Edition 2010.02

    ist p253 not p249

  • http://www.phusion.nl/ Hongli Lai

    Oops, looks like the backport backported too much code. :p

  • Pingback: Brightbox Blog - Ruby on Rails Hosting – Ruby Enterprise 1.8.7-2010.02 Packages for Ubuntu Hardy & Lucid()

  • lsp

    It seems like “Illegal Instruction” error is still present on FreeBSD 6.3-STABLE i386:

    gcc -g -O2 -DRUBY_EXPORT -L. -rdynamic main.o libruby-static.a -Wl,-rpath,/opt/ruby-enterprise-1.8.7-2010.02/lib -L/opt/ruby-enterprise-1.8.7-2010.02/lib -ltcmalloc_minimal -lpthread -lcrypt -lm -o miniruby
    Illegal instruction
    *** Error code 132

  • Alexey Vakhov

    The same on FreeBSD-6.0

    make PRELIBS=’-Wl,-rpath,/opt/ruby-enterprise-1.8.7-2010.02/lib -L/opt/ruby-enterprise-1.8.7-2010.02/lib -ltcmalloc_minimal -lpthread’
    Illegal instruction (core dumped)
    *** Error code 132

  • Johan

    Semilar thing on FreeBSD 8.1

    gcc -g -O2 -DRUBY_EXPORT -L. -rdynamic main.o libruby-static.a -Wl,-rpath,/opt/ree/lib -L/opt/ree/lib -ltcmalloc_minimal -lpthread -lrt -lcrypt -lm -o miniruby
    *** Signal 4