美文网首页
Connecting to raw.githubusercont

Connecting to raw.githubusercont

作者: 吟风划彩虹 | 来源:发表于2020-02-10 21:53 被阅读0次

文章参考自该篇博客

wget或者curl请求raw.githubusercontent.com这个域名的时候有时候会出现以下问题

Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 151.101.228.133
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|151.101.228.133|:443... failed: Connection refused.

原因是由于某些原因导致GitHub的raw.githubusercontent.com域名解析被污染了。

记录一下解决方法:

  1. 查询raw.githubusercontent.com的真实IP
    https://www.ipaddress.com/ 查询raw.githubuercontent.com的真实IP。

  2. 修改hosts
    在/etc/hosts/中绑定查到的host,例如:

sudo vim /etc/hosts
#绑定host
199.232.28.133 raw.githubusercontent.com

然后再执行就能成功了。

相关文章

网友评论

      本文标题:Connecting to raw.githubusercont

      本文链接:https://www.haomeiwen.com/subject/mfizxhtx.html