尝试安装RVM时无法解析主机 [英] Could not resolve host when trying to install RVM

查看:322
本文介绍了尝试安装RVM时无法解析主机的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试按照RVM页面上的说明在我的环境中安装RVM

I'm trying to install RVM on my environment following the instructions on RVM page

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

但是我总是这样:

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   185  100   185    0     0    198      0 --:--:-- --:--:-- --:--:--   246
100  9979  100  9979    0     0   3821      0  0:00:02  0:00:02 --:--:-- 14740
Please read and follow further instructions.
Press ENTER to continue.
Downloading RVM from wayneeseguin branch stable
curl: (6) Could not resolve host: github.com; nodename nor servname provided, or not known

在尝试RVM之前尝试安装gems时遇到相同的错误.有人说这是网络问题,但我不知道是什么问题.我是红宝石的新手,正在尝试设置环境以使用Rails.

I've got the same error when trying to install gems before trying RVM. Some people say it's a network problem, but I can't figure out what it is. I'm new to ruby and trying to setup my environment to work with rails.

我尝试对github.com进行ping操作,大多数数据包运行良好,丢失率不到10%.

I've tried to ping github.com and most packets went fine with less than 10% loss.

这真的是我的网络存在的问题吗?如果是这样,我该如何解决?

So is this really a problem with my network? If so, how can I fix this?

我正在运行Mac OS X 10.8.

I'm running Mac OS X 10.8.

更新:

当然,这是我在Mac OS X上的网络配置中的问题.我无法在git或svn上运行命令.我总是收到无法解析主机名"错误.需要对此进行一些调查. 有人遇到过同样的问题吗?因此,我可以尝试更改网络配置.

Definitely, it's some problem in my network configuration on Mac OS X. I can't run commands on git or svn. I always get the 'could not resolve hostname' error. Need some investigation on that. Have someone ever had the same problem? So I could try to change something on my network configuration.

推荐答案

它看起来像DNS或代理问题.根据您的评论,您没有使用代理.将您的DNS服务器更改为 Google DNS ,然后重试.

It looks like a DNS or proxy problem. From your comments, you are not using proxy. Change your DNS servers to Google DNS and try again.

该问题与git或svn无关,因此您不会在其站点上找到有关DNS的信息.这是由于网络配置,网络可用性或互联网提供商(可能是前者)造成的.

That problem is not related to git or svn, so you won't find info about DNS on their sites. It's due to network config, network availability or internet provider (likely the former).

这篇关于尝试安装RVM时无法解析主机的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆