Error When Installing Ruby 2.1.3 with Rvm

Error when installing Ruby 2.1.3 with RVM

I had the same problem

rvm reinstall 2.1.3 --disable-binary

worked for me
(based on Fresh Installs of RVM and Ruby 2.1.1 - dyld library/pathing error).

RVM install ruby failed to install rubies, RVM installed in /usr/local

Your problem is in permissions:

 mkdir: /usr/local/rvm/tmp/rvm_src_7085: Permission denied

You have RVM installed in /usr/local

I am running RVM on OS X Yosemite and have my RVM installed in my home directory:

 /Users/andy...

If you want to install globally like you have it, you will probably have to use the sudo command to complete the install. But I would highly recommend NOT doing that.

You should uninstall RVM and re-install it under your home directory. That is, open the terminal and ensure that you are in your home directory:

cd ~/

will put you in your home directory. Then install RVM and DO NOT use sudo, just install it with your regular permissions. That is the whole point of RVM, to keep the versions of Ruby separate.

Here is the Stack Overflow answer for removing all traces of the old RVM from your system before reinstalling:
How can I remove RVM (Ruby Version Manager) from my system?
Be sure and pay attention to the part at the end about checking for modifications to your $PATH variable.

Ruby 2.1.3 installation in Ubuntu 14.04.1 hang?

Looks like this might do the trick. It worked for me on OS X.

rvm install 2.1.3 -- --with-setjmp-type=setjmp

Found the solution in this rvm issue, which references a core Ruby installation issue.

Installing ruby-2.1.2: Cannot load such file -- openssl (LoadError)

Ruby <2.4 is incompatible with OpenSSL 1.1 (e.g see https://github.com/rbenv/ruby-build/issues/1353).

Just a hunch, but if you're using Mac + Homebrew, OpenSSL 1.0 was recently deleted, so anything along the lines of brew upgrade openssl would trash that.

There are several options to deal with this:

  1. I have older Rubies via asdf installed with LibreSSL (which may be safer anyway, see https://security.stackexchange.com/questions/112545/what-are-the-main-advantages-of-using-libressl-in-favor-of-openssl):
$ openssl
OpenSSL> version
LibreSSL 2.8.3

  1. Compile and link your own OpenSSL 1.0 (or then set compiler flags as environment variables when building Ruby -- https://rvm.io/rubies/installing)
  2. See if your system's package manager allows you to access openssl 1.0 and install with that (was helping a coworker with this recently and we weren't able to find a good keg for homebrew at this time, unfortunately)

There might be something less convoluted than that; if someone has ideas, please feel free to comment or give an alternate answer.

EDIT

I personally ran into this issue with some other software and discovered that this fixed it, since the old SSL version was sitting around still:

brew switch openssl 1.0.2s

Should work so long as Homebrew doesn't "helpfully" clean that out for me.

How do I upgrade RVM when the official way doesn't work?

Install RVM from scratch

1) First remove the current version, see: https://stackoverflow.com/a/3558763/1076207

# use sudo at your own discretion
rvm implode --force
gem uninstall rvm
rm -rf ~/.rvm

# open file
vim ~/.bash_profile
# remove lines:
# [[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm"
# close file

2) Follow the directions on the RVM install page: https://rvm.io/rvm/install



Related Topics



Leave a reply



Submit