Redmine, ruby gems, mysql2

Hi,

I need to install Redmine on OpenSUSE 42.2 but I run into problems with the mysql extension (crash with segmentation fault).


(in /home/apache/redmine/redmine-3.3.3)
/usr/lib64/ruby/gems/2.1.0/extensions/x86_64-linux/2.1.0/mysql2-0.3.21/mysql2/mysql2.so: [BUG] Segmentation fault at 0x0000000000000b
ruby 2.1.2p95 (2014-05-08 revision 45877) [x86_64-linux-gnu]

I’m using the following versions


Using rake 12.0.0
Using i18n 0.7.0
Using json 1.8.6
Using minitest 5.10.1
Using thread_safe 0.3.6
Using builder 3.2.3
Using erubis 2.7.0
Using mini_portile2 2.1.0
Using rack 1.6.5
Using mime-types-data 3.2016.0521
Using arel 6.0.4
Using public_suffix 2.0.5
Using bundler 1.14.6
Using coderay 1.1.1
Using concurrent-ruby 1.0.5
Using htmlentities 4.3.4
Using thor 0.19.4
Using mimemagic 0.3.2
Using mysql2 0.3.21
Using net-ldap 0.12.1
Using ruby-openid 2.3.0
Using rbpdf-font 1.19.1
Using redcarpet 3.3.4
Using request_store 1.0.5
Using tzinfo 1.2.3
Using nokogiri 1.6.8.1
Using rack-test 0.6.3
Using mime-types 3.1
Using addressable 2.5.1
Using sprockets 3.7.1
Using rack-openid 1.4.2
Using rbpdf 1.19.2
Using activesupport 4.2.7.1
Using loofah 2.0.3
Using mail 2.6.4
Using css_parser 1.4.10
Using rails-deprecated_sanitizer 1.0.3
Using globalid 0.4.0
Using activemodel 4.2.7.1
Using rails-html-sanitizer 1.0.3
Using roadie 3.2.1
Using rails-dom-testing 1.0.8
Using activejob 4.2.7.1
Using activerecord 4.2.7.1
Using protected_attributes 1.1.3
Using actionview 4.2.7.1
Using actionpack 4.2.7.1
Using actionmailer 4.2.7.1
Using actionpack-action_caching 1.2.0
Using actionpack-xml_parser 1.0.2
Using railties 4.2.7.1
Using sprockets-rails 3.2.0
Using jquery-rails 3.1.4
Using roadie-rails 1.1.1
Using rails 4.2.7.1

I’ve tried on two different computer and it seems that there is a bug in the mysql extension.
Any known workaround for the problem?

Thank you

Regards
Reidar

How are you installing Ruby?
I’ve recently updated some new requirements for LEAP 42.2 in my “Install Ruby on openSUSE 42.2” guide (although now probably needs some re-writing to clarify)… If Ruby from the openSUSE repos doesn’t work fully (eg I discovered that currently the Jekyll packages will install, but don’t support all of Jekyll’s features), then I also provide you with instructions how to install Ruby from the official Ruby repos, using rbenv which allows you to specify the Ruby version you want to run systemwide, in a single specific Ruby app, or a console.

https://en.opensuse.org/User:Tsu2/Install_Ruby

TSU

TSU,

Thank you for responding.
Ruby is installed from the Leap 42.2 repositories, I’ve tried on two different computer with the same result (segmentation fault in mysql2.so).

I’ll try to use a different version of Ruby as described in the instructions. I’m generally happy with OpenSUSE so changing to another distribution is not my first option.

Thanks
Reidar

Hi,

I got the same issue and found your post while searching for solutions. But nothing on the web.

Now I went to investigate it by myself and found the culprit:
libssl.so.38
libcrypto.so.37

There are conflicts logged in the mkmf.log of the mysql2 gem.
I uninstalled these two packages and reinstalled the mysql2 gem. Now everything is fine.

Regards.

First, you need to describe where the gem you used came from (openSUSE, Ruby repos? elsewhere?)
If you uninstalled those library files, you need to make sure that replacement libraries are installed, and more likely later versions which you can assume are “improved” (ie patches, features, etc).

TSU

I’ve installed the gems from the Ruby repo.

Okay, so I’ve reinstalled libssl from the OpenSUSE update repo, then reinstalled the mysql2 gem v. 0.3.21 without an issue.

I resolved the problem by uninstalling the following (old versions not in use):
libssl.so.38
libcrypto.so.37
libtsl.so.10

Thank you for the help viragomann