Error loading RubyGems plugin ,openssl.bundle (LoadError)

前端 未结 4 369
小蘑菇
小蘑菇 2020-12-24 05:32

I am new to ruby. When I type any thing related to gem, error below will happen. why causes it and how to solve the problem? Thanks!

Error loading RubyGems          


        
相关标签:
4条回答
  • 2020-12-24 05:56

    The following worked for me.

    brew rm openssl
    brew cleanup openssl
    brew install openssl
    rvm reinstall ruby
    

    Apparently brew update or brew upgrade breaks the Ruby runtime which is what caused the error for me.

    0 讨论(0)
  • 2020-12-24 06:10

    To whoever having this problem with rbenv, I solved it reinstalling openssl and upgrading rbenv, then reinstalling ruby:

    brew reinstall openssl
    brew upgrade ruby-build rbenv
    rbenv install 2.2.10 # or whatever version you're using it
    
    0 讨论(0)
  • 2020-12-24 06:15

    Things to verify...

    • How did you install rvm
    • hit rvm notes and check if it's installed properly
    • ruby -v, check for the version of ruby present

    If you find any issues here, uninstall rvm using rvm implode and also remove ruby. Refer to the rvm installation guide for the use of this command.

    \curl -L https://get.rvm.io | bash -s stable --ruby
    

    OR you can try the other way without removing the present rvm installation.

    rvm get stable
    rvm reinstall 2.0.0
    

    Hope this helps.

    0 讨论(0)
  • 2020-12-24 06:20

    Im assuming you already installed the right package aka brew install/reinstall openssl if not - do it.

    Another Solution (In case your package is installed) - Might be that your package is not referenced to the right endpoint version, you have multiple versions of the same package (on this use-case openssl package) and your rvm is not finding it event though it's installed.

    Run list of the package versions and switch to the right one.

    example:

    brew list  --versions openssl
    
    /* Output:
    openssl 1.0.2s
    openssl 1.2
    openssl 1.3
    */
    
    brew switch openssl 1.0.2s
    
    0 讨论(0)
提交回复
热议问题