Getting a While executing gem … (Gem::RemoteFetcher::FetchError) 503 error when attempting to install rails

僤鯓⒐⒋嵵緔 提交于 2020-01-05 02:54:06

问题


This is the error I get when I try to do a "gem install rails -v 4.1.0" using Ruby 2.1.1 and RVM.

ERROR: While executing gem ... (Gem::RemoteFetcher::FetchError) bad response Service Unavailable 503 (http://api.rubygems.org/api/v1/dependencies?gems=activerecord)

Not sure what is causing this, anybody have any ideas?


回答1:


It would be a ssl problem.

Change your gem sources and try again.

gem sources --remove https://rubygems.org/
gem sources -a http://rubygems.org/



回答2:


Make sure your rvm ssl certificates are up to date.

Check their status

$ rvm osx-ssl-certs status all

Update them!

$ rvm osx-ssl-certs update all

Also try

gem install rails --include-dependencies



回答3:


Sometimes it is just a server problem.

I waited a few minutes and tried again and it worked.



来源:https://stackoverflow.com/questions/23351405/getting-a-while-executing-gem-gemremotefetcherfetcherror-503-error-whe

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!