0
votes

I am trying to manually install rails, but have encountered the following error:

c:\Ruby193\bin>gem install rails
ERROR:  Could not find a valid gem 'rails' (>= 0) in any repository
ERROR:  While executing gem ... (Gem::RemoteFetcher::FetchError)
    Errno::ETIMEDOUT: A connection attempt failed because the connected party 
did not properly respond after a period of time, or established connection failed
because connected host has failed to respond. - connect(2) (http://rubygems.org/
latest_specs.4.8.gz)

How can this be solved?

The steps I followed so far:

  • I installed Ruby from here: http://rubyinstaller.org/downloads/, running the Ruby 1.9.3-p545 from the RubyInstaller section. (into C:\Ruby193)
  • I installed also (for use with Ruby 1.8.7 and 1.9.3): the DevKit-tdm-32-4.5.2-20111229-1559-sfx.exe into C:\RubyDevKit.
  • I went to RubyDevKit in cmd and typed:

dir dk.rb
ruby dk.rb init
ruby dk.rb install

  • I launched irb (typed irb in C:\RubyDevKit) to confirm ruby works and it does.
1
Umm are you connected to the internet? - Anshul Goyal
yes, I am connected to the internet, mu. In fact, I just tried now to manually download http://rubygems.org/ latest_specs.4.8.gz by typing this in my browser and it worked. But still, my Rails installation fails when I enter gem install rails as described above. Is there something I am missing? Need to install rails. - Samy
Have a look at this question. - Anshul Goyal

1 Answers

-1
votes

I am right now faced with this problem

Reset DNS cache solved that problem for me (Run "ipconfig /flushdns" from cmd shell)